diff options
| -rw-r--r-- | arch/x86/kernel/kdebugfs.c | 8 | ||||
| -rw-r--r-- | include/linux/debugfs.h | 2 |
2 files changed, 10 insertions, 0 deletions
diff --git a/arch/x86/kernel/kdebugfs.c b/arch/x86/kernel/kdebugfs.c index c03205991718..f2d43bc75514 100644 --- a/arch/x86/kernel/kdebugfs.c +++ b/arch/x86/kernel/kdebugfs.c | |||
| @@ -12,9 +12,13 @@ | |||
| 12 | #include <linux/init.h> | 12 | #include <linux/init.h> |
| 13 | #include <linux/io.h> | 13 | #include <linux/io.h> |
| 14 | #include <linux/mm.h> | 14 | #include <linux/mm.h> |
| 15 | #include <linux/module.h> | ||
| 15 | 16 | ||
| 16 | #include <asm/setup.h> | 17 | #include <asm/setup.h> |
| 17 | 18 | ||
| 19 | struct dentry *arch_debugfs_dir; | ||
| 20 | EXPORT_SYMBOL(arch_debugfs_dir); | ||
| 21 | |||
| 18 | #ifdef CONFIG_DEBUG_BOOT_PARAMS | 22 | #ifdef CONFIG_DEBUG_BOOT_PARAMS |
| 19 | struct setup_data_node { | 23 | struct setup_data_node { |
| 20 | u64 paddr; | 24 | u64 paddr; |
| @@ -209,6 +213,10 @@ static int __init arch_kdebugfs_init(void) | |||
| 209 | { | 213 | { |
| 210 | int error = 0; | 214 | int error = 0; |
| 211 | 215 | ||
| 216 | arch_debugfs_dir = debugfs_create_dir("x86", NULL); | ||
| 217 | if (!arch_debugfs_dir) | ||
| 218 | return -ENOMEM; | ||
| 219 | |||
| 212 | #ifdef CONFIG_DEBUG_BOOT_PARAMS | 220 | #ifdef CONFIG_DEBUG_BOOT_PARAMS |
| 213 | error = boot_params_kdebugfs_init(); | 221 | error = boot_params_kdebugfs_init(); |
| 214 | #endif | 222 | #endif |
diff --git a/include/linux/debugfs.h b/include/linux/debugfs.h index 7266124361b4..32755cdf68db 100644 --- a/include/linux/debugfs.h +++ b/include/linux/debugfs.h | |||
| @@ -26,6 +26,8 @@ struct debugfs_blob_wrapper { | |||
| 26 | unsigned long size; | 26 | unsigned long size; |
| 27 | }; | 27 | }; |
| 28 | 28 | ||
| 29 | extern struct dentry *arch_debugfs_dir; | ||
| 30 | |||
| 29 | #if defined(CONFIG_DEBUG_FS) | 31 | #if defined(CONFIG_DEBUG_FS) |
| 30 | 32 | ||
| 31 | /* declared over in file.c */ | 33 | /* declared over in file.c */ |
