diff options
author | Nick Piggin <npiggin@suse.de> | 2008-08-02 06:01:03 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-08-05 00:31:34 -0400 |
commit | 529ae9aaa08378cfe2a4350bded76f32cc8ff0ce (patch) | |
tree | d3ae998f9876c72a83a022805103a92111852b21 /mm/rmap.c | |
parent | e9ba9698187ddbc0c5bfcf41de0349a662d23d02 (diff) |
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 <npiggin@suse.de>
Acked-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Acked-by: Peter Zijlstra <peterz@infradead.org>
Acked-by: Andrew Morton <akpm@linux-foundation.org>
Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/rmap.c')
-rw-r--r-- | mm/rmap.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -422,7 +422,7 @@ int page_referenced(struct page *page, int is_locked, | |||
422 | referenced += page_referenced_anon(page, mem_cont); | 422 | referenced += page_referenced_anon(page, mem_cont); |
423 | else if (is_locked) | 423 | else if (is_locked) |
424 | referenced += page_referenced_file(page, mem_cont); | 424 | referenced += page_referenced_file(page, mem_cont); |
425 | else if (TestSetPageLocked(page)) | 425 | else if (!trylock_page(page)) |
426 | referenced++; | 426 | referenced++; |
427 | else { | 427 | else { |
428 | if (page->mapping) | 428 | if (page->mapping) |