Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

rust: bitops: 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>
Signed-off-by: Yury Norov (NVIDIA) <yury.norov@gmail.com>

authored by

Alice Ryhl and committed by
Yury Norov (NVIDIA)
8618307b ac3dc186

+4
+4
rust/helpers/bitops.c
··· 2 2 3 3 #include <linux/bitops.h> 4 4 5 + __rust_helper 5 6 void rust_helper___set_bit(unsigned long nr, unsigned long *addr) 6 7 { 7 8 __set_bit(nr, addr); 8 9 } 9 10 11 + __rust_helper 10 12 void rust_helper___clear_bit(unsigned long nr, unsigned long *addr) 11 13 { 12 14 __clear_bit(nr, addr); 13 15 } 14 16 17 + __rust_helper 15 18 void rust_helper_set_bit(unsigned long nr, volatile unsigned long *addr) 16 19 { 17 20 set_bit(nr, addr); 18 21 } 19 22 23 + __rust_helper 20 24 void rust_helper_clear_bit(unsigned long nr, volatile unsigned long *addr) 21 25 { 22 26 clear_bit(nr, addr);