On Thu, 2026-02-05 at 20:21 -0800, John Hubbard wrote:
> + fn client_alloc_size(chipset: Chipset) -> u64 {
> + if crate::fb::hal::fb_hal(chipset)
> + .non_wpr_heap_size()
> + .is_some()
> + {
> + GSP_FW_HEAP_PARAM_CLIENT_ALLOC_SIZE_GH100
> + } else {
> + u64::from(bindings::GSP_FW_HEAP_PARAM_CLIENT_ALLOC_SIZE)
> + }
> + .align_up(GSP_HEAP_ALIGNMENT)
> + .unwrap_or(u64::MAX)
I understand not wanting to return a Result<> for impossible situations, but I
don't know if this is
the answer. For one thing, there is no way we can allocate a heap that large.
Maybe we need to have some kind of infallible align_up() variant, but in this
case, I would say a
panic is warranted.