.uevent = block_uevent,
};
-decl_subsys(block, &ktype_block, &block_uevent_ops);
+decl_subsys(block, &block_uevent_ops);
/*
* aggregate disk stat collector. Uses the same stats that the sysfs
disk->part = kmalloc_node(size,
GFP_KERNEL | __GFP_ZERO, node_id);
if (!disk->part) {
+ free_disk_stats(disk);
kfree(disk);
return NULL;
}
}
disk->minors = minors;
- kobj_set_kset_s(disk,block_subsys);
+ disk->kobj.kset = &block_subsys;
+ disk->kobj.ktype = &ktype_block;
kobject_init(&disk->kobj);
rand_initialize_disk(disk);
INIT_WORK(&disk->async_notify,