]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mm: frontswap: add swap hooks and extend try_to_unuse
authorDan Magenheimer <dan.magenheimer@oracle.com>
Tue, 30 Aug 2011 14:05:59 +0000 (08:05 -0600)
committerDan Magenheimer <dan.magenheimer@oracle.com>
Tue, 30 Aug 2011 14:05:59 +0000 (08:05 -0600)
commit2a728af502026984468479454f72c416d7612c36
tree7d0426c93c8f4667ef40e8b757a7e21125f9bcae
parentbfc8948870d64ed098cd181bcbb92fb4fb0966a0
mm: frontswap: add swap hooks and extend try_to_unuse

This third patch of four in the frontswap series adds hooks in the swap
subsystem and extends try_to_unuse so that frontswap_shrink can do a
"partial swapoff".  Also, declarations for the extern-ified swap variables
in the first patch are declared.

Note that failed frontswap_map allocation is safe... failure is noted
by lack of "FS" in the subsequent printk.

[v8: rebase to 3.0-rc4]
[v8: kamezawa.hiroyu@jp.fujitsu.com: add comment to clarify find_next_to_unuse]
[v7: rebase to 3.0-rc3]
[v7: JBeulich@novell.com: use new static inlines, no-ops if not config'd]
[v6: rebase to 3.1-rc1]
[v6: lliubbo@gmail.com: use vzalloc]
[v6: lliubbo@gmail.com: fix null pointer deref if vzalloc fails]
[v5: accidentally posted stale code for v4 that failed to compile :-(]
[v4: rebase to 2.6.39]
Signed-off-by: Dan Magenheimer <dan.magenheimer@oracle.com>
Reviewed-by: Konrad Wilk <konrad.wilk@oracle.com>
Acked-by: Jan Beulich <JBeulich@novell.com>
Acked-by: Seth Jennings <sjenning@linux.vnet.ibm.com>
Cc: Jeremy Fitzhardinge <jeremy@goop.org>
Cc: Hugh Dickins <hughd@google.com>
Cc: Johannes Weiner <hannes@cmpxchg.org>
Cc: Nitin Gupta <ngupta@vflare.org>
Cc: Matthew Wilcox <matthew@wil.cx>
Cc: Chris Mason <chris.mason@oracle.com>
Cc: Rik Riel <riel@redhat.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
mm/page_io.c
mm/swapfile.c