diff options
author | Zach Brown <zach.brown@oracle.com> | 2005-12-15 17:28:17 -0500 |
---|---|---|
committer | Joel Becker <joel.becker@oracle.com> | 2006-01-03 14:45:42 -0500 |
commit | 994fc28c7b1e697ac56befe4aecabf23f0689f46 (patch) | |
tree | da36d162e9bd077e9b5be385b28e2db90475c263 /mm/vmscan.c | |
parent | 7063fbf2261194f72ee75afca67b3b38b554b5fa (diff) |
[PATCH] add AOP_TRUNCATED_PAGE, prepend AOP_ to WRITEPAGE_ACTIVATE
readpage(), prepare_write(), and commit_write() callers are updated to
understand the special return code AOP_TRUNCATED_PAGE in the style of
writepage() and WRITEPAGE_ACTIVATE. AOP_TRUNCATED_PAGE tells the caller that
the callee has unlocked the page and that the operation should be tried again
with a new page. OCFS2 uses this to detect and work around a lock inversion in
its aop methods. There should be no change in behaviour for methods that don't
return AOP_TRUNCATED_PAGE.
WRITEPAGE_ACTIVATE is also prepended with AOP_ for consistency and they are
made enums so that kerneldoc can be used to document their semantics.
Signed-off-by: Zach Brown <zach.brown@oracle.com>
Diffstat (limited to 'mm/vmscan.c')
-rw-r--r-- | mm/vmscan.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/vmscan.c b/mm/vmscan.c index b0cd81c32de6..795a050fe471 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c | |||
@@ -367,7 +367,7 @@ static pageout_t pageout(struct page *page, struct address_space *mapping) | |||
367 | res = mapping->a_ops->writepage(page, &wbc); | 367 | res = mapping->a_ops->writepage(page, &wbc); |
368 | if (res < 0) | 368 | if (res < 0) |
369 | handle_write_error(mapping, page, res); | 369 | handle_write_error(mapping, page, res); |
370 | if (res == WRITEPAGE_ACTIVATE) { | 370 | if (res == AOP_WRITEPAGE_ACTIVATE) { |
371 | ClearPageReclaim(page); | 371 | ClearPageReclaim(page); |
372 | return PAGE_ACTIVATE; | 372 | return PAGE_ACTIVATE; |
373 | } | 373 | } |