mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
block: put dev->kobj in blk_register_queue fail path
kernel needs to kobject_put on dev->kobj if elv_register_queue fails. Signed-off-by: Xiaotian Feng <[email protected]> Cc: "Martin K. Petersen" <[email protected]> Cc: Stephen Hemminger <[email protected]> Cc: Nikanth Karthikesan <[email protected]> Cc: David Teigland <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
This commit is contained in:
parent
4ee69851cd
commit
c87ffbb812
1 changed files with 1 additions and 0 deletions
|
|
@ -511,6 +511,7 @@ int blk_register_queue(struct gendisk *disk)
|
|||
kobject_uevent(&q->kobj, KOBJ_REMOVE);
|
||||
kobject_del(&q->kobj);
|
||||
blk_trace_remove_sysfs(disk_to_dev(disk));
|
||||
kobject_put(&dev->kobj);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue