diff options
Diffstat (limited to 'fs')
-rw-r--r-- | fs/ocfs2/cluster/netdebug.c | 20 | ||||
-rw-r--r-- | fs/ocfs2/dlm/dlmdebug.c | 22 |
2 files changed, 15 insertions, 27 deletions
diff --git a/fs/ocfs2/cluster/netdebug.c b/fs/ocfs2/cluster/netdebug.c index a3f150e52b02..0edf836b42d5 100644 --- a/fs/ocfs2/cluster/netdebug.c +++ b/fs/ocfs2/cluster/netdebug.c | |||
@@ -141,7 +141,7 @@ static int nst_seq_show(struct seq_file *seq, void *v) | |||
141 | " sock acquiry: %lu.%ld\n" | 141 | " sock acquiry: %lu.%ld\n" |
142 | " send start: %lu.%ld\n" | 142 | " send start: %lu.%ld\n" |
143 | " wait start: %lu.%ld\n", | 143 | " wait start: %lu.%ld\n", |
144 | nst, (unsigned long)nst->st_task->pid, | 144 | nst, (unsigned long)task_pid_nr(nst->st_task), |
145 | (unsigned long)nst->st_task->tgid, | 145 | (unsigned long)nst->st_task->tgid, |
146 | nst->st_task->comm, nst->st_node, | 146 | nst->st_task->comm, nst->st_node, |
147 | nst->st_sc, nst->st_id, nst->st_msg_type, | 147 | nst->st_sc, nst->st_id, nst->st_msg_type, |
@@ -421,23 +421,17 @@ int o2net_debugfs_init(void) | |||
421 | 421 | ||
422 | return 0; | 422 | return 0; |
423 | bail: | 423 | bail: |
424 | if (sc_dentry) | 424 | debugfs_remove(sc_dentry); |
425 | debugfs_remove(sc_dentry); | 425 | debugfs_remove(nst_dentry); |
426 | if (nst_dentry) | 426 | debugfs_remove(o2net_dentry); |
427 | debugfs_remove(nst_dentry); | ||
428 | if (o2net_dentry) | ||
429 | debugfs_remove(o2net_dentry); | ||
430 | return -ENOMEM; | 427 | return -ENOMEM; |
431 | } | 428 | } |
432 | 429 | ||
433 | void o2net_debugfs_exit(void) | 430 | void o2net_debugfs_exit(void) |
434 | { | 431 | { |
435 | if (sc_dentry) | 432 | debugfs_remove(sc_dentry); |
436 | debugfs_remove(sc_dentry); | 433 | debugfs_remove(nst_dentry); |
437 | if (nst_dentry) | 434 | debugfs_remove(o2net_dentry); |
438 | debugfs_remove(nst_dentry); | ||
439 | if (o2net_dentry) | ||
440 | debugfs_remove(o2net_dentry); | ||
441 | } | 435 | } |
442 | 436 | ||
443 | #endif /* CONFIG_DEBUG_FS */ | 437 | #endif /* CONFIG_DEBUG_FS */ |
diff --git a/fs/ocfs2/dlm/dlmdebug.c b/fs/ocfs2/dlm/dlmdebug.c index 77199ca4409a..04a32be0aeb9 100644 --- a/fs/ocfs2/dlm/dlmdebug.c +++ b/fs/ocfs2/dlm/dlmdebug.c | |||
@@ -743,7 +743,7 @@ static int debug_state_print(struct dlm_ctxt *dlm, char *buf, int len) | |||
743 | /* Thread Pid: xxx Node: xxx State: xxxxx */ | 743 | /* Thread Pid: xxx Node: xxx State: xxxxx */ |
744 | out += snprintf(buf + out, len - out, | 744 | out += snprintf(buf + out, len - out, |
745 | "Thread Pid: %d Node: %d State: %s\n", | 745 | "Thread Pid: %d Node: %d State: %s\n", |
746 | dlm->dlm_thread_task->pid, dlm->node_num, state); | 746 | task_pid_nr(dlm->dlm_thread_task), dlm->node_num, state); |
747 | 747 | ||
748 | /* Number of Joins: xxx Joining Node: xxx */ | 748 | /* Number of Joins: xxx Joining Node: xxx */ |
749 | out += snprintf(buf + out, len - out, | 749 | out += snprintf(buf + out, len - out, |
@@ -823,7 +823,7 @@ static int debug_state_print(struct dlm_ctxt *dlm, char *buf, int len) | |||
823 | /* Recovery Pid: xxxx Master: xxx State: xxxx */ | 823 | /* Recovery Pid: xxxx Master: xxx State: xxxx */ |
824 | out += snprintf(buf + out, len - out, | 824 | out += snprintf(buf + out, len - out, |
825 | "Recovery Pid: %d Master: %d State: %s\n", | 825 | "Recovery Pid: %d Master: %d State: %s\n", |
826 | dlm->dlm_reco_thread_task->pid, | 826 | task_pid_nr(dlm->dlm_reco_thread_task), |
827 | dlm->reco.new_master, state); | 827 | dlm->reco.new_master, state); |
828 | 828 | ||
829 | /* Recovery Map: xx xx */ | 829 | /* Recovery Map: xx xx */ |
@@ -956,14 +956,10 @@ void dlm_debug_shutdown(struct dlm_ctxt *dlm) | |||
956 | struct dlm_debug_ctxt *dc = dlm->dlm_debug_ctxt; | 956 | struct dlm_debug_ctxt *dc = dlm->dlm_debug_ctxt; |
957 | 957 | ||
958 | if (dc) { | 958 | if (dc) { |
959 | if (dc->debug_purgelist_dentry) | 959 | debugfs_remove(dc->debug_purgelist_dentry); |
960 | debugfs_remove(dc->debug_purgelist_dentry); | 960 | debugfs_remove(dc->debug_mle_dentry); |
961 | if (dc->debug_mle_dentry) | 961 | debugfs_remove(dc->debug_lockres_dentry); |
962 | debugfs_remove(dc->debug_mle_dentry); | 962 | debugfs_remove(dc->debug_state_dentry); |
963 | if (dc->debug_lockres_dentry) | ||
964 | debugfs_remove(dc->debug_lockres_dentry); | ||
965 | if (dc->debug_state_dentry) | ||
966 | debugfs_remove(dc->debug_state_dentry); | ||
967 | dlm_debug_put(dc); | 963 | dlm_debug_put(dc); |
968 | } | 964 | } |
969 | } | 965 | } |
@@ -994,8 +990,7 @@ bail: | |||
994 | 990 | ||
995 | void dlm_destroy_debugfs_subroot(struct dlm_ctxt *dlm) | 991 | void dlm_destroy_debugfs_subroot(struct dlm_ctxt *dlm) |
996 | { | 992 | { |
997 | if (dlm->dlm_debugfs_subroot) | 993 | debugfs_remove(dlm->dlm_debugfs_subroot); |
998 | debugfs_remove(dlm->dlm_debugfs_subroot); | ||
999 | } | 994 | } |
1000 | 995 | ||
1001 | /* debugfs root */ | 996 | /* debugfs root */ |
@@ -1011,7 +1006,6 @@ int dlm_create_debugfs_root(void) | |||
1011 | 1006 | ||
1012 | void dlm_destroy_debugfs_root(void) | 1007 | void dlm_destroy_debugfs_root(void) |
1013 | { | 1008 | { |
1014 | if (dlm_debugfs_root) | 1009 | debugfs_remove(dlm_debugfs_root); |
1015 | debugfs_remove(dlm_debugfs_root); | ||
1016 | } | 1010 | } |
1017 | #endif /* CONFIG_DEBUG_FS */ | 1011 | #endif /* CONFIG_DEBUG_FS */ |