Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP1:GA
xen.4507
qemu-xen-upstream-xen_platform-unplug-also-SCSI...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File qemu-xen-upstream-xen_platform-unplug-also-SCSI-disks.patch of Package xen.4507
From: Olaf Hering <olaf@aepfle.de> Subject: [PATCH] xen_platform: unplug also SCSI disks References: bnc#953518 - disks added via SCSI controller are visible twice on HVM XEN guest systems Using 'vdev=sd[a-o]' will create an emulated LSI controller, which can be used by the emulated BIOS to boot from disk. If the HVM domU has also PV driver the disk may appear twice in the guest. To avoid this an unplug of the emulated hardware is needed, similar to what is done for IDE and NIC drivers already. Since the SCSI controller provides only disks the entire controller can be unplugged at once. Impact of the change for classic and pvops based guest kernels: vdev=sda:disk0 before: pvops: disk0=pv xvda + emulated sda classic: disk0=pv sda + emulated sdq after: pvops: disk0=pv xvda classic: disk0=pv sda vdev=hda:disk0, vdev=sda:disk1 before: pvops: disk0=pv xvda disk1=emulated sda classic: disk0=pv hda disk1=pv sda + emulated sdq after: pvops: disk0=pv xvda disk1=not accessible by blkfront, index hda==index sda classic: disk0=pv hda disk1=pv sda vdev=hda:disk0, vdev=sda:disk1, vdev=sdb:disk2 before: pvops: disk0=pv xvda disk1=emulated sda disk2=pv xvdb + emulated sdb classic: disk0=pv hda disk1=pv sda + emulated sdq disk2=pv sdb + emulated sdr after: pvops: disk0=pv xvda disk1=not accessible by blkfront, index hda==index sda disk2=pv xvdb classic: disk0=pv hda disk1=pv sda disk2=pv sda Signed-off-by: Olaf Hering <olaf@aepfle.de> --- hw/xen/xen_platform.c | 5 +++++ 1 file changed, 5 insertions(+) --- xen-4.4.4-testing.orig/tools/qemu-xen-dir-remote/hw/xen/xen_platform.c +++ xen-4.4.4-testing/tools/qemu-xen-dir-remote/hw/xen/xen_platform.c @@ -112,6 +112,11 @@ static void unplug_disks(PCIBus *b, PCID && strcmp(d->name, "xen-pci-passthrough") != 0) { qdev_unplug(DEVICE(d), NULL); } + else if (pci_get_word(d->config + PCI_CLASS_DEVICE) == + PCI_CLASS_STORAGE_SCSI + && strcmp(d->name, "xen-pci-passthrough") != 0) { + object_unparent(OBJECT(d)); + } } static void pci_unplug_disks(PCIBus *bus)
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