diff options
| author | Long Li <[email protected]> | 2021-05-12 08:06:40 +0000 |
|---|---|---|
| committer | Lorenzo Pieralisi <[email protected]> | 2021-06-03 17:28:48 +0000 |
| commit | 94d22763207ac6633612b8d8e0ca4fba0f7aa139 (patch) | |
| tree | f93d65deb83f01b40dcc20f6b5e10ed43a2887cc /tools/perf/scripts/python/event_analyzing_sample.py | |
| parent | Linux 5.13-rc1 (diff) | |
| download | kernel-94d22763207ac6633612b8d8e0ca4fba0f7aa139.tar.gz kernel-94d22763207ac6633612b8d8e0ca4fba0f7aa139.zip | |
PCI: hv: Fix a race condition when removing the device
On removing the device, any work item (hv_pci_devices_present() or
hv_pci_eject_device()) scheduled on workqueue hbus->wq may still be running
and race with hv_pci_remove().
This can happen because the host may send PCI_EJECT or PCI_BUS_RELATIONS(2)
and decide to rescind the channel immediately after that.
Fix this by flushing/destroying the workqueue of hbus before doing hbus remove.
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Long Li <[email protected]>
Signed-off-by: Lorenzo Pieralisi <[email protected]>
Reviewed-by: Michael Kelley <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/event_analyzing_sample.py')
0 files changed, 0 insertions, 0 deletions
