diff options
Diffstat (limited to 'drivers/edac/edac_pci_sysfs.c')
-rw-r--r-- | drivers/edac/edac_pci_sysfs.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/edac/edac_pci_sysfs.c b/drivers/edac/edac_pci_sysfs.c index 495198ad059..97f5064e399 100644 --- a/drivers/edac/edac_pci_sysfs.c +++ b/drivers/edac/edac_pci_sysfs.c | |||
@@ -338,12 +338,12 @@ static struct kobj_type ktype_edac_pci_main_kobj = { | |||
338 | * edac_pci_main_kobj_setup() | 338 | * edac_pci_main_kobj_setup() |
339 | * | 339 | * |
340 | * setup the sysfs for EDAC PCI attributes | 340 | * setup the sysfs for EDAC PCI attributes |
341 | * assumes edac_class has already been initialized | 341 | * assumes edac_subsys has already been initialized |
342 | */ | 342 | */ |
343 | static int edac_pci_main_kobj_setup(void) | 343 | static int edac_pci_main_kobj_setup(void) |
344 | { | 344 | { |
345 | int err; | 345 | int err; |
346 | struct sysdev_class *edac_class; | 346 | struct bus_type *edac_subsys; |
347 | 347 | ||
348 | debugf0("%s()\n", __func__); | 348 | debugf0("%s()\n", __func__); |
349 | 349 | ||
@@ -354,9 +354,9 @@ static int edac_pci_main_kobj_setup(void) | |||
354 | /* First time, so create the main kobject and its | 354 | /* First time, so create the main kobject and its |
355 | * controls and attributes | 355 | * controls and attributes |
356 | */ | 356 | */ |
357 | edac_class = edac_get_sysfs_class(); | 357 | edac_subsys = edac_get_sysfs_subsys(); |
358 | if (edac_class == NULL) { | 358 | if (edac_subsys == NULL) { |
359 | debugf1("%s() no edac_class\n", __func__); | 359 | debugf1("%s() no edac_subsys\n", __func__); |
360 | err = -ENODEV; | 360 | err = -ENODEV; |
361 | goto decrement_count_fail; | 361 | goto decrement_count_fail; |
362 | } | 362 | } |
@@ -381,7 +381,7 @@ static int edac_pci_main_kobj_setup(void) | |||
381 | /* Instanstiate the pci object */ | 381 | /* Instanstiate the pci object */ |
382 | err = kobject_init_and_add(edac_pci_top_main_kobj, | 382 | err = kobject_init_and_add(edac_pci_top_main_kobj, |
383 | &ktype_edac_pci_main_kobj, | 383 | &ktype_edac_pci_main_kobj, |
384 | &edac_class->kset.kobj, "pci"); | 384 | &edac_subsys->dev_root->kobj, "pci"); |
385 | if (err) { | 385 | if (err) { |
386 | debugf1("Failed to register '.../edac/pci'\n"); | 386 | debugf1("Failed to register '.../edac/pci'\n"); |
387 | goto kobject_init_and_add_fail; | 387 | goto kobject_init_and_add_fail; |
@@ -404,7 +404,7 @@ kzalloc_fail: | |||
404 | module_put(THIS_MODULE); | 404 | module_put(THIS_MODULE); |
405 | 405 | ||
406 | mod_get_fail: | 406 | mod_get_fail: |
407 | edac_put_sysfs_class(); | 407 | edac_put_sysfs_subsys(); |
408 | 408 | ||
409 | decrement_count_fail: | 409 | decrement_count_fail: |
410 | /* if are on this error exit, nothing to tear down */ | 410 | /* if are on this error exit, nothing to tear down */ |
@@ -432,7 +432,7 @@ static void edac_pci_main_kobj_teardown(void) | |||
432 | __func__); | 432 | __func__); |
433 | kobject_put(edac_pci_top_main_kobj); | 433 | kobject_put(edac_pci_top_main_kobj); |
434 | } | 434 | } |
435 | edac_put_sysfs_class(); | 435 | edac_put_sysfs_subsys(); |
436 | } | 436 | } |
437 | 437 | ||
438 | /* | 438 | /* |