[PATCH/RFC] virtio_test: A module for testing virtio via userspace

Dmitry Vyukov
Sat, 12 Nov 2022 16:19:42 -0000

Hi,

The original email is from 2009, so I assume you don't have it in
your inboxes already. Here is the original email:

https://lore.kernel.org/all/200906190927.34831.borntraeger at de.ibm.com/

> This patch introduces a prototype for a virtio_test module. This module can
> be bound to any virtio device via sysfs bind/unbind feature, e.g:
> $ echo virtio1 > /sys/bus/virtio/drivers/virtio_rng/unbind
> $ modprobe virtio_test
>
> On probe this module registers to all virtqueues and creates a character
> device for every virtio device. (/dev/viotest<number>).
> The character device offers ioctls to allow a userspace application to
submit
> virtio operations like addbuf, kick and getbuf. It also offers ioctls to
get
> information about the device and to query the amount of occurred callbacks
(or
> wait synchronously on callbacks).

As far as I understand the test driver was never merged and I can't find
any similar testing drivers. I am looking for a test module that allows
to create a transient virtio device that can be used to activate a virtio
driver are communicate with it as if from the host.

Does such thing exist already?
Or how are virtio transports/drivers tested/fuzzed nowadays?

Thanks