[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]
Subject: Re: [virtio-dev] Backend libraries for VirtIO device emulation
Hello Alex, On Fri, Mar 06, 2020 at 06:33:57PM +0000, Alex Bennée wrote: > Hi, > > So the context of my question is what sort of common software layer is > required to implement a virtio backend entirely in userspace? > > Currently most virtio backends are embedded directly in various VMMs > which emulate a number of devices as well as deal with handling devices > that are vhost aware and link with the host kernel. However there seems > to be a growing interest in having backends implemented in separate > processes, potentially even hosted in other guest VMs. > > As far as I can tell there is a lot of duplicated effort in handling the > low level navigation of virt queues and buffers. QEMU has code in > hw/virtio as well as contrib/libvhost-user which is used by the recent > virtiofsd daemon. kvm-tool has a virtio subdirectory that implements a > similar set of functionality for it's emulation. The Rust-vmm project > has libraries for implementing the device traits. > > Another aspect to this is the growing interest in carrying virtio over > other hypervisors. I'm wondering if there is enough abstraction possible > to have a common library that is hypervisor agnostic? Can a device > backend be emulated purely with some shared memory and some sockets for > passing messages/kicks from/to the VMM which then deals with the hypervisor > specifics of the virtio-transport? > > Thoughts? I am currently investigating the use of metamodeling to capture virtio concepts. The work is still a draft but you can give a look at https://github.com/MatiasVara/virtioml. One of the ideas is to base on a metamodel to generate the code for different targets, e.g., rust, c, etc. For the moment, I just played by generating the c header. This could be extended to other languages. Regards, Matias. > > -- > Alex Bennée > > --------------------------------------------------------------------- > To unsubscribe, e-mail: virtio-dev-unsubscribe@lists.oasis-open.org > For additional commands, e-mail: virtio-dev-help@lists.oasis-open.org >
[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]