diff options
author | Kay Sievers <kay.sievers@vrfy.org> | 2007-11-02 08:47:53 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2008-01-24 23:40:18 -0500 |
commit | eb41d9465cdafee45e0cb30f3b7338646221908e (patch) | |
tree | a2e5d62c8b1bd48d5b20515b541096709fe184e0 /include/linux/sched.h | |
parent | 386f275f5d097758f867bc99ddeaeb7a03b6b190 (diff) |
fix struct user_info export's sysfs interaction
Clean up the use of ksets and kobjects. Kobjects are instances of
objects (like struct user_info), ksets are collections of objects of a
similar type (like the uids directory containing the user_info directories).
So, use kobjects for the user_info directories, and a kset for the "uids"
directory.
On object cleanup, the final kobject_put() was missing.
Cc: Dhaval Giani <dhaval@linux.vnet.ibm.com>
Cc: Srivatsa Vaddagiri <vatsa@linux.vnet.ibm.com>
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'include/linux/sched.h')
-rw-r--r-- | include/linux/sched.h | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index cc14656f8682..d6eacda765ca 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -552,18 +552,13 @@ struct user_struct { | |||
552 | #ifdef CONFIG_FAIR_USER_SCHED | 552 | #ifdef CONFIG_FAIR_USER_SCHED |
553 | struct task_group *tg; | 553 | struct task_group *tg; |
554 | #ifdef CONFIG_SYSFS | 554 | #ifdef CONFIG_SYSFS |
555 | struct kset kset; | 555 | struct kobject kobj; |
556 | struct subsys_attribute user_attr; | ||
557 | struct work_struct work; | 556 | struct work_struct work; |
558 | #endif | 557 | #endif |
559 | #endif | 558 | #endif |
560 | }; | 559 | }; |
561 | 560 | ||
562 | #ifdef CONFIG_FAIR_USER_SCHED | 561 | extern int uids_sysfs_init(void); |
563 | extern int uids_kobject_init(void); | ||
564 | #else | ||
565 | static inline int uids_kobject_init(void) { return 0; } | ||
566 | #endif | ||
567 | 562 | ||
568 | extern struct user_struct *find_user(uid_t); | 563 | extern struct user_struct *find_user(uid_t); |
569 | 564 | ||