On Wed Jun 24, 2026 at 4:00 PM BST, Alvin Sun wrote: > Move `Module`, `InPlaceModule`, `ModuleMetadata` and `ThisModule` from > `lib.rs` into a new `rust/kernel/module.rs`. Re-export them from `lib.rs` > to avoid tree-wide changes. > > Switch six bus driver registrations from `module.0` to the public > `ThisModule::as_ptr()` accessor, since the field is no longer visible > outside the new `module` submodule. > > No functional change. > > Assisted-by: opencode:glm-5.2 > Acked-by: Danilo Krummrich <[email protected]> > Signed-off-by: Alvin Sun <[email protected]>
Suggested-by: Gary Guo <[email protected]> Link: https://lore.kernel.org/all/[email protected]/ Reviewed-by: Gary Guo <[email protected]> > --- > rust/kernel/auxiliary.rs | 2 +- > rust/kernel/i2c.rs | 2 +- > rust/kernel/lib.rs | 75 > +++++------------------------------------------- > rust/kernel/module.rs | 71 +++++++++++++++++++++++++++++++++++++++++++++ > rust/kernel/net/phy.rs | 6 +++- > rust/kernel/pci.rs | 2 +- > rust/kernel/platform.rs | 2 +- > rust/kernel/usb.rs | 2 +- > 8 files changed, 88 insertions(+), 74 deletions(-)

