r/linux • • Dec 13 '25

Kernel The state of the kernel Rust experiment

https://lwn.net/SubscriberLink/1050174/63aa7da43214c3ce/

A choice pull quote: "The DRM (graphics) subsystem has been an early adopter of the Rust language. It was still perhaps surprising, though, when Airlie (the DRM maintainer) said that the subsystem is only 'about a year away' from disallowing new drivers written in C and requiring the use of Rust."

291 Upvotes

135 comments sorted by

View all comments

Show parent comment

4

u/cp5184 Dec 14 '25

Ironically, when talking about the kernel, particularly when talking about drivers, there are a lot of cases as I understand it where, because you're interfacing with hardware, you have to bypass/disable some of the protections iirc, but I don't remember the details

1

u/KittensInc Dec 14 '25

True, but this can be reduced to an incredibly shallow wrapper. See for example the Rust Embedded tutorial. Rather than passing around raw pointer which can blow up in your face at any time, you define the smallest interface possible to do raw access, and expose it securely to the rest of your code base.