lkml.org 
[lkml]   [2012]   [Nov]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 09/11] zcache: Allow to compile if ZCACHE_DEBUG and !DEBUG_FS
Date
is defined.

Reviewed-by: Dan Magenheimer <dan.magenheimer@oracle.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
---
drivers/staging/ramster/debug.h | 14 +++++++++-----
1 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/ramster/debug.h b/drivers/staging/ramster/debug.h
index 35af06d..b412b90 100644
--- a/drivers/staging/ramster/debug.h
+++ b/drivers/staging/ramster/debug.h
@@ -174,7 +174,6 @@ static inline void inc_zcache_evicted_eph_pageframes(void) { zcache_evicted_eph_
static inline void inc_zcache_eph_nonactive_puts_ignored(void) { zcache_eph_nonactive_puts_ignored ++; };
static inline void inc_zcache_pers_nonactive_puts_ignored(void) { zcache_pers_nonactive_puts_ignored ++; };

-int zcache_debugfs_init(void);
#else
static inline void inc_zcache_obj_count(void) { };
static inline void dec_zcache_obj_count(void) { };
@@ -198,10 +197,6 @@ static inline unsigned long curr_pageframes_count(void)
{
return 0;
};
-static inline int zcache_debugfs_init(void)
-{
- return 0;
-};
static inline void inc_zcache_flush_total(void) { };
static inline void inc_zcache_flush_found(void) { };
static inline void inc_zcache_flobj_total(void) { };
@@ -223,3 +218,12 @@ static inline void inc_zcache_evicted_eph_pageframes(void) { };
static inline void inc_zcache_eph_nonactive_puts_ignored(void) { };
static inline void inc_zcache_pers_nonactive_puts_ignored(void) { };
#endif
+
+#ifdef CONFIG_DEBUG_FS
+int zcache_debugfs_init(void);
+#else
+static inline int zcache_debugfs_init(void)
+{
+ return 0;
+};
+#endif
--
1.7.7.6


\
 
 \ /
  Last update: 2012-11-14 21:01    [W:0.137 / U:0.940 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site