Skip to content

Commit c455f19

Browse files
DarksonnAndreas Hindborg
authored andcommitted
rust: xarray: 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> Acked-by: Tamir Duberstein <tamird@gmail.com> Link: https://lore.kernel.org/r/20260105-define-rust-helper-v2-27-51da5f454a67@google.com Signed-off-by: Andreas Hindborg <a.hindborg@kernel.org>
1 parent 9ace475 commit c455f19

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

rust/helpers/xarray.c

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

33
#include <linux/xarray.h>
44

5-
int rust_helper_xa_err(void *entry)
5+
__rust_helper int rust_helper_xa_err(void *entry)
66
{
77
return xa_err(entry);
88
}
99

10-
void rust_helper_xa_init_flags(struct xarray *xa, gfp_t flags)
10+
__rust_helper void rust_helper_xa_init_flags(struct xarray *xa, gfp_t flags)
1111
{
1212
return xa_init_flags(xa, flags);
1313
}
1414

15-
int rust_helper_xa_trylock(struct xarray *xa)
15+
__rust_helper int rust_helper_xa_trylock(struct xarray *xa)
1616
{
1717
return xa_trylock(xa);
1818
}
1919

20-
void rust_helper_xa_lock(struct xarray *xa)
20+
__rust_helper void rust_helper_xa_lock(struct xarray *xa)
2121
{
2222
return xa_lock(xa);
2323
}
2424

25-
void rust_helper_xa_unlock(struct xarray *xa)
25+
__rust_helper void rust_helper_xa_unlock(struct xarray *xa)
2626
{
2727
return xa_unlock(xa);
2828
}

0 commit comments

Comments
 (0)