jbd: config_jbd_debug cannot create /proc entry
PATCH 17/144 jbd: config_jbd_debug cannot create /proc entry
From: "Jose R. Santos" <[email protected]>
The jbd-debug file used to be located in /proc/sys/fs/jbd-debug, but create_proc_entry() does not do lookups on file names that are more that one directory deep. This causes the entry creation to fail and hence, no proc file is created.
Instead of fixing this on procfs might as well move the jbd2-debug file to debugfs which would be the preferred location for this kind of tunable. The new location is now /sys/kernel/debug/jbd/jbd-debug.
[[email protected]: zillions of cleanups]
Signed-off-by Jose R. Santos <[email protected]>
Acked-by Jan Kara <[email protected]>
Cc <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
fs/Kconfig | 10 +++--- fs/jbd/journal.c | 64 +++++++++++++----------------------------- include/linux/jbd.h | 2 - 3 files changed, 27 insertions(+), 49 deletions(-)
fs/Kconfig renamed from fs/Kconfig~jbd-config_jbd_debug-cannot-create-proc-entry +5 -5
@@ -220,7 +220,7 @@ config JBD config JBD_DEBUG bool "JBD (ext3) debugging support" - depends on JBD + depends on JBD && DEBUG_FS help If you are using the ext3 journaled file system (or potentially any other file system/device using JBD), this option allows you to
@@ -229,10 +229,10 @@ config JBD_DEBUG debugging output will be turned off. If you select Y here, then you will be able to turn on debugging - with "echo N > /proc/sys/fs/jbd-debug", where N is a number between - 1 and 5, the higher the number, the more debugging output is - generated. To turn debugging off again, do - "echo 0 > /proc/sys/fs/jbd-debug". + with "echo N > /sys/kernel/debug/jbd/jbd-debug", where N is a + number between 1 and 5, the higher the number, the more debugging + output is generated. To turn debugging off again, do + "echo 0 > /sys/kernel/debug/jbd/jbd-debug". config JBD2 tristate
fs/jbd/journal.c renamed from fs/jbd/journal.c~jbd-config_jbd_debug-cannot-create-proc-entry +21 -43
105 lines not on this page · raw message
include/linux/jbd.h renamed from include/linux/jbd.h~jbd-config_jbd_debug-cannot-create-proc-entry +1 -1
@@ -58,7 +58,7 @@* CONFIG_JBD_DEBUG is on. */ #define JBD_EXPENSIVE_CHECKING -extern int journal_enable_debug; +extern u8 journal_enable_debug; #define jbd_debug(n, f, a...) \ do { \
_