Re: [libvirt] [PATCH v2 4/5] qemu_hotplug: Fix a rare race condition when detaching a device twice

2019-03-14 Thread Peter Krempa
On Thu, Mar 14, 2019 at 15:31:48 +0100, Michal Privoznik wrote: > On 3/14/19 3:14 PM, Peter Krempa wrote: > > On Thu, Mar 14, 2019 at 14:56:48 +0100, Michal Privoznik wrote: > > > On 3/14/19 2:18 PM, Peter Krempa wrote: > > > > On Thu, Mar 14, 2019 at 13:22:38 +0100, Michal Privoznik wrote: > > >

Re: [libvirt] [PATCH v2 4/5] qemu_hotplug: Fix a rare race condition when detaching a device twice

2019-03-14 Thread Michal Privoznik
On 3/14/19 3:14 PM, Peter Krempa wrote: On Thu, Mar 14, 2019 at 14:56:48 +0100, Michal Privoznik wrote: On 3/14/19 2:18 PM, Peter Krempa wrote: On Thu, Mar 14, 2019 at 13:22:38 +0100, Michal Privoznik wrote: [...] How can this be considered success? Also this introduces a possible

Re: [libvirt] [PATCH v2 4/5] qemu_hotplug: Fix a rare race condition when detaching a device twice

2019-03-14 Thread Peter Krempa
On Thu, Mar 14, 2019 at 14:56:48 +0100, Michal Privoznik wrote: > On 3/14/19 2:18 PM, Peter Krempa wrote: > > On Thu, Mar 14, 2019 at 13:22:38 +0100, Michal Privoznik wrote: [...] > > > > How can this be considered success? Also this introduces a possible > > regression. The DEVICE_DELETED

Re: [libvirt] [PATCH v2 4/5] qemu_hotplug: Fix a rare race condition when detaching a device twice

2019-03-14 Thread Michal Privoznik
On 3/14/19 2:18 PM, Peter Krempa wrote: On Thu, Mar 14, 2019 at 13:22:38 +0100, Michal Privoznik wrote: https://bugzilla.redhat.com/show_bug.cgi?id=1623389 If a device is detached twice from the same domain the following race condition may happen: 1) The first DetachDevice() call will issue

Re: [libvirt] [PATCH v2 4/5] qemu_hotplug: Fix a rare race condition when detaching a device twice

2019-03-14 Thread Peter Krempa
On Thu, Mar 14, 2019 at 13:22:38 +0100, Michal Privoznik wrote: > https://bugzilla.redhat.com/show_bug.cgi?id=1623389 > > If a device is detached twice from the same domain the following > race condition may happen: > > 1) The first DetachDevice() call will issue "device_del" on qemu > monitor,

[libvirt] [PATCH v2 4/5] qemu_hotplug: Fix a rare race condition when detaching a device twice

2019-03-14 Thread Michal Privoznik
https://bugzilla.redhat.com/show_bug.cgi?id=1623389 If a device is detached twice from the same domain the following race condition may happen: 1) The first DetachDevice() call will issue "device_del" on qemu monitor, but since the DEVICE_DELETED event did not arrive in time, the API ends