[PATCH v3 1/3] rust: clk: use the type-state pattern
Miguel Ojeda
miguel.ojeda.sandonis at gmail.com
Thu Feb 12 03:45:28 PST 2026
On Thu, Feb 12, 2026 at 8:59 AM Maxime Ripard <mripard at kernel.org> wrote:
>
> And the "oh but driver is using the API" is kind of ironic in the
> context of the Rust bindings which have globally been in that situation
> for years. You can't argue it both ways.
I don't think this is true, if I understand you correctly.
To give some context, when Rust was close to land in mainline, we were
explicitly asked to cut down what we had out-of-tree to a minimum of
APIs, which was fair. So I did exactly that, to a point where you
could essentially only declare a module for x86_64 and use `pr_info!`
in it (pretty much). I even considered dropping the `pr_info!` too...
:)
Then we started upstreaming bits piece by piece, getting agreement and
input from the relevant maintainers for each bit, and so on, which
took years for several reasons, one of which was precisely waiting for
actual users for APIs.
[ Others were getting maintainers engaged and involved for some of the
core APIs/subsystems, getting authors of the original code to submit
it upstream via patches was yet another, reworking and cleaning the
code with the new, better approaches we found meanwhile (like
pin-init), and so on and so forth. ]
Cheers,
Miguel
More information about the linux-riscv
mailing list