Re: [PATCH v2 2/3] drm/tyr: use pin-init self-referential support

From: Alice Ryhl

Date: Thu Dec 03 2026 - 05:42:12 EST


On Tue, Dec 1, 2026 at 12:20 AM Danilo Krummrich <dakr@xxxxxxxxxx> wrote:
>
> Now that pin-init supports self-referential structs, Arc is no longer
> needed just to share resources whose lifetimes are bounded by their
> owners.
>
> Use pin-init's self-referential support to share the MMIO mapping, MMU
> and firmware VM through borrows instead of Arc, avoiding their separate
> allocations and reference counts.
>
> Hide the invariant resource lifetime shared by the VM and its sections
> behind an existential lifetime that outlives 'mmu, so Firmware only needs
> a single lifetime parameter.
>
> Cc: Gary Guo <gary@xxxxxxxxxxx>
> Signed-off-by: Danilo Krummrich <dakr@xxxxxxxxxx>

Reviewed-by: Alice Ryhl <aliceryhl@xxxxxxxxxx>