this post was submitted on 06 Feb 2025
88 points (97.8% liked)

Linux

6118 readers
283 users here now

A community for everything relating to the GNU/Linux operating system

Also check out:

Original icon base courtesy of [email protected] and The GIMP

founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] -3 points 2 weeks ago (1 children)

Hellwig has some excellent points and people are up in arms solely because he’s not giving the green light for the shiny new toy.

Keep the wrappers in your code instead of making life painful for others

This is a perfectly valid approach, anyone claiming he’s resistant for no reason has never tried maintaining a multi language code base.

If you want to use something that's not C, be that assembly or Rust, you write to C interfaces and deal with the impedance mismatch yourself as far as I'm concerned.

Again an entirely reasonable approach. There is precedence for this approach in the kernel/dma and I see no reason to change this now, unless a full kernel/dma rewrite to Rust were to occur.

[–] [email protected] 21 points 2 weeks ago* (last edited 2 weeks ago) (1 children)

What they are asking is not to change the c code to suit rust, but to leave the C code as is, and have a single Rust-written wrapper that links into the C DMA code so that other Rust drivers can link into the wrapper. Additionally, said wrapper is not to be maintained by Hellwig, but by the maintainers of the drivers that will use the wrapper, so without overhead for Hellwig.

He is not asking to not make his work harder, he's explicitly asking to make it harder to write rust drivers that use DMA.