Re: [PATCH 2/3] rust: xarray: abstract `xa_alloc_cyclic`
From: Miguel Ojeda
Date: Tue Oct 07 2025 - 13:28:44 EST
On Tue, Oct 7, 2025 at 7:19 PM Onur Özkan <work@xxxxxxxxxxxxx> wrote:
>
> Why do we not like to use the bindings type directly?
For public APIs, we generally try to avoid exposing C types:
https://docs.kernel.org/rust/general-information.html#abstractions-vs-bindings
Sometimes it still makes sense, of course, e.g. a method may return
an inner type so that it gets used by other abstractions to call into
C. But generally we want to avoid exposing those for drivers and other
abstractions wherever possible.
Cheers,
Miguel