Merge remote-tracking branch 'sstabellini/xen-fixes' into staging
* sstabellini/xen-fixes: xen_disk: detach the blkdev before bdrv_delete xen_console: ignore console disconnect events from console/0
This commit is contained in:
commit
49e00ba969
@ -248,6 +248,9 @@ static void con_disconnect(struct XenDevice *xendev)
|
||||
{
|
||||
struct XenConsole *con = container_of(xendev, struct XenConsole, xendev);
|
||||
|
||||
if (!xendev->dev) {
|
||||
return;
|
||||
}
|
||||
if (con->chr)
|
||||
qemu_chr_add_handlers(con->chr, NULL, NULL, NULL, NULL);
|
||||
xen_be_unbind_evtchn(&con->xendev);
|
||||
|
@ -726,6 +726,7 @@ static void blk_disconnect(struct XenDevice *xendev)
|
||||
if (!blkdev->dinfo) {
|
||||
/* close/delete only if we created it ourself */
|
||||
bdrv_close(blkdev->bs);
|
||||
bdrv_detach_dev(blkdev->bs, blkdev);
|
||||
bdrv_delete(blkdev->bs);
|
||||
}
|
||||
blkdev->bs = NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user