aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/edac/edac_device_sysfs.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2012-01-06 14:42:52 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2012-01-06 14:42:52 -0500
commitff4b8a57f0aaa2882d444ca44b2b9b333d22a4df (patch)
treed851c923f85566572112d4c0f884cff388a3cc05 /drivers/edac/edac_device_sysfs.c
parent805a6af8dba5dfdd35ec35dc52ec0122400b2610 (diff)
parentea04018e6bc5ddb2f0466c0e5b986bd4901b7e8e (diff)
Merge branch 'driver-core-next' into Linux 3.2
This resolves the conflict in the arch/arm/mach-s3c64xx/s3c6400.c file, and it fixes the build error in the arch/x86/kernel/microcode_core.c file, that the merge did not catch. The microcode_core.c patch was provided by Stephen Rothwell <sfr@canb.auug.org.au> who was invaluable in the merge issues involved with the large sysdev removal process in the driver-core tree. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/edac/edac_device_sysfs.c')
-rw-r--r--drivers/edac/edac_device_sysfs.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/edac/edac_device_sysfs.c b/drivers/edac/edac_device_sysfs.c
index 86649df00285..b4ea185ccebf 100644
--- a/drivers/edac/edac_device_sysfs.c
+++ b/drivers/edac/edac_device_sysfs.c
@@ -1,5 +1,5 @@
1/* 1/*
2 * file for managing the edac_device class of devices for EDAC 2 * file for managing the edac_device subsystem of devices for EDAC
3 * 3 *
4 * (C) 2007 SoftwareBitMaker 4 * (C) 2007 SoftwareBitMaker
5 * 5 *
@@ -230,21 +230,21 @@ static struct kobj_type ktype_device_ctrl = {
230 */ 230 */
231int edac_device_register_sysfs_main_kobj(struct edac_device_ctl_info *edac_dev) 231int edac_device_register_sysfs_main_kobj(struct edac_device_ctl_info *edac_dev)
232{ 232{
233 struct sysdev_class *edac_class; 233 struct bus_type *edac_subsys;
234 int err; 234 int err;
235 235
236 debugf1("%s()\n", __func__); 236 debugf1("%s()\n", __func__);
237 237
238 /* get the /sys/devices/system/edac reference */ 238 /* get the /sys/devices/system/edac reference */
239 edac_class = edac_get_sysfs_class(); 239 edac_subsys = edac_get_sysfs_subsys();
240 if (edac_class == NULL) { 240 if (edac_subsys == NULL) {
241 debugf1("%s() no edac_class error\n", __func__); 241 debugf1("%s() no edac_subsys error\n", __func__);
242 err = -ENODEV; 242 err = -ENODEV;
243 goto err_out; 243 goto err_out;
244 } 244 }
245 245
246 /* Point to the 'edac_class' this instance 'reports' to */ 246 /* Point to the 'edac_subsys' this instance 'reports' to */
247 edac_dev->edac_class = edac_class; 247 edac_dev->edac_subsys = edac_subsys;
248 248
249 /* Init the devices's kobject */ 249 /* Init the devices's kobject */
250 memset(&edac_dev->kobj, 0, sizeof(struct kobject)); 250 memset(&edac_dev->kobj, 0, sizeof(struct kobject));
@@ -261,7 +261,7 @@ int edac_device_register_sysfs_main_kobj(struct edac_device_ctl_info *edac_dev)
261 261
262 /* register */ 262 /* register */
263 err = kobject_init_and_add(&edac_dev->kobj, &ktype_device_ctrl, 263 err = kobject_init_and_add(&edac_dev->kobj, &ktype_device_ctrl,
264 &edac_class->kset.kobj, 264 &edac_subsys->dev_root->kobj,
265 "%s", edac_dev->name); 265 "%s", edac_dev->name);
266 if (err) { 266 if (err) {
267 debugf1("%s()Failed to register '.../edac/%s'\n", 267 debugf1("%s()Failed to register '.../edac/%s'\n",
@@ -284,7 +284,7 @@ err_kobj_reg:
284 module_put(edac_dev->owner); 284 module_put(edac_dev->owner);
285 285
286err_mod_get: 286err_mod_get:
287 edac_put_sysfs_class(); 287 edac_put_sysfs_subsys();
288 288
289err_out: 289err_out:
290 return err; 290 return err;
@@ -308,7 +308,7 @@ void edac_device_unregister_sysfs_main_kobj(struct edac_device_ctl_info *dev)
308 * b) 'kfree' the memory 308 * b) 'kfree' the memory
309 */ 309 */
310 kobject_put(&dev->kobj); 310 kobject_put(&dev->kobj);
311 edac_put_sysfs_class(); 311 edac_put_sysfs_subsys();
312} 312}
313 313
314/* edac_dev -> instance information */ 314/* edac_dev -> instance information */