RinHizakura / vusb-land

A virtual USB environment
0 stars 0 forks source link

Aggregated to LKMPG? #1

Open jserv opened 4 months ago

jserv commented 4 months ago

I find this project interesting. Do you think it is feasible to adapt this virtual USB driver as an example, as illustrated in the Linux Kernel Module Programming Guide (LKMPG)?

RinHizakura commented 4 months ago

This project is not going to implement a driver for the virtual USB device. Instead, it implements a virtual USB host controller device(HCD) driver. The virtual USB device controller(UCD) driver should also be implemented in the future. With sufficient features in these drivers, the target of the project is going to provide a minimalist virtual environment to test USB gadgets like g_zero on every platform. I feel these are too advanced for LKMPG, because the kind of drivers are mostly provided by platform manufacturers, not USB device vendors. An example like USB Drivers in Linux could be closer to what you are looking for.

Even if this is fine for LKMPG, this project still has so many things to do to make the mentioned goal complete. I couldn't find time to do this now, but if anyone is interested in more about this, I am fine to give more explanation and lead the way to done.

By the way, if you are looking for any implementation of the virtual device driver. Maybe the vi2c-diva which demonstrates how to implement an I2C device driver is a suitable one for you.