diff options
author | Sage Weil <sage@newdream.net> | 2009-11-12 18:05:52 -0500 |
---|---|---|
committer | Sage Weil <sage@newdream.net> | 2009-11-12 18:56:51 -0500 |
commit | 039934b895c89c2bb40aa5132efe00e60b70efca (patch) | |
tree | cb29a509f2fcf6423191beb8b6aec6e20b89ee14 /fs/ceph | |
parent | fef320ff8887c702cde7ca6b8dbfff3a341d49fe (diff) |
ceph: build cleanly without CONFIG_DEBUG_FS
Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'fs/ceph')
-rw-r--r-- | fs/ceph/debugfs.c | 23 | ||||
-rw-r--r-- | fs/ceph/mds_client.h | 2 | ||||
-rw-r--r-- | fs/ceph/mon_client.h | 2 | ||||
-rw-r--r-- | fs/ceph/osd_client.h | 2 | ||||
-rw-r--r-- | fs/ceph/super.h | 2 |
5 files changed, 31 insertions, 0 deletions
diff --git a/fs/ceph/debugfs.c b/fs/ceph/debugfs.c index 9edbad32f116..9b2020696680 100644 --- a/fs/ceph/debugfs.c +++ b/fs/ceph/debugfs.c | |||
@@ -8,6 +8,8 @@ | |||
8 | #include "super.h" | 8 | #include "super.h" |
9 | #include "mds_client.h" | 9 | #include "mds_client.h" |
10 | 10 | ||
11 | #ifdef CONFIG_DEBUG_FS | ||
12 | |||
11 | /* | 13 | /* |
12 | * Implement /sys/kernel/debug/ceph fun | 14 | * Implement /sys/kernel/debug/ceph fun |
13 | * | 15 | * |
@@ -423,3 +425,24 @@ void ceph_debugfs_client_cleanup(struct ceph_client *client) | |||
423 | debugfs_remove(client->debugfs_dir); | 425 | debugfs_remove(client->debugfs_dir); |
424 | } | 426 | } |
425 | 427 | ||
428 | #else // CONFIG_DEBUG_FS | ||
429 | |||
430 | int __init ceph_debugfs_init(void) | ||
431 | { | ||
432 | return 0; | ||
433 | } | ||
434 | |||
435 | void ceph_debugfs_cleanup(void) | ||
436 | { | ||
437 | } | ||
438 | |||
439 | int ceph_debugfs_client_init(struct ceph_client *client) | ||
440 | { | ||
441 | return 0; | ||
442 | } | ||
443 | |||
444 | void ceph_debugfs_client_cleanup(struct ceph_client *client) | ||
445 | { | ||
446 | } | ||
447 | |||
448 | #endif // CONFIG_DEBUG_FS | ||
diff --git a/fs/ceph/mds_client.h b/fs/ceph/mds_client.h index f566e9c84295..0751b821f231 100644 --- a/fs/ceph/mds_client.h +++ b/fs/ceph/mds_client.h | |||
@@ -256,7 +256,9 @@ struct ceph_mds_client { | |||
256 | spinlock_t cap_dirty_lock; /* protects above items */ | 256 | spinlock_t cap_dirty_lock; /* protects above items */ |
257 | wait_queue_head_t cap_flushing_wq; | 257 | wait_queue_head_t cap_flushing_wq; |
258 | 258 | ||
259 | #ifdef CONFIG_DEBUG_FS | ||
259 | struct dentry *debugfs_file; | 260 | struct dentry *debugfs_file; |
261 | #endif | ||
260 | 262 | ||
261 | spinlock_t dentry_lru_lock; | 263 | spinlock_t dentry_lru_lock; |
262 | struct list_head dentry_lru; | 264 | struct list_head dentry_lru; |
diff --git a/fs/ceph/mon_client.h b/fs/ceph/mon_client.h index 5258c5693b03..9f6db45bf469 100644 --- a/fs/ceph/mon_client.h +++ b/fs/ceph/mon_client.h | |||
@@ -78,7 +78,9 @@ struct ceph_mon_client { | |||
78 | int want_next_osdmap; /* 1 = want, 2 = want+asked */ | 78 | int want_next_osdmap; /* 1 = want, 2 = want+asked */ |
79 | u32 have_osdmap, have_mdsmap; | 79 | u32 have_osdmap, have_mdsmap; |
80 | 80 | ||
81 | #ifdef CONFIG_DEBUG_FS | ||
81 | struct dentry *debugfs_file; | 82 | struct dentry *debugfs_file; |
83 | #endif | ||
82 | }; | 84 | }; |
83 | 85 | ||
84 | extern struct ceph_monmap *ceph_monmap_decode(void *p, void *end); | 86 | extern struct ceph_monmap *ceph_monmap_decode(void *p, void *end); |
diff --git a/fs/ceph/osd_client.h b/fs/ceph/osd_client.h index 9a4addf7d651..766c8dc80aff 100644 --- a/fs/ceph/osd_client.h +++ b/fs/ceph/osd_client.h | |||
@@ -83,7 +83,9 @@ struct ceph_osd_client { | |||
83 | struct rb_root requests; /* pending requests */ | 83 | struct rb_root requests; /* pending requests */ |
84 | int num_requests; | 84 | int num_requests; |
85 | struct delayed_work timeout_work; | 85 | struct delayed_work timeout_work; |
86 | #ifdef CONFIG_DEBUG_FS | ||
86 | struct dentry *debugfs_file; | 87 | struct dentry *debugfs_file; |
88 | #endif | ||
87 | 89 | ||
88 | mempool_t *req_mempool; | 90 | mempool_t *req_mempool; |
89 | 91 | ||
diff --git a/fs/ceph/super.h b/fs/ceph/super.h index 06b62c02f513..8aa1ffba6c0d 100644 --- a/fs/ceph/super.h +++ b/fs/ceph/super.h | |||
@@ -112,9 +112,11 @@ static inline unsigned long time_sub(unsigned long a, unsigned long b) | |||
112 | */ | 112 | */ |
113 | struct ceph_client { | 113 | struct ceph_client { |
114 | __s64 whoami; /* my client number */ | 114 | __s64 whoami; /* my client number */ |
115 | #ifdef CONFIG_DEBUG_FS | ||
115 | struct dentry *debugfs_monmap; | 116 | struct dentry *debugfs_monmap; |
116 | struct dentry *debugfs_mdsmap, *debugfs_osdmap; | 117 | struct dentry *debugfs_mdsmap, *debugfs_osdmap; |
117 | struct dentry *debugfs_dir, *debugfs_dentry_lru, *debugfs_caps; | 118 | struct dentry *debugfs_dir, *debugfs_dentry_lru, *debugfs_caps; |
119 | #endif | ||
118 | 120 | ||
119 | struct mutex mount_mutex; /* serialize mount attempts */ | 121 | struct mutex mount_mutex; /* serialize mount attempts */ |
120 | struct ceph_mount_args *mount_args; | 122 | struct ceph_mount_args *mount_args; |