Re: [PATCH 1/4] drm/tyr: name resource lifetimes after their types

From: Danilo Krummrich

Date: Thu Nov 19 2026 - 11:38:27 EST


On Thu Nov 19, 2026 at 4:44 PM CET, Alice Ryhl wrote:
> On Thu, Nov 19, 2026 at 02:57:37PM +0100, Danilo Krummrich wrote:
>> I think in the end it comes down to personal preference, so this is fine with me
>> too.
>>
>> Though, I'd use a generic name in the latter case too, such that it doesn't need
>> to be changed once a second resource is referenced later on.
>
> Agreed, using a generic name like `'a` (or borrowed-resource names for
> invariant lifetimes) sounds good to me too.
>
> Also, when updating this for v2, note that `VmAsData<'drm>` in
> `mmu/address_space.rs` and `GpuVmData<'drm>` (along with `VmMapArgs`,
> `VmOpType`, `VmOpResources`, `VmOpRequest`, and `PtUpdateContext` in
> `vm.rs`) were still left using `'drm`.

Before I respin I'll wait for Gary to look into how the existential lifetime
could be moved to Vm (which is what I considered initially, but couldn't really
get to work).

I think having it on Firmware is reasonable, but I think having it on Vm would
probably be better.