.store = queue_attr_store,
};
+static const struct attribute_group *blk_queue_attr_groups[] = {
+ &queue_attr_group,
+ NULL
+};
+
struct kobj_type blk_queue_ktype = {
+ .default_groups = blk_queue_attr_groups,
.sysfs_ops = &queue_sysfs_ops,
.release = blk_release_queue,
};
if (ret < 0)
goto unlock;
- ret = sysfs_create_group(&q->kobj, &queue_attr_group);
- if (ret) {
- kobject_del(&q->kobj);
- goto unlock;
- }
-
if (queue_is_mq(q))
__blk_mq_register_dev(dev, q);
mutex_lock(&q->sysfs_lock);