On 8/29/25 5:59 PM, Alexandre Courbot wrote:
On Sat Aug 30, 2025 at 8:30 AM JST, John Hubbard wrote:
On 8/25/25 9:07 PM, Alexandre Courbot wrote:
...
We only support one version of the firmware. And in the coming months,
that one version will have a different version number.
Given those constraints, we should simply remove most (all?) of the "r570_144::"
namespace qualifiers in the code, starting here.
That way, we get:
a) A small diff, instead of a huge one, when we update to a new firmware
version.
b) Shorter, cleaner symbols everywhere: GSP_FW_HEAP_SIZE_OVERRIDE_LIBOS2_MAX_MB
instead of r570_144::GSP_FW_HEAP_SIZE_OVERRIDE_LIBOS2_MAX_MB, for example.
`nvfw` is the module that is supposed to abstract the currently
supported firmware version - but in order to provide this abstraction,
it needs to refer the items in question. :) I don't see how we could
avoid these qualifiers short of having a `use r750_144::*` which could
result into name collisions.
My idea here was: "what name collisions?". There shouldn't be any.
Because again, there is only one firmware version supported at a time.
But maybe we can do a module alias to reduce the diff once the version
changes:
use r570_144 as fwbindings;
...
pub(crate) const LIBOS2_PARAMS: LibosParams = LibosParams {
carveout_size: fwbindings::GSP_FW_HEAP_PARAM_OS_SIZE_LIBOS2 as u64,
Is that what you had in mind?
Not initially, but it would address most of what bothered me here,
which is having a particular version number all over everywhere.
thanks,
--
John Hubbard