Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 105298
b: refs/heads/master
c: ff7ea79
h: refs/heads/master
v: v3
  • Loading branch information
Nishanth Aravamudan authored and Linus Torvalds committed Jul 24, 2008
1 parent 71c1e62 commit f8f9e5b
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5e9426abe209cf134adbbd62c5e73ef534eb73e9
refs/heads/master: ff7ea79cf7c3a481851bd4b2185fdeb6ce4afa29
6 changes: 6 additions & 0 deletions trunk/Documentation/ABI/testing/sysfs-kernel-mm
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
What: /sys/kernel/mm
Date: July 2008
Contact: Nishanth Aravamudan <nacc@us.ibm.com>, VM maintainers
Description:
/sys/kernel/mm/ should contain any and all VM
related information in /sys/kernel/.
2 changes: 2 additions & 0 deletions trunk/include/linux/kobject.h
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,8 @@ extern struct kobject *kset_find_obj(struct kset *, const char *);

/* The global /sys/kernel/ kobject for people to chain off of */
extern struct kobject *kernel_kobj;
/* The global /sys/kernel/mm/ kobject for people to chain off of */
extern struct kobject *mm_kobj;
/* The global /sys/hypervisor/ kobject for people to chain off of */
extern struct kobject *hypervisor_kobj;
/* The global /sys/power/ kobject for people to chain off of */
Expand Down
16 changes: 16 additions & 0 deletions trunk/mm/mm_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
*/
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/kobject.h>
#include <linux/module.h>
#include "internal.h"

#ifdef CONFIG_DEBUG_MEMORY_INIT
Expand Down Expand Up @@ -134,3 +136,17 @@ static __init int set_mminit_loglevel(char *str)
}
early_param("mminit_loglevel", set_mminit_loglevel);
#endif /* CONFIG_DEBUG_MEMORY_INIT */

struct kobject *mm_kobj;
EXPORT_SYMBOL_GPL(mm_kobj);

static int __init mm_sysfs_init(void)
{
mm_kobj = kobject_create_and_add("mm", kernel_kobj);
if (!mm_kobj)
return -ENOMEM;

return 0;
}

__initcall(mm_sysfs_init);

0 comments on commit f8f9e5b

Please sign in to comment.