kbuild: rust: remove the `alloc` crate and `GlobalAlloc`
authorDanilo Krummrich <dakr@kernel.org>
Fri, 4 Oct 2024 15:41:32 +0000 (17:41 +0200)
committerMiguel Ojeda <ojeda@kernel.org>
Tue, 15 Oct 2024 21:10:32 +0000 (23:10 +0200)
commit392e34b6bc22077ef63abf62387ea3e9f39418c1
tree9abf0e5a381a7f2bd776f4960478485f138528ed
parent8ae740c3917ff92108df17236b3cf1b9a74bd359
kbuild: rust: remove the `alloc` crate and `GlobalAlloc`

Now that we have our own `Allocator`, `Box` and `Vec` types we can remove
Rust's `alloc` crate and the `new_uninit` unstable feature.

Also remove `Kmalloc`'s `GlobalAlloc` implementation -- we can't remove
this in a separate patch, since the `alloc` crate requires a
`#[global_allocator]` to set, that implements `GlobalAlloc`.

Signed-off-by: Danilo Krummrich <dakr@kernel.org>
Link: https://lore.kernel.org/r/20241004154149.93856-29-dakr@kernel.org
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
rust/Makefile
rust/exports.c
rust/kernel/alloc/allocator.rs
scripts/Makefile.build
scripts/generate_rust_analyzer.py