[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20241108031012.335203-10-alistair.francis@wdc.com>
Date: Fri, 8 Nov 2024 13:10:10 +1000
From: Alistair Francis <alistair23@...il.com>
To: a.hindborg@...nel.org,
boqun.feng@...il.com,
bjorn3_gh@...tonmail.com,
alistair.francis@....com,
rust-for-linux@...r.kernel.org,
me@...enk.dev,
benno.lossin@...ton.me,
aliceryhl@...gle.com,
tmgross@...ch.edu,
linux-kernel@...r.kernel.org,
alex.gaynor@...il.com,
ojeda@...nel.org,
gary@...yguo.net
Cc: alistair23@...il.com
Subject: [PATCH v2 09/11] rust: helpers: Remove some spinlock helpers
Now that we support wrap-static-fns we no longer need the custom helpers.
Signed-off-by: Alistair Francis <alistair.francis@....com>
---
rust/bindgen_static_functions | 4 ++++
rust/helpers/spinlock.c | 15 ---------------
2 files changed, 4 insertions(+), 15 deletions(-)
diff --git a/rust/bindgen_static_functions b/rust/bindgen_static_functions
index 407dd091ddec..9d6c44e277b5 100644
--- a/rust/bindgen_static_functions
+++ b/rust/bindgen_static_functions
@@ -20,3 +20,7 @@
--allowlist-function refcount_dec_and_test
--allowlist-function signal_pending
+
+--allowlist-function spin_lock
+--allowlist-function spin_unlock
+--allowlist-function spin_trylock
diff --git a/rust/helpers/spinlock.c b/rust/helpers/spinlock.c
index b7b0945e8b3c..1c47608c42ed 100644
--- a/rust/helpers/spinlock.c
+++ b/rust/helpers/spinlock.c
@@ -11,18 +11,3 @@ void rust_helper___spin_lock_init(spinlock_t *lock, const char *name,
spin_lock_init(lock);
#endif
}
-
-void rust_helper_spin_lock(spinlock_t *lock)
-{
- spin_lock(lock);
-}
-
-void rust_helper_spin_unlock(spinlock_t *lock)
-{
- spin_unlock(lock);
-}
-
-int rust_helper_spin_trylock(spinlock_t *lock)
-{
- return spin_trylock(lock);
-}
--
2.47.0
Powered by blists - more mailing lists