Re: [libvirt] [PATCH RESEND] qemu: Do not free the device from activePciHostdevs if it's in use

2011-12-14 Thread Osier Yang
On 2011年12月15日 06:57, Eric Blake wrote: On 11/29/2011 03:23 AM, Osier Yang wrote: * src/qemu/qemu_hostdev.c (qemuDomainReAttachHostdevDevices): pciDeviceListFree(pcidevs) in the end free()s the device even if it's in use by other domain, which can cause rase. s/rase/a race/ ... The patch al

Re: [libvirt] [PATCH RESEND] qemu: Do not free the device from activePciHostdevs if it's in use

2011-12-14 Thread Eric Blake
On 11/29/2011 03:23 AM, Osier Yang wrote: > * src/qemu/qemu_hostdev.c (qemuDomainReAttachHostdevDevices): > pciDeviceListFree(pcidevs) in the end free()s the device even if > it's in use by other domain, which can cause rase. s/rase/a race/ ... > > The patch also fixes another problem, there won

[libvirt] [PATCH RESEND] qemu: Do not free the device from activePciHostdevs if it's in use

2011-11-29 Thread Osier Yang
* src/qemu/qemu_hostdev.c (qemuDomainReAttachHostdevDevices): pciDeviceListFree(pcidevs) in the end free()s the device even if it's in use by other domain, which can cause rase. How to reproduce: virsh nodedev-dettach pci__00_19_0 virsh start test virsh attach-device test hostdev.xml virsh