diff options
author | Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp> | 2017-05-08 18:58:59 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2017-05-08 20:15:14 -0400 |
commit | c718a97514e4d77c97a35734b728aaf541a0621b (patch) | |
tree | ee3ecc300b4f02c8e27af51a24607068b54a0f61 /fs/buffer.c | |
parent | f44a2920c84af809883ecbbd08d47fb5fe47c8ad (diff) |
fs: semove set but not checked AOP_FLAG_UNINTERRUPTIBLE flag
Commit afddba49d18f ("fs: introduce write_begin, write_end, and
perform_write aops") introduced AOP_FLAG_UNINTERRUPTIBLE flag which was
checked in pagecache_write_begin(), but that check was removed by
4e02ed4b4a2f ("fs: remove prepare_write/commit_write").
Between these two commits, commit d9414774dc0c ("cifs: Convert cifs to
new aops.") added a check in cifs_write_begin(), but that check was soon
removed by commit a98ee8c1c707 ("[CIFS] fix regression in
cifs_write_begin/cifs_write_end").
Therefore, AOP_FLAG_UNINTERRUPTIBLE flag is checked nowhere. Let's
remove this flag. This patch has no functionality changes.
Link: http://lkml.kernel.org/r/1489294781-53494-1-git-send-email-penguin-kernel@I-love.SAKURA.ne.jp
Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Reviewed-by: Jeff Layton <jlayton@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Cc: Nick Piggin <npiggin@gmail.com>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/buffer.c')
-rw-r--r-- | fs/buffer.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/fs/buffer.c b/fs/buffer.c index 9196f2a270da..c3c7455efa3f 100644 --- a/fs/buffer.c +++ b/fs/buffer.c | |||
@@ -2379,8 +2379,7 @@ int generic_cont_expand_simple(struct inode *inode, loff_t size) | |||
2379 | goto out; | 2379 | goto out; |
2380 | 2380 | ||
2381 | err = pagecache_write_begin(NULL, mapping, size, 0, | 2381 | err = pagecache_write_begin(NULL, mapping, size, 0, |
2382 | AOP_FLAG_UNINTERRUPTIBLE|AOP_FLAG_CONT_EXPAND, | 2382 | AOP_FLAG_CONT_EXPAND, &page, &fsdata); |
2383 | &page, &fsdata); | ||
2384 | if (err) | 2383 | if (err) |
2385 | goto out; | 2384 | goto out; |
2386 | 2385 | ||
@@ -2415,9 +2414,8 @@ static int cont_expand_zero(struct file *file, struct address_space *mapping, | |||
2415 | } | 2414 | } |
2416 | len = PAGE_SIZE - zerofrom; | 2415 | len = PAGE_SIZE - zerofrom; |
2417 | 2416 | ||
2418 | err = pagecache_write_begin(file, mapping, curpos, len, | 2417 | err = pagecache_write_begin(file, mapping, curpos, len, 0, |
2419 | AOP_FLAG_UNINTERRUPTIBLE, | 2418 | &page, &fsdata); |
2420 | &page, &fsdata); | ||
2421 | if (err) | 2419 | if (err) |
2422 | goto out; | 2420 | goto out; |
2423 | zero_user(page, zerofrom, len); | 2421 | zero_user(page, zerofrom, len); |
@@ -2449,9 +2447,8 @@ static int cont_expand_zero(struct file *file, struct address_space *mapping, | |||
2449 | } | 2447 | } |
2450 | len = offset - zerofrom; | 2448 | len = offset - zerofrom; |
2451 | 2449 | ||
2452 | err = pagecache_write_begin(file, mapping, curpos, len, | 2450 | err = pagecache_write_begin(file, mapping, curpos, len, 0, |
2453 | AOP_FLAG_UNINTERRUPTIBLE, | 2451 | &page, &fsdata); |
2454 | &page, &fsdata); | ||
2455 | if (err) | 2452 | if (err) |
2456 | goto out; | 2453 | goto out; |
2457 | zero_user(page, zerofrom, len); | 2454 | zero_user(page, zerofrom, len); |