Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
bonzini
· 11mo ago · 0 comments
You can absolutely write
drivers
with zero unsafe Rust. The bridge from Rust to C is where unsafe code lies.
Comments
[–]
weebull
11mo ago
And hardware access. You absolutely can't write a hardware driver without unsafe.
[–]
bonzini
OP
11mo ago
There are devices that do not have access to memory, and you can write a safe description of such a device's registers. The only thing that is inherently unsafe is building DMA descriptors.