Skip to content

Commit 7caeac0

Browse files
Darksonnojeda
authored andcommitted
rust: bug: add __rust_helper to helpers
This is needed to inline these helpers into Rust code. Reviewed-by: Boqun Feng <boqun.feng@gmail.com> Reviewed-by: Gary Guo <gary@garyguo.net> Signed-off-by: Alice Ryhl <aliceryhl@google.com> Link: https://patch.msgid.link/20260105-define-rust-helper-v2-3-51da5f454a67@google.com Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
1 parent 0bfea95 commit 7caeac0

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

rust/helpers/bug.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
#include <linux/bug.h>
44

5-
__noreturn void rust_helper_BUG(void)
5+
__rust_helper __noreturn void rust_helper_BUG(void)
66
{
77
BUG();
88
}
99

10-
bool rust_helper_WARN_ON(bool cond)
10+
__rust_helper bool rust_helper_WARN_ON(bool cond)
1111
{
1212
return WARN_ON(cond);
1313
}

0 commit comments

Comments
 (0)