diff options
author | Rikard Falkeborn <[email protected]> | 2021-05-22 17:42:02 -0700 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2021-05-22 15:09:07 -1000 |
commit | f747e6667ebb2ffb8133486c9cd19800d72b0d98 (patch) | |
tree | da4178160dfb6592c2a37f9eed45b391b5a47e9f /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | 0f90b88dbcd1143e0f408502eba0af97429c502a (diff) |
linux/bits.h: fix compilation error with GENMASK
GENMASK() has an input check which uses __builtin_choose_expr() to
enable a compile time sanity check of its inputs if they are known at
compile time.
However, it turns out that __builtin_constant_p() does not always return
a compile time constant [0]. It was thought this problem was fixed with
gcc 4.9 [1], but apparently this is not the case [2].
Switch to use __is_constexpr() instead which always returns a compile time
constant, regardless of its inputs.
Link: https://lore.kernel.org/lkml/[email protected] [0]
Link: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=19449 [1]
Link: https://lore.kernel.org/lkml/[email protected] [2]
Link: https://lkml.kernel.org/r/[email protected]
Signed-off-by: Rikard Falkeborn <[email protected]>
Reported-by: Tetsuo Handa <[email protected]>
Acked-by: Arnd Bergmann <[email protected]>
Reviewed-by: Andy Shevchenko <[email protected]>
Cc: Ard Biesheuvel <[email protected]>
Cc: Yury Norov <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions