Commit bee69f9f authored by David Vrabel's avatar David Vrabel Committed by Willy Tarreau

blkfront: Fix backtrace in del_gendisk

Commit 89de1669 upstream.

The call to del_gendisk follows an non-refcounted gd->queue
pointer. We release the last ref in blk_cleanup_queue. Fixed by
reordering releases accordingly.
Signed-off-by: default avatarDaniel Stodden <daniel.stodden@citrix.com>
Signed-off-by: default avatarJeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: default avatarDavid Vrabel <david.vrabel@citrix.com>
Signed-off-by: default avatarWilly Tarreau <w@1wt.eu>
parent 53148aeb
......@@ -942,11 +942,11 @@ static void blkfront_closing(struct xenbus_device *dev)
/* Flush gnttab callback work. Must be done with no locks held. */
flush_scheduled_work();
del_gendisk(info->gd);
blk_cleanup_queue(info->rq);
info->rq = NULL;
del_gendisk(info->gd);
out:
xenbus_frontend_closed(dev);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment