Re: [PATCH v10 6/8] rust: gpu: Add GPU buddy allocator bindings
From: Joel Fernandes
Date: Thu Feb 19 2026 - 10:34:51 EST
On Thu, Feb 19, 2026 at 02:13:37PM +0900, Alexandre Courbot wrote:
> > + types::Opaque,
>
> Need a `//` or `rustfmt` will reformat.
Fixed, thanks.
> > +// SAFETY: [`GpuBuddyInner`] can be sent between threads.
>
> No need to link on non-doccomments.
Fixed. Removed the brackets from SAFETY comments for GpuBuddyInner
and GpuBuddyGuard.
> > +/// - `buddy` references a valid [`GpuBuddyInner`].
>
> rustdoc complains that this links to a private item in a public doc - we
> should not mention `GpuBuddyInner` here.
Per Miguel's reply, I've kept the mention but removed the square
brackets so it doesn't try to create a link. This way it's still
mentioned for practical reference without triggering the rustdoc
warning.
> > /// as references from [`CListIter`] during iteration over [`AllocatedBlocks`].
>
> Link should be [`CListIter`](kernel::ffi::clist::CListIter) to resolve.
> But maybe we don't need to share that detail in the public
> documentation?
Agreed, removed the CListIter reference from the public doc. It now
just says "as references during iteration over AllocatedBlocks".
Thanks,
Joel