opnsense-src/sys/dev/virtio
Jessica Clarke be79a2c60f virtio_mmio: Fix V1 device probing spec conformance (section 4.2.3.1.1)
We must check MagicValue not just Version before anything else, and then
we must check DeviceID and immediately abort if zero (and this must not
be an error).

Do all this when probing rather than at the start of attaching as that's
where this belongs, and provides a clear boundary between the device
detection and device initialisation parts of the specified driver
initialisation process. This also means we don't create empty device
instances for placeholder devices, reducing clutter on systems that
pre-allocate a large number, such as QEMU's AArch64 virt machine (which
provides 32).

Reviewed by:	bryanv
Differential Revision:	https://reviews.freebsd.org/D28070
2021-01-21 01:05:21 +00:00
..
balloon virtio: Handle possible failure of virtio_finalize_features() 2021-01-19 04:55:26 +00:00
block virtio: Handle possible failure of virtio_finalize_features() 2021-01-19 04:55:26 +00:00
console virtio: Handle possible failure of virtio_finalize_features() 2021-01-19 04:55:26 +00:00
mmio virtio_mmio: Fix V1 device probing spec conformance (section 4.2.3.1.1) 2021-01-21 01:05:21 +00:00
network virtio: Handle possible failure of virtio_finalize_features() 2021-01-19 04:55:26 +00:00
pci virtio: Handle possible failure of virtio_finalize_features() 2021-01-19 04:55:26 +00:00
random virtio: Handle possible failure of virtio_finalize_features() 2021-01-19 04:55:26 +00:00
scsi virtio: Handle possible failure of virtio_finalize_features() 2021-01-19 04:55:26 +00:00
virtio.c virtio_pci: Add sysctl to show current features 2021-01-19 04:55:23 +00:00
virtio.h virtio_pci: Add sysctl to show current features 2021-01-19 04:55:23 +00:00
virtio_bus_if.m virtio: Add VirtIO PCI modern (V1) support 2021-01-19 04:55:23 +00:00
virtio_config.h Update VirtIO definitions from Linux virtio_config.h and virtio_ring.h headers 2018-06-17 20:45:48 +00:00
virtio_endian.h virtio: Add VirtIO PCI modern (V1) support 2021-01-19 04:55:23 +00:00
virtio_ids.h Sync VirtIO IDs with Linux 2018-01-14 06:03:40 +00:00
virtio_if.m Add optional VirtIO device method for post-attach notifications 2013-09-01 04:20:23 +00:00
virtio_ring.h Update VirtIO definitions from Linux virtio_config.h and virtio_ring.h headers 2018-06-17 20:45:48 +00:00
virtqueue.c virtio: Add modern (v1) virtqueue support 2021-01-19 04:55:23 +00:00
virtqueue.h virtio: Add modern (v1) virtqueue support 2021-01-19 04:55:23 +00:00