Message ID | 20220623212205.2805002-4-deso@posteo.net (mailing list archive) |
---|---|
State | Superseded |
Delegated to: | BPF |
Headers | show |
Series | Introduce type match support | expand |
diff --git a/include/linux/btf.h b/include/linux/btf.h index 1bfed7..54a65a 100644 --- a/include/linux/btf.h +++ b/include/linux/btf.h @@ -242,6 +242,11 @@ static inline u8 btf_int_offset(const struct btf_type *t) return BTF_INT_OFFSET(*(u32 *)(t + 1)); } +static inline u8 btf_int_bits(const struct btf_type *t) +{ + return BTF_INT_BITS(*(u32 *)(t + 1)); +} + static inline u8 btf_int_encoding(const struct btf_type *t) { return BTF_INT_ENCODING(*(u32 *)(t + 1));
This change adds the btf_int_bits() function to include/linux/btf.h. It mirrors what already exists in user space and will be required by follow on changes. Signed-off-by: Daniel Müller <deso@posteo.net> --- include/linux/btf.h | 5 +++++ 1 file changed, 5 insertions(+)