opnsense-src/sys/dev/pci
Andriy Gapon d7d4592ada PCI hot-plug: use dedicated taskqueue for device attach / detach
Attaching and detaching devices can be heavy-weight and detaching can
sleep waiting for events.  For that reason using the system-wide
single-threaded taskqueue_thread is not really appropriate.
There is even a possibility for a deadlock if taskqueue_thread is used
for detaching.

In fact, there is an easy to reproduce deadlock involving nvme, pass
and a sudden removal of an NVMe device.
A pass peripheral would not release a reference on an nvme sim until
pass_shutdown_kqueue() is executed via taskqueue_thread.  But the
taskqueue's thread is blocked in nvme_detach() -> ... -> cam_sim_free()
because of the outstanding reference.

Sponsored by:	CyberSecure
Reviewed by:	mav, imp

(cherry picked from commit 12588ce02d)
2021-05-21 13:28:06 +03:00
..
controller Add PCI Express driver for the ARM Neoverse N1 System Development 2020-02-11 15:12:09 +00:00
fixup_pci.c
hostb_pci.c pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
ignore_pci.c
isa_pci.c pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
pci.c Set PCIe device's Max_Payload_Size to match PCIe root's. 2021-05-04 20:53:55 -04:00
pci_dw.c DesignWare PCIe driver: Don't call bus_generic_attach() twice. 2020-12-05 10:55:09 +00:00
pci_dw.h pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
pci_dw_if.m Add driver for DesignWare PCIE core, and its Armada 8K specific attachement. 2019-10-20 11:11:32 +00:00
pci_dw_mv.c pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
pci_host_generic.c pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
pci_host_generic.h Clean up the pci host generic driver 2020-06-17 19:56:17 +00:00
pci_host_generic_acpi.c Only set the PCI bus end when we are reducing it 2020-11-29 16:22:33 +00:00
pci_host_generic_acpi.h Add PCI Express driver for the ARM Neoverse N1 System Development 2020-02-11 15:12:09 +00:00
pci_host_generic_fdt.c pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
pci_host_generic_fdt.h Add a driver for bcm2838 PCI express controller 2020-07-06 08:51:55 +00:00
pci_if.m
pci_iov.c pci_iov: When pci_iov_detach(9) is called, destroy VF children 2020-12-18 03:46:50 +00:00
pci_iov.h
pci_iov_if.m
pci_iov_private.h pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
pci_iov_schema.c
pci_pci.c PCI hot-plug: use dedicated taskqueue for device attach / detach 2021-05-21 13:28:06 +03:00
pci_private.h Export pci_attach() and pci_detach(). 2019-10-15 18:58:01 +00:00
pci_subr.c
pci_user.c pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
pcib_if.m
pcib_private.h Abstract the locking for PCIe hotplug. It still uses Giant so there's 2019-12-26 21:00:06 +00:00
pcib_support.c pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00
pcireg.h Add more values for PCI capabilities, PCIe extended capabilities, and subclasses. 2020-02-20 17:08:52 +00:00
pcivar.h MFC 1acf24a044: 2021-03-24 08:54:52 +01:00
schema_private.h
vga_pci.c pci: clean up empty lines in .c and .h files 2020-09-01 22:00:07 +00:00