Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP1:GA
xen.10697
xen_pvonhvm.unplug_at_resume.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File xen_pvonhvm.unplug_at_resume.patch of Package xen.10697
From: Olaf Hering <olaf@aepfle.de> Date: Mon, 11 Jun 2018 14:17:37 +0200 Subject: unmodified_drivers: unplug the emulated devices at resume time Since qemu-2.10 it is required to unplug emulated devices again after a live migration. If this is not done, qemu's block-backend driver will be unable to open the backing disk image because it is still busy by qemu's IDE driver. As a result the domUs block-frontend driver will be unable to access the disks, and the domU has to be destroyed. libxl is unable to detect the situation. Apply the same workaround for this qemu bug that was done already years ago in linux.git with commit 512b109ec962 ("xen: unplug the emulated devices at resume time") to make sure xenlinux based domUs can be migrated to unfixed hosts. Signed-off-by: Olaf Hering <olaf@aepfle.de> --- .../linux-2.6/platform-pci/platform-pci.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) Index: xen-4.4.4-testing/unmodified_drivers/linux-2.6/platform-pci/platform-pci.c =================================================================== --- xen-4.4.4-testing.orig/unmodified_drivers/linux-2.6/platform-pci/platform-pci.c +++ xen-4.4.4-testing/unmodified_drivers/linux-2.6/platform-pci/platform-pci.c @@ -289,6 +289,12 @@ int gnttab_init(void); #define UNPLUG_AUX_IDE_DISKS 4 #define UNPLUG_ALL 7 +static short unplug_value; +static void unplug_devices(void) +{ + outw(unplug_value, XEN_IOPORT_UNPLUG); +} + static int check_platform_magic(struct device *dev, long ioaddr, long iolen) { short magic, unplug = 0; @@ -328,6 +334,7 @@ static int check_platform_magic(struct d dev_warn(dev, "unrecognised option '%s' " "in module parameter 'dev_unplug'\n", p); } + unplug_value = unplug; if (iolen < 0x16) { err = "backend too old"; @@ -355,7 +362,7 @@ static int check_platform_magic(struct d } /* Fall through */ case 0: - outw(unplug, XEN_IOPORT_UNPLUG); + unplug_devices(); break; default: err = "unknown I/O protocol version"; @@ -514,6 +521,8 @@ void platform_pci_resume(void) if (set_callback_via(callback_via)) printk("platform_pci_resume failure!\n"); + + unplug_devices(); } static int __init platform_pci_module_init(void)
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor