Re: [PATCH 2/6] gpu: nova-core: gsp: sequencer: do not store sequence into GspSequencer
From: Eliot Courtney
Date: Mon Jun 22 2026 - 03:02:38 EST
On Fri Jun 19, 2026 at 10:42 PM JST, Alexandre Courbot wrote:
> The sequence is currently stored in the `GspSequencer` even though its
> lifetime is limited to `GspSequencer::run`. This object-oriented design
> does not play well with the borrow-checker, as `GspSequencer::iter`
> borrows a reference to the `GspSequencer`, which makes it difficult to
> introduce mutable references in `GspBootContext`, as we want to do in
> order to make the `Falcon` references mutable.
>
> Thus, store the sequence locally in `GspSequencer::run`, and move
> iterator creation to `GspSeqIter::new` so it no longer needs to borrow
> the whole `GspSequencer`.
>
> Signed-off-by: Alexandre Courbot <acourbot@xxxxxxxxxx>
> ---
Reviewed-by: Eliot Courtney <ecourtney@xxxxxxxxxx>