Skip to contentSkip to conversation

Alloc changes for 7.2-rc1

GIT PULL Applied Danilo Krummrich 2 participants 2 messages May 25 – May 28 Rust

lore
Share & tools
lore

Danilo Krummrich

author reviewer
#0 lore raw

Hi Miguel,

There's one trivial import conflict with a patch that I took through the driver-core tree.

Thanks,
Danilo

The following changes since commit 254f49634ee16a731174d2ae34bc50bd5f45e731:

Linux 7.1-rc1 (2026-04-26 14:19:00 -0700)

are available in the Git repository at:

https://github.com/Rust-for-Linux/linux.git tags/alloc-7.2-rc1

for you to fetch changes up to ec51531fb8efda9b75316111c040dd756f815b0c:

rust: alloc: cleanup doctest imports to "kernel vertical" style (2026-05-20 17:34:17 +0200)

----------------------------------------------------------------
Alloc changes for 7.2-rc1

- Fix the Vec::reserve() doc test to properly account for the existing vector length in the capacity assertion

- Fix an incorrect operator in the Vec::extend_with() SAFETY comment; add a doc test demonstrating basic usage and the zero-length case

- Cleanup all imports in the alloc module and its doctests to use the "kernel vertical" import style

----------------------------------------------------------------
Danilo Krummrich (2):
rust: alloc: cleanup imports and use "kernel vertical" style
rust: alloc: cleanup doctest imports to "kernel vertical" style

Hsiu Che Yu (3):
rust: alloc: fix assert in Vec::reserve doc test
rust: alloc: add doc test for Vec::extend_with
rust: alloc: fix Vec::extend_with SAFETY comment

 rust/kernel/alloc.rs                |  8 ++++++--
 rust/kernel/alloc/allocator.rs      | 34 ++++++++++++++++++++++++----------
 rust/kernel/alloc/allocator/iter.rs |  8 ++++++--
 rust/kernel/alloc/kbox.rs           | 76 ++++++++++++++++++++++++++++++++++++++++++++++++++++------------------------
 rust/kernel/alloc/kvec.rs           | 81 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++------------------
 rust/kernel/alloc/kvec/errors.rs    |  6 ++++--
 rust/kernel/alloc/layout.rs         | 10 ++++++++--
 7 files changed, 163 insertions(+), 60 deletions(-)
Applied
#1 lore raw
Quoted 5 lines · Danilo Krummrich

The following changes since commit 254f49634ee16a731174d2ae34bc50bd5f45e731:

Linux 7.1-rc1 (2026-04-26 14:19:00 -0700)

Quoted 7 lines

are available in the Git repository at:

https://github.com/Rust-for-Linux/linux.git tags/alloc-7.2-rc1

for you to fetch changes up to ec51531fb8efda9b75316111c040dd756f815b0c:

rust: alloc: cleanup doctest imports to "kernel vertical" style (2026-05-20 17:34:17 +0200)

Merged into rust-next -- thanks!

Cheers,
Miguel