2c16e13ff3
Softint-based interrupt handling is considered as a future direction of the (network) device driver architecture in NetBSD. pq3etsec of ppc is already implemented based on the architecture (unlike pq3etsec, this change doesn't include softint-based if_start). In this architecture, a hardware interrupt handler just schedules a softint and the softint performs actual interrupt processing. It reduces processing in hardware interrupt context and allows Layer 2 network stack (e.g., bridge, vlan and even bpf) run in softint context, which makes it easy to implement fine-grain locking in the layer. This is an experimental implementation of the architecture in if_viof. virtio introduces a new flag VIRTIO_F_PCI_INTR_SOFTINT. If a driver of virtio sets it to sc_flags of virtio_softc, virtio calls softint_schedule in virtio_intr instead of directly calling the interrupt handler of the driver. When VIOIF_SOFTINT_INTR is on, vioif doesn't use the existing softint (vioif_rx_softint) that is called from vioif_rx_vq_done. Because vioif_rx_softint already runs in softint context and another softint isn't needed. This change actually improves performance in some cases. The feature is disabled by default and enabled when SOFTINT_INTR is set somewhere (normally in a kernel configuration). |
||
---|---|---|
bin | ||
common | ||
compat | ||
crypto | ||
dist/pf | ||
distrib | ||
doc | ||
etc | ||
external | ||
extsrc | ||
games | ||
gnu | ||
include | ||
lib | ||
libexec | ||
regress | ||
rescue | ||
sbin | ||
share | ||
sys | ||
tests | ||
tools | ||
usr.bin | ||
usr.sbin | ||
x11 | ||
build.sh | ||
BUILDING | ||
Makefile | ||
Makefile.inc | ||
UPDATING |