(Cc: Miguel)

On Fri Aug 28, 2026 at 7:33 AM CEST, Alexandre Courbot wrote:
> The `kernel` crate now features a replacement for our lossless integer
> conversion routines. Switch to the kernel version and remove our own.
>
> Signed-off-by: Alexandre Courbot <[email protected]>
> Reviewed-by: Danilo Krummrich <[email protected]>
> Reviewed-by: Eliot Courtney <[email protected]>
> ---
>  drivers/gpu/nova-core/falcon.rs                    |  12 +-
>  drivers/gpu/nova-core/falcon/fsp.rs                |   4 +-
>  drivers/gpu/nova-core/fb.rs                        |   2 +-
>  drivers/gpu/nova-core/fb/hal/gb100.rs              |   6 +-
>  drivers/gpu/nova-core/firmware.rs                  |   4 +-
>  drivers/gpu/nova-core/firmware/booter.rs           |   4 +-
>  drivers/gpu/nova-core/firmware/fwsec.rs            |   2 +-
>  drivers/gpu/nova-core/firmware/fwsec/bootloader.rs |   4 +-
>  drivers/gpu/nova-core/firmware/gsp.rs              |   9 +-
>  drivers/gpu/nova-core/firmware/tlv.rs              |  11 +-
>  drivers/gpu/nova-core/fsp.rs                       |   8 +-
>  drivers/gpu/nova-core/gsp.rs                       |   4 +-
>  drivers/gpu/nova-core/gsp/cmdq.rs                  |  22 +--
>  drivers/gpu/nova-core/gsp/fw.rs                    |  42 ++--
>  drivers/gpu/nova-core/gsp/fw/commands.rs           |   4 +-
>  drivers/gpu/nova-core/gsp/sequencer.rs             |   2 +-
>  drivers/gpu/nova-core/mctp.rs                      |   8 +-
>  drivers/gpu/nova-core/num.rs                       | 211 
> ---------------------
>  drivers/gpu/nova-core/vbios.rs                     |   2 +-
>  19 files changed, 78 insertions(+), 283 deletions(-)

Please see the discussion in [1].

If we make this change, then the subsequent conversion to const_as!() would need
to go through the Rust tree next cycle, which could be a bit of a mess, as I'd
expect a bunch of conflicts.

Alternatively, we could the the full three cycle dance, or have a signed tag for
const_as!() and use it right away.

But honestly, the former would just be unnecessary noise. If we don't do the
latter, let's just keep the nova-core num module until the dust has been
settled.

[1] 
https://lore.kernel.org/all/CANiq72k+-fNWZCwGuQ=FTchxgm-X-f6WR=tG=ercn19ic1e...@mail.gmail.com/

Reply via email to