diff options
author | Matthew Wilcox <mawilcox@microsoft.com> | 2018-04-10 19:36:56 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2018-04-11 13:28:39 -0400 |
commit | b93b016313b3ba8003c3b8bb71f569af91f19fc7 (patch) | |
tree | ad4be96414189dcdf8c972f351ba430996e9fdff /fs/afs/write.c | |
parent | f6bb2a2c0b81c47282ddb7883f92e65a063c27dd (diff) |
page cache: use xa_lock
Remove the address_space ->tree_lock and use the xa_lock newly added to
the radix_tree_root. Rename the address_space ->page_tree to ->i_pages,
since we don't really care that it's a tree.
[willy@infradead.org: fix nds32, fs/dax.c]
Link: http://lkml.kernel.org/r/20180406145415.GB20605@bombadil.infradead.orgLink: http://lkml.kernel.org/r/20180313132639.17387-9-willy@infradead.org
Signed-off-by: Matthew Wilcox <mawilcox@microsoft.com>
Acked-by: Jeff Layton <jlayton@redhat.com>
Cc: Darrick J. Wong <darrick.wong@oracle.com>
Cc: Dave Chinner <david@fromorbit.com>
Cc: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/afs/write.c')
-rw-r--r-- | fs/afs/write.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/fs/afs/write.c b/fs/afs/write.c index 9370e2feb999..dbc3c0b0142d 100644 --- a/fs/afs/write.c +++ b/fs/afs/write.c | |||
@@ -570,10 +570,11 @@ static int afs_writepages_region(struct address_space *mapping, | |||
570 | 570 | ||
571 | _debug("wback %lx", page->index); | 571 | _debug("wback %lx", page->index); |
572 | 572 | ||
573 | /* at this point we hold neither mapping->tree_lock nor lock on | 573 | /* |
574 | * the page itself: the page may be truncated or invalidated | 574 | * at this point we hold neither the i_pages lock nor the |
575 | * (changing page->mapping to NULL), or even swizzled back from | 575 | * page lock: the page may be truncated or invalidated |
576 | * swapper_space to tmpfs file mapping | 576 | * (changing page->mapping to NULL), or even swizzled |
577 | * back from swapper_space to tmpfs file mapping | ||
577 | */ | 578 | */ |
578 | ret = lock_page_killable(page); | 579 | ret = lock_page_killable(page); |
579 | if (ret < 0) { | 580 | if (ret < 0) { |