diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2015-04-03 15:07:48 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2015-04-11 22:29:37 -0400 |
commit | a35fb914ae62a58ca7519778fffac722c6ae255f (patch) | |
tree | 4247bf8db32b4433c9f5c76c512fdc52d6f4cf93 | |
parent | 493c84c0722ac991a96df2fd6c7798b2126b626c (diff) |
autofs: switch to __vfs_write()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r-- | fs/autofs4/autofs_i.h | 2 | ||||
-rw-r--r-- | fs/autofs4/waitq.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/fs/autofs4/autofs_i.h b/fs/autofs4/autofs_i.h index 8e98cf954bab..d10e619632ab 100644 --- a/fs/autofs4/autofs_i.h +++ b/fs/autofs4/autofs_i.h | |||
@@ -213,7 +213,7 @@ void autofs4_clean_ino(struct autofs_info *); | |||
213 | 213 | ||
214 | static inline int autofs_prepare_pipe(struct file *pipe) | 214 | static inline int autofs_prepare_pipe(struct file *pipe) |
215 | { | 215 | { |
216 | if (!pipe->f_op->write) | 216 | if (!(pipe->f_mode & FMODE_CAN_WRITE)) |
217 | return -EINVAL; | 217 | return -EINVAL; |
218 | if (!S_ISFIFO(file_inode(pipe)->i_mode)) | 218 | if (!S_ISFIFO(file_inode(pipe)->i_mode)) |
219 | return -EINVAL; | 219 | return -EINVAL; |
diff --git a/fs/autofs4/waitq.c b/fs/autofs4/waitq.c index 116fd38ee472..2ad05ab93db8 100644 --- a/fs/autofs4/waitq.c +++ b/fs/autofs4/waitq.c | |||
@@ -70,7 +70,7 @@ static int autofs4_write(struct autofs_sb_info *sbi, | |||
70 | 70 | ||
71 | mutex_lock(&sbi->pipe_mutex); | 71 | mutex_lock(&sbi->pipe_mutex); |
72 | while (bytes && | 72 | while (bytes && |
73 | (wr = file->f_op->write(file,data,bytes,&file->f_pos)) > 0) { | 73 | (wr = __vfs_write(file,data,bytes,&file->f_pos)) > 0) { |
74 | data += wr; | 74 | data += wr; |
75 | bytes -= wr; | 75 | bytes -= wr; |
76 | } | 76 | } |