aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/base/sys.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-04 21:04:48 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-04 21:04:48 -0400
commit5b339915762d30b21995aa7263e74081f2f1110a (patch)
tree4e076dbd27025054b21dddd78a1cb3fef3de34d7 /drivers/base/sys.c
parent89661adaaee2f85116b399e642129ccd4dafd195 (diff)
parent823bccfc4002296ba88c3ad0f049e1abd8108d30 (diff)
Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6: remove "struct subsystem" as it is no longer needed sysfs: printk format warning DOC: Fix wrong identifier name in Documentation/driver-model/devres.txt platform: reorder platform_device_del Driver core: fix show_uevent from taking up way too much stack
Diffstat (limited to 'drivers/base/sys.c')
-rw-r--r--drivers/base/sys.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/base/sys.c b/drivers/base/sys.c
index 04e5db445c74..29f1291966c1 100644
--- a/drivers/base/sys.c
+++ b/drivers/base/sys.c
@@ -25,7 +25,7 @@
25 25
26#include "base.h" 26#include "base.h"
27 27
28extern struct subsystem devices_subsys; 28extern struct kset devices_subsys;
29 29
30#define to_sysdev(k) container_of(k, struct sys_device, kobj) 30#define to_sysdev(k) container_of(k, struct sys_device, kobj)
31#define to_sysdev_attr(a) container_of(a, struct sysdev_attribute, attr) 31#define to_sysdev_attr(a) container_of(a, struct sysdev_attribute, attr)
@@ -138,7 +138,7 @@ int sysdev_class_register(struct sysdev_class * cls)
138 pr_debug("Registering sysdev class '%s'\n", 138 pr_debug("Registering sysdev class '%s'\n",
139 kobject_name(&cls->kset.kobj)); 139 kobject_name(&cls->kset.kobj));
140 INIT_LIST_HEAD(&cls->drivers); 140 INIT_LIST_HEAD(&cls->drivers);
141 cls->kset.subsys = &system_subsys; 141 cls->kset.kobj.parent = &system_subsys.kobj;
142 kset_set_kset_s(cls, system_subsys); 142 kset_set_kset_s(cls, system_subsys);
143 return kset_register(&cls->kset); 143 return kset_register(&cls->kset);
144} 144}
@@ -309,7 +309,7 @@ void sysdev_shutdown(void)
309 pr_debug("Shutting Down System Devices\n"); 309 pr_debug("Shutting Down System Devices\n");
310 310
311 down(&sysdev_drivers_lock); 311 down(&sysdev_drivers_lock);
312 list_for_each_entry_reverse(cls, &system_subsys.kset.list, 312 list_for_each_entry_reverse(cls, &system_subsys.list,
313 kset.kobj.entry) { 313 kset.kobj.entry) {
314 struct sys_device * sysdev; 314 struct sys_device * sysdev;
315 315
@@ -384,7 +384,7 @@ int sysdev_suspend(pm_message_t state)
384 384
385 pr_debug("Suspending System Devices\n"); 385 pr_debug("Suspending System Devices\n");
386 386
387 list_for_each_entry_reverse(cls, &system_subsys.kset.list, 387 list_for_each_entry_reverse(cls, &system_subsys.list,
388 kset.kobj.entry) { 388 kset.kobj.entry) {
389 389
390 pr_debug("Suspending type '%s':\n", 390 pr_debug("Suspending type '%s':\n",
@@ -457,7 +457,7 @@ gbl_driver:
457 } 457 }
458 458
459 /* resume other classes */ 459 /* resume other classes */
460 list_for_each_entry_continue(cls, &system_subsys.kset.list, 460 list_for_each_entry_continue(cls, &system_subsys.list,
461 kset.kobj.entry) { 461 kset.kobj.entry) {
462 list_for_each_entry(err_dev, &cls->kset.list, kobj.entry) { 462 list_for_each_entry(err_dev, &cls->kset.list, kobj.entry) {
463 pr_debug(" %s\n", kobject_name(&err_dev->kobj)); 463 pr_debug(" %s\n", kobject_name(&err_dev->kobj));
@@ -483,7 +483,7 @@ int sysdev_resume(void)
483 483
484 pr_debug("Resuming System Devices\n"); 484 pr_debug("Resuming System Devices\n");
485 485
486 list_for_each_entry(cls, &system_subsys.kset.list, kset.kobj.entry) { 486 list_for_each_entry(cls, &system_subsys.list, kset.kobj.entry) {
487 struct sys_device * sysdev; 487 struct sys_device * sysdev;
488 488
489 pr_debug("Resuming type '%s':\n", 489 pr_debug("Resuming type '%s':\n",
@@ -501,7 +501,7 @@ int sysdev_resume(void)
501 501
502int __init system_bus_init(void) 502int __init system_bus_init(void)
503{ 503{
504 system_subsys.kset.kobj.parent = &devices_subsys.kset.kobj; 504 system_subsys.kobj.parent = &devices_subsys.kobj;
505 return subsystem_register(&system_subsys); 505 return subsystem_register(&system_subsys);
506} 506}
507 507