]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
rust: use custom FFI integer types
authorGary Guo <gary@garyguo.net>
Fri, 7 Mar 2025 22:50:06 +0000 (23:50 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 13 Mar 2025 12:01:49 +0000 (13:01 +0100)
commit641ecd0d0a219eb624bbb7fd610e589e55528c0b
tree5e23ac49f0e7fc063f97c19600805e9a4516d4c2
parent0ea8582faa7692d1082f74990d527ee7f1259bb5
rust: use custom FFI integer types

commit d072acda4862f095ec9056979b654cc06a22cc68 upstream.

Currently FFI integer types are defined in libcore. This commit creates
the `ffi` crate and asks bindgen to use that crate for FFI integer types
instead of `core::ffi`.

This commit is preparatory and no type changes are made in this commit
yet.

Signed-off-by: Gary Guo <gary@garyguo.net>
Link: https://lore.kernel.org/r/20240913213041.395655-4-gary@garyguo.net
[ Added `rustdoc`, `rusttest` and KUnit tests support. Rebased on top of
  `rust-next` (e.g. migrated more `core::ffi` cases). Reworded crate
  docs slightly and formatted. - Miguel ]
Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
23 files changed:
rust/Makefile
rust/ffi.rs [new file with mode: 0644]
rust/kernel/alloc/allocator.rs
rust/kernel/alloc/allocator_test.rs
rust/kernel/alloc/kbox.rs
rust/kernel/block/mq/operations.rs
rust/kernel/block/mq/raw_writer.rs
rust/kernel/block/mq/tag_set.rs
rust/kernel/error.rs
rust/kernel/init.rs
rust/kernel/lib.rs
rust/kernel/net/phy.rs
rust/kernel/str.rs
rust/kernel/sync/arc.rs
rust/kernel/sync/condvar.rs
rust/kernel/sync/lock.rs
rust/kernel/sync/lock/mutex.rs
rust/kernel/sync/lock/spinlock.rs
rust/kernel/task.rs
rust/kernel/time.rs
rust/kernel/types.rs
rust/kernel/uaccess.rs
rust/macros/module.rs