[PATCH 5/5] gpu: nova-core: firmware: process and prepare the GSP firmware

Alexandre Courbot acourbot at nvidia.com
Fri Aug 22 13:04:27 UTC 2025


On Fri Aug 22, 2025 at 9:57 PM JST, Danilo Krummrich wrote:
> Hi Alex,
>
> not a full review yet, but a few ad-hoc comments from skimming over it.
>
> On Fri Aug 22, 2025 at 2:47 PM CEST, Alexandre Courbot wrote:
>> +/// A device-mapped firmware with a set of (also device-mapped) pages tables mapping the firmware
>> +/// to the start of their own address space.
>> +pub(crate) struct GspFirmware {
>> +    /// The GSP firmware inside a [`VVec`], device-mapped via a SG table.
>> +    #[expect(unused)]
>
> Do we expect this to change? Otherwise, just prefix the field name with an
> underscore.

Yes, all the fields marked unused are eventually used in incoming
patches.

>
>> +    fw: Pin<KBox<SGTable<Owned<VVec<u8>>>>>,
>> +    /// The level 2 page table, mapping [`Self::fw`] at its beginning.
>> +    #[expect(unused)]
>> +    lvl2: Pin<KBox<SGTable<Owned<VVec<u8>>>>>,
>> +    /// The level 1 page table, mapping [`Self::lvl2`] at its beginning.
>> +    #[expect(unused)]
>> +    lvl1: Pin<KBox<SGTable<Owned<VVec<u8>>>>>,
>
> Instead of creating three allocations, just make struct GspFirmware pin_data by
> itself. This should even propagate down to struct Gpu, which is pin_data.
>
> So everything can be in one single allocation.

Ah, I was actually wondering - thanks, will try and do that.


More information about the Nouveau mailing list