Skip to content

Commit

Permalink
block: remove blk_free_devt in add_partition
Browse files Browse the repository at this point in the history
put_device(pdev) will call pdev->type->release finally, and blk_free_devt
has been called in part_release(), so remove it.

Signed-off-by: weiping zhang <zhangweiping@didichuxing.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
  • Loading branch information
weiping zhang authored and axboe committed Aug 24, 2017
1 parent 97e0546 commit 4757084
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion block/partition-generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,6 @@ struct hd_struct *add_partition(struct gendisk *disk, int partno,
device_del(pdev);
out_put:
put_device(pdev);
blk_free_devt(devt);
return ERR_PTR(err);
}

Expand Down

0 comments on commit 4757084

Please sign in to comment.