aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/edac/edac_mc_sysfs.c
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@vrfy.org>2011-12-14 18:21:07 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2011-12-14 18:21:07 -0500
commitfe5ff8b84c8b03348a2f64ea9d884348faec2217 (patch)
tree8ad7290974ee129eee717a80846d25ea202fa21b /drivers/edac/edac_mc_sysfs.c
parent997d3eaf02cad6fdb54bd6085c9a7c48ddd68a2d (diff)
edac: convert sysdev_class to a regular subsystem
After all sysdev classes are ported to regular driver core entities, the sysdev implementation will be entirely removed from the kernel. Cc: Doug Thompson <dougthompson@xmission.com> Cc: Paul Gortmaker <paul.gortmaker@windriver.com> Cc: Lucas De Marchi <lucas.demarchi@profusion.mobi> Cc: Borislav Petkov <borislav.petkov@amd.com> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/edac/edac_mc_sysfs.c')
-rw-r--r--drivers/edac/edac_mc_sysfs.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/edac/edac_mc_sysfs.c b/drivers/edac/edac_mc_sysfs.c
index 29ffa350bfbe..d56e63477d5c 100644
--- a/drivers/edac/edac_mc_sysfs.c
+++ b/drivers/edac/edac_mc_sysfs.c
@@ -1021,19 +1021,19 @@ void edac_remove_sysfs_mci_device(struct mem_ctl_info *mci)
1021int edac_sysfs_setup_mc_kset(void) 1021int edac_sysfs_setup_mc_kset(void)
1022{ 1022{
1023 int err = -EINVAL; 1023 int err = -EINVAL;
1024 struct sysdev_class *edac_class; 1024 struct bus_type *edac_subsys;
1025 1025
1026 debugf1("%s()\n", __func__); 1026 debugf1("%s()\n", __func__);
1027 1027
1028 /* get the /sys/devices/system/edac class reference */ 1028 /* get the /sys/devices/system/edac subsys reference */
1029 edac_class = edac_get_sysfs_class(); 1029 edac_subsys = edac_get_sysfs_subsys();
1030 if (edac_class == NULL) { 1030 if (edac_subsys == NULL) {
1031 debugf1("%s() no edac_class error=%d\n", __func__, err); 1031 debugf1("%s() no edac_subsys error=%d\n", __func__, err);
1032 goto fail_out; 1032 goto fail_out;
1033 } 1033 }
1034 1034
1035 /* Init the MC's kobject */ 1035 /* Init the MC's kobject */
1036 mc_kset = kset_create_and_add("mc", NULL, &edac_class->kset.kobj); 1036 mc_kset = kset_create_and_add("mc", NULL, &edac_subsys->dev_root->kobj);
1037 if (!mc_kset) { 1037 if (!mc_kset) {
1038 err = -ENOMEM; 1038 err = -ENOMEM;
1039 debugf1("%s() Failed to register '.../edac/mc'\n", __func__); 1039 debugf1("%s() Failed to register '.../edac/mc'\n", __func__);
@@ -1045,7 +1045,7 @@ int edac_sysfs_setup_mc_kset(void)
1045 return 0; 1045 return 0;
1046 1046
1047fail_kset: 1047fail_kset:
1048 edac_put_sysfs_class(); 1048 edac_put_sysfs_subsys();
1049 1049
1050fail_out: 1050fail_out:
1051 return err; 1051 return err;
@@ -1059,6 +1059,6 @@ fail_out:
1059void edac_sysfs_teardown_mc_kset(void) 1059void edac_sysfs_teardown_mc_kset(void)
1060{ 1060{
1061 kset_unregister(mc_kset); 1061 kset_unregister(mc_kset);
1062 edac_put_sysfs_class(); 1062 edac_put_sysfs_subsys();
1063} 1063}
1064 1064