Linux 6.12 Brings 9p Network USB Gadget Driver To Ease Embedded Device Development

Written by Michael Larabel in Hardware on 26 September 2024 at 09:00 AM EDT. 1 Comment
HARDWARE
The USB/Thunderbolt subsystem updates were submitted today for the Linux 6.12 kernel merge window along with the other areas of the kernel overseen by Greg Kroah-Hartman. A new USB driver is the 9p network gadget driver that has been in development for quite a while and aims to help ease embedded Linux device development.

The 9pfs transport USB gadget driver allows for mounting USB host side exported to 9pfs file-systems via the USB gadget interface. The USB host exports a file-system while the gadget on the USB device-side makes it mountable.

Michael Grzeschik with Pengutronix explained in the 9pfs transport USB gadget driver patch series:
"The USB host exports a filesystem, while the gadget on the USB device side makes it mountable.

Diod (9pfs server) and the forwarder are on the development host, where the root filesystem is actually stored. The gadget is initialized during boot (or later) on the embedded board. Then the forwarder will find it on the USB bus and start forwarding requests.

In this case the 9p requests come from the device and are handled by the host. The reason is that USB device ports are normally not available on PCs, so a connection in the other direction would not work."

One of the intended use-cases for this is to serve as an alternative to a Network File-System (NFS) root booting during the development of embedded Linux devices.

9pfs USB transport diagram


This addition is arguably the most interesting of the USB changes for the Linux 6.12 kernel.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week