Thanks a lot for looking into this! I'll review early next week. On Wed, Mar 09, 2016 at 07:19:59PM +0100, Ladi Prosek wrote: > The goal here is to support booting from modern only (non-transitional) > virtio-net devices.
Side-note: it is preferable to use transitional devices through the modern interface, as well. Some advantages include: - ability to work without enabling IO space (or even memory space) - ability to reduce ring size, and generally lower memory consumption > The code strives to comply with the virtio 1.0 spec > and is heavily inspired by the Linux kernel implementation. > > One notable divergence from Linux is the explicit differentiation > between port I/O and memory I/O due to the lack of __iomem in iPXE. See > struct virtio_pci_region for details. > > src/drivers/bus/pciextra.c | 54 ++++++--- > src/drivers/bus/virtio-pci.c | 213 ++++++++++++++++++++++++++++++++- > src/drivers/bus/virtio-ring.c | 12 +- > src/drivers/net/virtio-net.c | 259 > +++++++++++++++++++++++++++++++++++++++-- > src/drivers/net/virtio-net.h | 18 +++ > src/include/ipxe/errfile.h | 1 + > src/include/ipxe/pci.h | 2 + > src/include/ipxe/virtio-pci.h | 231 ++++++++++++++++++++++++++++++++++++ > src/include/ipxe/virtio-ring.h | 9 ++ > 9 files changed, 769 insertions(+), 30 deletions(-) > > [PATCH 1/4] [pci] Add pci_find_next_capability > [PATCH 2/4] [virtio] Add virtio 1.0 constants and data structures > [PATCH 3/4] [virtio] Add virtio 1.0 PCI support > [PATCH 4/4] [virtio] Add virtio-net 1.0 support _______________________________________________ ipxe-devel mailing list ipxe-devel@lists.ipxe.org https://lists.ipxe.org/mailman/listinfo.cgi/ipxe-devel