From: Dmitry Monakhov Date: Fri, 3 Jan 2014 03:10:24 +0000 (+1100) Subject: fs/pipe.c: skip file_update_time on frozen fs X-Git-Tag: next-20140106~2^2~56 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=be8a170d79237f09713da357385ed6165ece56b2;p=karo-tx-linux.git fs/pipe.c: skip file_update_time on frozen fs Pipe has no data associated with fs so it is not good idea to block pipe_write() if FS is frozen, but we can not update file's time on such filesystem. Let's use same idea as we use in touch_time(). Addresses https://bugzilla.kernel.org/show_bug.cgi?id=65701 Signed-off-by: Dmitry Monakhov Reviewed-by: Jan Kara Cc: Al Viro Signed-off-by: Andrew Morton --- diff --git a/fs/pipe.c b/fs/pipe.c index 0e0752ef2715..78fd0d0788db 100644 --- a/fs/pipe.c +++ b/fs/pipe.c @@ -663,10 +663,11 @@ out: wake_up_interruptible_sync_poll(&pipe->wait, POLLIN | POLLRDNORM); kill_fasync(&pipe->fasync_readers, SIGIO, POLL_IN); } - if (ret > 0) { + if (ret > 0 && sb_start_write_trylock(file_inode(filp)->i_sb)) { int err = file_update_time(filp); if (err) ret = err; + sb_end_write(file_inode(filp)->i_sb); } return ret; }