Rust Code Updated For The Linux Kernel - Networking & Async Support Started
Making for an exciting Saturday morning, Miguel Ojeda has posted the latest patch series plumbing Rust language support into the Linux kernel. The "Rust for the Linux kernel" patches are now up to their sixth version for adding the necessary infrastructure for this second, optional language to the kernel plus continuing to add more sample code / basic functionality for showing off use of this memory-safety-focused language for kernel purposes.
The Rust for Linux effort continues running strong with many developers and organizations interested in seeing the ability to begin making use of Rust code in the kernel especially for areas prone to memory safety issues. With the v6 patches out today, the toolchain support has been updated against Rust 1.60, support for running documentation tests in-kernel, and other Rust infrastructure improvements.
When it comes to Rust code usage within the kernel, the start of networking support is found with this patch series. The "net" module has support for types like Namespace, SkBuff, Ipv4Addr, SocketAddrV4, TcpListener, and more. There is also the start of "async" support for asynchronous kernel programming. The current state already is working for allowing asynchronous TCP socket code. The new Rust code also adds support for network packet filters and other new features.
As of this Rust for Linux v6 series, the Rust support is still considered "experimental" but good enough that kernel developers can begin working on Rust abstractions for other kernel subsystems and porting more drivers over to Rust, if desired.
More details on the updated Rust code for the Linux kernel via this patch series. The Rust kernel effort currently amounts to 37.9k lines of code including the infrastructure, subsystem abstractions started so far, sample code, and converting some Android and GPIO driver code to Rust as additional examples.
The Rust for Linux effort continues running strong with many developers and organizations interested in seeing the ability to begin making use of Rust code in the kernel especially for areas prone to memory safety issues. With the v6 patches out today, the toolchain support has been updated against Rust 1.60, support for running documentation tests in-kernel, and other Rust infrastructure improvements.
When it comes to Rust code usage within the kernel, the start of networking support is found with this patch series. The "net" module has support for types like Namespace, SkBuff, Ipv4Addr, SocketAddrV4, TcpListener, and more. There is also the start of "async" support for asynchronous kernel programming. The current state already is working for allowing asynchronous TCP socket code. The new Rust code also adds support for network packet filters and other new features.
As of this Rust for Linux v6 series, the Rust support is still considered "experimental" but good enough that kernel developers can begin working on Rust abstractions for other kernel subsystems and porting more drivers over to Rust, if desired.
More details on the updated Rust code for the Linux kernel via this patch series. The Rust kernel effort currently amounts to 37.9k lines of code including the infrastructure, subsystem abstractions started so far, sample code, and converting some Android and GPIO driver code to Rust as additional examples.
26 Comments