summaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/dlm/dlmdebug.h
diff options
context:
space:
mode:
authorSunil Mushran <sunil.mushran@oracle.com>2008-03-10 23:16:23 +0100
committerMark Fasheh <mfasheh@suse.com>2008-04-18 17:56:08 +0200
commit007dce53a29ccffc000ab5373d188f73881390fd (patch)
tree84ce6e26cc3bed0cb2e041b1a4aabca3449498ff /fs/ocfs2/dlm/dlmdebug.h
parentocfs2/dlm: Create debugfs dirs (diff)
downloadlinux-007dce53a29ccffc000ab5373d188f73881390fd.tar.xz
linux-007dce53a29ccffc000ab5373d188f73881390fd.zip
ocfs2/dlm: Dump the dlm state in a debugfs file
This patch dumps the dlm state (dlm_ctxt) into a debugfs file. Useful for debugging. Signed-off-by: Sunil Mushran <sunil.mushran@oracle.com> Signed-off-by: Joel Becker <joel.becker@oracle.com> Signed-off-by: Mark Fasheh <mfasheh@suse.com>
Diffstat (limited to '')
-rw-r--r--fs/ocfs2/dlm/dlmdebug.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/fs/ocfs2/dlm/dlmdebug.h b/fs/ocfs2/dlm/dlmdebug.h
index b96959512d96..94cc10a4e19c 100644
--- a/fs/ocfs2/dlm/dlmdebug.h
+++ b/fs/ocfs2/dlm/dlmdebug.h
@@ -27,6 +27,19 @@
#ifdef CONFIG_DEBUG_FS
+struct dlm_debug_ctxt {
+ struct kref debug_refcnt;
+ struct dentry *debug_state_dentry;
+};
+
+struct debug_buffer {
+ int len;
+ char *buf;
+};
+
+int dlm_debug_init(struct dlm_ctxt *dlm);
+void dlm_debug_shutdown(struct dlm_ctxt *dlm);
+
int dlm_create_debugfs_subroot(struct dlm_ctxt *dlm);
void dlm_destroy_debugfs_subroot(struct dlm_ctxt *dlm);
@@ -35,6 +48,13 @@ void dlm_destroy_debugfs_root(void);
#else
+static int dlm_debug_init(struct dlm_ctxt *dlm)
+{
+ return 0;
+}
+static void dlm_debug_shutdown(struct dlm_ctxt *dlm)
+{
+}
static int dlm_create_debugfs_subroot(struct dlm_ctxt *dlm)
{
return 0;