diff options
author | Nathan Chancellor <[email protected]> | 2019-08-11 20:31:20 -0700 |
---|---|---|
committer | Paul Burton <[email protected]> | 2019-08-11 21:44:31 -0700 |
commit | c59ae0a1055127dd3828a88e111a0db59b254104 (patch) | |
tree | bac69ce4216487aedbaf33c04eb563ad35422118 /net/switchdev/switchdev.c | |
parent | 077ff3be06e8de2657075dd2738b9a21f8ebd890 (diff) |
MIPS: tlbex: Explicitly cast _PAGE_NO_EXEC to a boolean
clang warns:
arch/mips/mm/tlbex.c:634:19: error: use of logical '&&' with constant
operand [-Werror,-Wconstant-logical-operand]
if (cpu_has_rixi && _PAGE_NO_EXEC) {
^ ~~~~~~~~~~~~~
arch/mips/mm/tlbex.c:634:19: note: use '&' for a bitwise operation
if (cpu_has_rixi && _PAGE_NO_EXEC) {
^~
&
arch/mips/mm/tlbex.c:634:19: note: remove constant to silence this
warning
if (cpu_has_rixi && _PAGE_NO_EXEC) {
~^~~~~~~~~~~~~~~~
1 error generated.
Explicitly cast this value to a boolean so that clang understands we
intend for this to be a non-zero value.
Fixes: 00bf1c691d08 ("MIPS: tlbex: Avoid placing software PTE bits in Entry* PFN fields")
Link: https://github.com/ClangBuiltLinux/linux/issues/609
Signed-off-by: Nathan Chancellor <[email protected]>
Signed-off-by: Paul Burton <[email protected]>
Cc: Ralf Baechle <[email protected]>
Cc: James Hogan <[email protected]>
Cc: Nick Desaulniers <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Diffstat (limited to 'net/switchdev/switchdev.c')
0 files changed, 0 insertions, 0 deletions