aboutsummaryrefslogtreecommitdiffstats
path: root/mm/swap.c
diff options
context:
space:
mode:
authorPeter Zijlstra <a.p.zijlstra@chello.nl>2007-10-17 02:25:46 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-17 11:42:45 -0400
commite0bf68ddec4f4f90e5871404be4f1854c17f3120 (patch)
tree36203a3558cbe26d698bed18be69b3822fb5eef2 /mm/swap.c
parentdc62a30e274d003a4d08fb888f1520add4b21373 (diff)
mm: bdi init hooks
provide BDI constructor/destructor hooks [akpm@linux-foundation.org: compile fix] Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/swap.c')
-rw-r--r--mm/swap.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/mm/swap.c b/mm/swap.c
index d034b2128d2b..a65eff8a517a 100644
--- a/mm/swap.c
+++ b/mm/swap.c
@@ -28,6 +28,7 @@
28#include <linux/percpu.h> 28#include <linux/percpu.h>
29#include <linux/cpu.h> 29#include <linux/cpu.h>
30#include <linux/notifier.h> 30#include <linux/notifier.h>
31#include <linux/backing-dev.h>
31 32
32/* How many pages do we try to swap or page in/out together? */ 33/* How many pages do we try to swap or page in/out together? */
33int page_cluster; 34int page_cluster;
@@ -547,6 +548,10 @@ void __init swap_setup(void)
547{ 548{
548 unsigned long megs = num_physpages >> (20 - PAGE_SHIFT); 549 unsigned long megs = num_physpages >> (20 - PAGE_SHIFT);
549 550
551#ifdef CONFIG_SWAP
552 bdi_init(swapper_space.backing_dev_info);
553#endif
554
550 /* Use a smaller cluster for small-memory machines */ 555 /* Use a smaller cluster for small-memory machines */
551 if (megs < 16) 556 if (megs < 16)
552 page_cluster = 2; 557 page_cluster = 2;