]> Git Repo - linux.git/commit
mm: cleancache: lazy initialization to allow tmem backends to build/run as modules
authorDan Magenheimer <[email protected]>
Tue, 30 Apr 2013 22:26:56 +0000 (15:26 -0700)
committerLinus Torvalds <[email protected]>
Wed, 1 May 2013 00:04:01 +0000 (17:04 -0700)
commit49a9ab815acb8379a2f5fd43abe40038821e8f87
tree965226ce0574ce3906ba433bfcb11463c56eff24
parent4f89849da22db9d0edb378acea65e23fcd546173
mm: cleancache: lazy initialization to allow tmem backends to build/run as modules

With the goal of allowing tmem backends (zcache, ramster, Xen tmem) to
be built/loaded as modules rather than built-in and enabled by a boot
parameter, this patch provides "lazy initialization", allowing backends
to register to cleancache even after filesystems were mounted.  Calls to
init_fs and init_shared_fs are remembered as fake poolids but no real
tmem_pools created.  On backend registration the fake poolids are mapped
to real poolids and respective tmem_pools.

Signed-off-by: Stefan Hengelein <[email protected]>
Signed-off-by: Florian Schmaus <[email protected]>
Signed-off-by: Andor Daam <[email protected]>
Signed-off-by: Dan Magenheimer <[email protected]>
[v1: Minor fixes: used #define for some values and bools]
[v2: Removed CLEANCACHE_HAS_LAZY_INIT]
[v3: Added more comments, added a lock for [shared_|]fs_poolid_map]
Signed-off-by: Konrad Rzeszutek Wilk <[email protected]>
Signed-off-by: Bob Liu <[email protected]>
Cc: Wanpeng Li <[email protected]>
Cc: Minchan Kim <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
mm/cleancache.c
This page took 0.07643 seconds and 4 git commands to generate.