diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2025-11-06 11:54:59 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2025-11-06 11:54:59 -0800 |
| commit | c90841db3524657204c096fd47283817cfdbd2f9 (patch) | |
| tree | c4afd66c44d8b3832c3004d2492234c3b9444d9b /include | |
| parent | Merge tag 'net-6.18-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/net... (diff) | |
| parent | libeth: xdp: Disable generic kCFI pass for libeth_xdp_tx_xmit_bulk() (diff) | |
| download | linux-c90841db3524657204c096fd47283817cfdbd2f9.tar.gz linux-c90841db3524657204c096fd47283817cfdbd2f9.zip | |
Merge tag 'hardening-v6.18-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux
Pull hardening fixes from Kees Cook:
"This is a work-around for a (now fixed) corner case in the arm32 build
with Clang KCFI enabled.
- Introduce __nocfi_generic for arm32 Clang (Nathan Chancellor)"
* tag 'hardening-v6.18-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/kees/linux:
libeth: xdp: Disable generic kCFI pass for libeth_xdp_tx_xmit_bulk()
ARM: Select ARCH_USES_CFI_GENERIC_LLVM_PASS
compiler_types: Introduce __nocfi_generic
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/compiler_types.h | 6 | ||||
| -rw-r--r-- | include/net/libeth/xdp.h | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/include/linux/compiler_types.h b/include/linux/compiler_types.h index 59288a2c1ad2..1414be493738 100644 --- a/include/linux/compiler_types.h +++ b/include/linux/compiler_types.h @@ -461,6 +461,12 @@ struct ftrace_likely_data { # define __nocfi #endif +#if defined(CONFIG_ARCH_USES_CFI_GENERIC_LLVM_PASS) +# define __nocfi_generic __nocfi +#else +# define __nocfi_generic +#endif + /* * Any place that could be marked with the "alloc_size" attribute is also * a place to be marked with the "malloc" attribute, except those that may diff --git a/include/net/libeth/xdp.h b/include/net/libeth/xdp.h index bc3507edd589..898723ab62e8 100644 --- a/include/net/libeth/xdp.h +++ b/include/net/libeth/xdp.h @@ -513,7 +513,7 @@ struct libeth_xdp_tx_desc { * can't fail, but can send less frames if there's no enough free descriptors * available. The actual free space is returned by @prep from the driver. */ -static __always_inline u32 +static __always_inline __nocfi_generic u32 libeth_xdp_tx_xmit_bulk(const struct libeth_xdp_tx_frame *bulk, void *xdpsq, u32 n, bool unroll, u64 priv, u32 (*prep)(void *xdpsq, struct libeth_xdpsq *sq), |
