On Tue Sep 1, 2026 at 9:07 AM CEST, Alistair Popple wrote:
> On 2026-09-01 at 06:42 +1000, Gary Guo <[email protected]> wrote...
>> On Mon Aug 31, 2026 at 9:08 PM BST, Danilo Krummrich wrote:
>> > On Fri Aug 28, 2026 at 5:35 AM CEST, Alistair Popple wrote:
>> >> +/// API handle for the auxiliary bus child drivers to interact with 
>> >> nova-core.
>> >> +pub struct NovaCoreApi<'bound> {
>> >> +    #[expect(unused)]
>> >> +    pub(crate) gpu: Pin<&'bound Gpu<'bound>>,
>> >> +}
>> >> +
>> >> +impl NovaCoreApi<'_> {
>> >> +    /// Obtain a [`NovaCoreApi`] handle from an auxiliary device 
>> >> registered
>> >> +    /// by nova-core.
>> >> +    pub fn of(adev: &auxiliary::Device<Bound>) -> 
>> >> Result<Pin<&NovaCoreApi<'_>>> {
>> >> +        adev.registration_data::<CovariantForLt!(NovaCoreApi<'_>)>()
>> >> +    }
>> >> +}
>> >
>> > CovariantForLt does not hold anymore on latest drm-rust-next, as Cmdq has a
>> > Mutex. So, this needs ForLt now and therefore the approach that I shared 
>> > in [1]
>> > a while ago. I applied the changes in [2] to fix it up.
>
> I can see why the mutex means covariance no longer holds, but I would kind
> of also expect it to not compile given it surely can't be safe here to treat
> an invariant type as covariant. Is this just a limitation of the current
> CovariantForLt implementation not being able to prove covariance or am I 
> missing
> something else? Thanks.

Well, it did not compile (as expected) on my end, which is how I caught it.
What's your base revision?

Reply via email to