aboutsummaryrefslogtreecommitdiffstats
path: root/fs/afs/write.c
diff options
context:
space:
mode:
authorNick Piggin <[email protected]>2008-08-02 10:01:03 +0000
committerLinus Torvalds <[email protected]>2008-08-05 04:31:34 +0000
commit529ae9aaa08378cfe2a4350bded76f32cc8ff0ce (patch)
treed3ae998f9876c72a83a022805103a92111852b21 /fs/afs/write.c
parentMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/sparc-2.6 (diff)
downloadkernel-529ae9aaa08378cfe2a4350bded76f32cc8ff0ce.tar.gz
kernel-529ae9aaa08378cfe2a4350bded76f32cc8ff0ce.zip
mm: rename page trylock
Converting page lock to new locking bitops requires a change of page flag operation naming, so we might as well convert it to something nicer (!TestSetPageLocked_Lock => trylock_page, SetPageLocked => set_page_locked). This also facilitates lockdeping of page lock. Signed-off-by: Nick Piggin <[email protected]> Acked-by: KOSAKI Motohiro <[email protected]> Acked-by: Peter Zijlstra <[email protected]> Acked-by: Andrew Morton <[email protected]> Acked-by: Benjamin Herrenschmidt <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'fs/afs/write.c')
-rw-r--r--fs/afs/write.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/afs/write.c b/fs/afs/write.c
index 9a849ad3c489..065b4e10681a 100644
--- a/fs/afs/write.c
+++ b/fs/afs/write.c
@@ -404,7 +404,7 @@ static int afs_write_back_from_locked_page(struct afs_writeback *wb,
page = pages[loop];
if (page->index > wb->last)
break;
- if (TestSetPageLocked(page))
+ if (!trylock_page(page))
break;
if (!PageDirty(page) ||
page_private(page) != (unsigned long) wb) {