提交 b1f5b81e 编写于 作者: R Robert Jennings 提交者: Greg Kroah-Hartman

zram/xvmalloc: create CONFIG_ZRAM_DEBUG for debug code

Add a debug config flag to enable debug printk output and future
debug code.
Signed-off-by: NRobert Jennings <rcj@linux.vnet.ibm.com>
Reviewed-by: NPekka Enberg <penberg@kernel.org>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 e3f201b5
...@@ -15,3 +15,11 @@ config ZRAM ...@@ -15,3 +15,11 @@ config ZRAM
See zram.txt for more information. See zram.txt for more information.
Project home: http://compcache.googlecode.com/ Project home: http://compcache.googlecode.com/
config ZRAM_DEBUG
bool "Compressed RAM block device debug support"
depends on ZRAM
default n
help
This option adds additional debugging code to the compressed
RAM block device driver.
...@@ -10,6 +10,10 @@ ...@@ -10,6 +10,10 @@
* Released under the terms of GNU General Public License Version 2.0 * Released under the terms of GNU General Public License Version 2.0
*/ */
#ifdef CONFIG_ZRAM_DEBUG
#define DEBUG
#endif
#include <linux/bitops.h> #include <linux/bitops.h>
#include <linux/errno.h> #include <linux/errno.h>
#include <linux/highmem.h> #include <linux/highmem.h>
......
...@@ -15,6 +15,10 @@ ...@@ -15,6 +15,10 @@
#define KMSG_COMPONENT "zram" #define KMSG_COMPONENT "zram"
#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt #define pr_fmt(fmt) KMSG_COMPONENT ": " fmt
#ifdef CONFIG_ZRAM_DEBUG
#define DEBUG
#endif
#include <linux/module.h> #include <linux/module.h>
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/bio.h> #include <linux/bio.h>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册