diff --git a/drivers/block/loop.c b/drivers/block/loop.c index 3f40e673a101..e90f7d349816 100644 --- a/drivers/block/loop.c +++ b/drivers/block/loop.c @@ -2183,8 +2183,8 @@ out: static void loop_remove(struct loop_device *lo) { del_gendisk(lo->lo_disk); - blk_mq_free_tag_set(&lo->tag_set); blk_cleanup_disk(lo->lo_disk); + blk_mq_free_tag_set(&lo->tag_set); mutex_destroy(&lo->lo_mutex); kfree(lo); }