Re: [PATCH v12 01/22] gpu: nova-core: gsp: Return GspStaticInfo from boot()
From: Alexandre Courbot
Date: Tue May 05 2026 - 20:47:15 EST
On Wed May 6, 2026 at 3:25 AM JST, Joel Fernandes wrote:
>
>
> On 5/2/2026 11:41 AM, Alexandre Courbot wrote:
>> On Sun Apr 26, 2026 at 6:14 AM JST, Joel Fernandes wrote:
>>> Refactor the GSP boot function to return GetGspStaticInfoReply.
>>>
>>> This enables access required for memory management initialization to:
>>> - bar1_pde_base: BAR1 page directory base.
>>> - bar2_pde_base: BAR2 page directory base.
>>> - usable memory regions in video memory.
>>>
>>> Reviewed-by: Eliot Courtney <ecourtney@xxxxxxxxxx>
>>> Reviewed-by: John Hubbard <jhubbard@xxxxxxxxxx>
>>> Cc: Nikola Djukic <ndjukic@xxxxxxxxxx>
>>> Signed-off-by: Joel Fernandes <joelagnelf@xxxxxxxxxx>
>>> ---
>>> drivers/gpu/nova-core/gpu.rs | 8 ++++++--
>>> drivers/gpu/nova-core/gsp/boot.rs | 12 ++++++++----
>>> 2 files changed, 14 insertions(+), 6 deletions(-)
>>>
>>> diff --git a/drivers/gpu/nova-core/gpu.rs b/drivers/gpu/nova-core/gpu.rs
>>> index 0f6fe9a1b955..f2a8915a1ff4 100644
>>> --- a/drivers/gpu/nova-core/gpu.rs
>>> +++ b/drivers/gpu/nova-core/gpu.rs
>>> @@ -21,7 +21,10 @@
>>> },
>>> fb::SysmemFlush,
>>> gfw,
>>> - gsp::Gsp,
>>> + gsp::{
>>> + commands::GetGspStaticInfoReply,
>>> + Gsp, //
>>> + },
>>> regs,
>>> };
>>>
>>> @@ -238,6 +241,7 @@ pub(crate) struct Gpu {
>>> /// GSP runtime data. Temporarily an empty placeholder.
>>> #[pin]
>>> gsp: Gsp,
>>> + gsp_static_info: GetGspStaticInfoReply,
>>
>> A short doccomment would be nice, but otherwise this looks good.
>
> I had added one before, but John suggested to drop it. I could add it back again
> if all agree on what we want to do. I am Ok with either though I'd lean more to
> the fact that its not necessary since it will basically read like the variable.
Without is fine, the name/type is indeed explicit enough. I was worried
that Clippy would start complaining if we need to make this type public
once nova-drm calls into nova-core. But we can fix that if it actually
happens.