You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
uapi: bitops: use UAPI-safe variant of BITS_PER_LONG again
commit 11fcf36 upstream.
Commit 1e7933a ("uapi: Revert "bitops: avoid integer overflow in GENMASK(_ULL)"")
did not take in account that the usage of BITS_PER_LONG in __GENMASK() was
changed to __BITS_PER_LONG for UAPI-safety in
commit 3c7a8e1 ("uapi: introduce uapi-friendly macros for GENMASK").
BITS_PER_LONG can not be used in UAPI headers as it derives from the kernel
configuration and not from the current compiler invocation.
When building compat userspace code or a compat vDSO its value will be
incorrect.
Switch back to __BITS_PER_LONG.
Fixes: 1e7933a ("uapi: Revert "bitops: avoid integer overflow in GENMASK(_ULL)"")
Cc: [email protected]
Signed-off-by: Thomas Weißschuh <[email protected]>
Signed-off-by: Yury Norov [NVIDIA] <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
0 commit comments