Re: [PATCH v3] rust: io: convert ResourceSize into a transparent newtype
From: Lorenzo Delgado
Date: Sun Sep 27 2026 - 14:12:23 EST
On Thu Sep 24, 2026 at 7:21 PM CEST, Danilo Krummrich wrote:
> So, I think we should change dma_len() to just return u32 (I'm also fine with a
> new type, but it might be slighly overkill).
>
> I'd usually pick this patch regardless and leave that for a follow-up, as it is
> a separate issue. But if we change dma_len() first, we only have to update tyr
> once, whereas if change it after we end up touching nova and tyr twice.
Makes sense, thanks. I sent v4 with a patch in front that makes dma_len()
return u32, so the newtype patch no longer touches tyr or nova-core:
https://lore.kernel.org/r/20260927-resource-size-newtype-v4-0-447a08af23fb@xxxxxxxxx
Heads-up: patch 1 interacts with Alexandre's nova_num on one line in
gsp.rs. Whichever lands second needs a two-line fixup; details in the
cover letter.