You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Newtypes allow to constrain what operations make sense on a value in order to prevent mistakes.
Please consider whether providing a newtype for the PhysAddr type alias would make sense and what operations could be provided for it -- please see #1198 for a similar thread about Offset.
At the time of writing, the patches would need to be based on top of that patch series.
Please take the chance as well to write a couple examples/tests for the newtype.
This requires submitting a proper patch to the LKML and the Rust for Linux mailing list. Please recall to test your changes (including generating the documentation if changed, running the Rust doctests if changed, etc.), to use a proper title for the commit, to sign your commit under the Developer's Certificate of Origin and to add a Suggested-by: tag, and a Link: tag to this issue. Please see https://docs.kernel.org/process/submitting-patches.html and https://rust-for-linux.com/contributing for details.
Activity
rust: Convert PhysAddr type alias into newtype
rust: Convert PhysAddr type alias into newtype
Convert the use of `phys_addr_t` in the Rust kernel bindings into a
quinnjr commentedon May 20, 2026
Hello @ojeda is this issue still open for needing work?
ojeda commentedon May 25, 2026
Please see https://lore.kernel.org/rust-for-linux/20260504045714.59248-1-albabhasan276@gmail.com/ which in turn points to https://lore.kernel.org/rust-for-linux/20260505082323.37335-1-x@2005.tr/
Helping to review the one from Favilances would be nice if you have the time!