aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/xen
diff options
context:
space:
mode:
authorFrederico Cadete <frederico@cadete.eu>2013-05-25 16:48:57 -0400
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>2013-05-28 09:54:48 -0400
commit1d7004f0593f631b78745e4c835d8e09b31f4996 (patch)
treee8c832f881ea34ae24e8e74e307ebe69f043b70e /drivers/xen
parentfce92683570c2ddcdb82cde67b0b07800106fbd9 (diff)
xmem/tmem: fix 'undefined variable' build error.
In the (not so useful) kernel configuration where CONFIG_SWAP is undefined and CONFIG_XEN_SELFBALLOONING is defined, xen_tmem_init would use undefined variable 'static bool frontswap'. Added #else to have #define frontswap (0) in the case where CONFIG_FRONTSWAP is not defined. Signed-off-by: Frederico Cadete <frederico@cadete.eu> Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Diffstat (limited to 'drivers/xen')
-rw-r--r--drivers/xen/tmem.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/xen/tmem.c b/drivers/xen/tmem.c
index 18e8bd8fa947..cc072c66c766 100644
--- a/drivers/xen/tmem.c
+++ b/drivers/xen/tmem.c
@@ -41,6 +41,8 @@ module_param(selfballooning, bool, S_IRUGO);
41#ifdef CONFIG_FRONTSWAP 41#ifdef CONFIG_FRONTSWAP
42static bool frontswap __read_mostly = true; 42static bool frontswap __read_mostly = true;
43module_param(frontswap, bool, S_IRUGO); 43module_param(frontswap, bool, S_IRUGO);
44#else /* CONFIG_FRONTSWAP */
45#define frontswap (0)
44#endif /* CONFIG_FRONTSWAP */ 46#endif /* CONFIG_FRONTSWAP */
45 47
46#ifdef CONFIG_XEN_SELFBALLOONING 48#ifdef CONFIG_XEN_SELFBALLOONING