tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: VirtIO MMIO for amd64




Update

My NetBSD/amd64 branch can now boot using PVH on qemu/x86_64,
qemu/microvm and Firecracker using MMIO backed block devices.
It also supports multiple VirtIO devices such as NICs.

The last blocking point was that Firecracker only supports one data
segment and as such needs DMA bouncing which was not enabled for that
case (thanks Jason for the hint!).

Now before opening a PR I'd like your advice on the "cmdline bus"
part. As I explained earlier in this thread, without PCI or ACPI, MMIO
devices are "detected" through a kernel parameter, for example:

root=ld0a console=com rw -v virtio_mmio.device=512@0xfeb00e00:12 virtio_mmio.device=512@0xfeb00c00:11

To support this, I've attached `virtio*` to a newly created bus,
`cmdlinebus?` which is attached to mainbus in amd64_mainbus.c
I am not entirely sure this is the cleanest way to proceed and
would like to have your feedback.

The working branch is here: https://github.com/NetBSDfr/NetBSD-src/tree/mmio_cmdline

Cheers,

--
------------------------------------------------------------------------
Emile `iMil' Heitor <imil@{home.imil.net,NetBSD.org}> | https://imil.net


Home | Main Index | Thread Index | Old Index