提交 1d7004f0 编写于 作者: F Frederico Cadete 提交者: Konrad Rzeszutek Wilk

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: NFrederico Cadete <frederico@cadete.eu>
Signed-off-by: NKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
上级 fce92683
...@@ -41,6 +41,8 @@ module_param(selfballooning, bool, S_IRUGO); ...@@ -41,6 +41,8 @@ module_param(selfballooning, bool, S_IRUGO);
#ifdef CONFIG_FRONTSWAP #ifdef CONFIG_FRONTSWAP
static bool frontswap __read_mostly = true; static bool frontswap __read_mostly = true;
module_param(frontswap, bool, S_IRUGO); module_param(frontswap, bool, S_IRUGO);
#else /* CONFIG_FRONTSWAP */
#define frontswap (0)
#endif /* CONFIG_FRONTSWAP */ #endif /* CONFIG_FRONTSWAP */
#ifdef CONFIG_XEN_SELFBALLOONING #ifdef CONFIG_XEN_SELFBALLOONING
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册