9 releases
Uses new Rust 2024
| new 0.0.2-rc.1 | Apr 18, 2026 |
|---|---|
| 0.0.1 | Mar 28, 2026 |
| 0.0.1-rc.2 | Feb 26, 2026 |
#8 in #gadget
140 downloads per month
Used in 2 crates
(via smoo-gadget-app)
165KB
4.5K
SLoC
smoo-gadget-core
Much of the "guts" of smoo's gadget daemon live here:
IoPumpowns and drives the protocol interactions on the (USB) wire.ExportControllerruns a reconciler that drives configured exports (from the host) into corresponding online ublk targets.LinkControlleris also a kinda-reconciler that handles the USB link (or the host side driving it) going away and/or coming online, and ensures in-flight I/O is parked and replayed (no timeouts).StateStorehandles (un)marshaling the runtime state we need to survive across daemon restarts/crashes.
Currently, we assume that we're dispatching i/o requests from ublk to USB via FunctionFS. In the future, if we were to support other platforms/targets, we'd try to tease the ublk / FFS parts into separate crates. That's very much out of scope for now, though.
The bits that drive the actual ublk (ctrl + i/o queues) rings live in smoo-gadget-ublk.
Dependencies
~16–27MB
~454K SLoC