freebsd-dev/sys/x86
John Baldwin 254e4e5b77 Simplify swi for bus_dma.
When a DMA request using bounce pages completes, a swi is triggered to
schedule pending DMA requests using the just-freed bounce pages.  For
a long time this bus_dma swi has been tied to a "virtual memory" swi
(swi_vm).  However, all of the swi_vm implementations are the same and
consist of checking a flag (busdma_swi_pending) which is always true
and if set calling busdma_swi.  I suspect this dates back to the
pre-SMPng days and that the intention was for swi_vm to serve as a
mux.  However, in the current scheme there's no need for the mux.

Instead, remove swi_vm and vm_ih.  Each bus_dma implementation that
uses bounce pages is responsible for creating its own swi (busdma_ih)
which it now schedules directly.  This swi invokes busdma_swi directly
removing the need for busdma_swi_pending.

One consequence is that the swi now works on RISC-V which had previously
failed to invoke busdma_swi from swi_vm.

Reviewed by:	imp, kib
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D33447
2021-12-28 13:51:25 -08:00
..
acpica x86: duplicate acpi_wakeup.c per i386 and amd64 2021-09-14 00:23:14 +03:00
bios smbios: Move smbios driver out from x86 machdep code 2021-02-23 21:17:09 +00:00
conf Retire synchronous PPP kernel driver sppp(4). 2021-10-22 11:41:36 -07:00
cpufreq x86: Remove CTLFLAG_NEEDGIANT from sysctls. 2021-12-25 22:24:20 -05:00
include Simplify swi for bus_dma. 2021-12-28 13:51:25 -08:00
iommu dmar: Disable protected memory regions after initialization 2021-10-29 10:08:25 +02:00
isa x86: Remove CTLFLAG_NEEDGIANT from sysctls. 2021-12-25 22:24:20 -05:00
linux Drop "All rights reserved" from my copyright statements. 2021-07-20 10:05:50 +03:00
pci pci: add missing PCI id of Coffee Lake GPU 2021-12-17 23:18:31 +02:00
x86 Simplify swi for bus_dma. 2021-12-28 13:51:25 -08:00
xen xen: plug some of set-but-not-used vars 2021-12-15 13:46:17 +00:00