Merge tag 'v3.8-rc7' into next
[~shefty/rdma-dev.git] / drivers / edac / edac_pci_sysfs.c
index 0056c4d..e8658e4 100644 (file)
@@ -429,8 +429,8 @@ static void edac_pci_main_kobj_teardown(void)
        if (atomic_dec_return(&edac_pci_sysfs_refcount) == 0) {
                edac_dbg(0, "called kobject_put on main kobj\n");
                kobject_put(edac_pci_top_main_kobj);
+               edac_put_sysfs_subsys();
        }
-       edac_put_sysfs_subsys();
 }
 
 /*