Skip to content

Commit

Permalink
x86: Add a arch directory for x86 under debugfs
Browse files Browse the repository at this point in the history
Add a directory for x86 arch under debugfs. Can be used to accumulate all
x86 specific debugfs files.

Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
  • Loading branch information
venkatesh.pallipadi@intel.com authored and H. Peter Anvin committed Jul 19, 2008
1 parent 50515af commit ae79cda
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
8 changes: 8 additions & 0 deletions arch/x86/kernel/kdebugfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,13 @@
#include <linux/init.h>
#include <linux/io.h>
#include <linux/mm.h>
#include <linux/module.h>

#include <asm/setup.h>

struct dentry *arch_debugfs_dir;
EXPORT_SYMBOL(arch_debugfs_dir);

#ifdef CONFIG_DEBUG_BOOT_PARAMS
struct setup_data_node {
u64 paddr;
Expand Down Expand Up @@ -209,6 +213,10 @@ static int __init arch_kdebugfs_init(void)
{
int error = 0;

arch_debugfs_dir = debugfs_create_dir("x86", NULL);
if (!arch_debugfs_dir)
return -ENOMEM;

#ifdef CONFIG_DEBUG_BOOT_PARAMS
error = boot_params_kdebugfs_init();
#endif
Expand Down
2 changes: 2 additions & 0 deletions include/linux/debugfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ struct debugfs_blob_wrapper {
unsigned long size;
};

extern struct dentry *arch_debugfs_dir;

#if defined(CONFIG_DEBUG_FS)

/* declared over in file.c */
Expand Down

0 comments on commit ae79cda

Please sign in to comment.