diff options
| author | Nick Desaulniers <[email protected]> | 2020-11-16 04:35:30 +0000 |
|---|---|---|
| committer | Gustavo A. R. Silva <[email protected]> | 2020-11-18 20:02:13 +0000 |
| commit | 77433830ed164a0bc38dd43877bab3f7f7fd7fa3 (patch) | |
| tree | 97e5197e4316cd4abc5830ed1b29efe84a4505bd /lib/assoc_array.c | |
| parent | Linux 5.10-rc4 (diff) | |
| download | kernel-77433830ed164a0bc38dd43877bab3f7f7fd7fa3.tar.gz kernel-77433830ed164a0bc38dd43877bab3f7f7fd7fa3.zip | |
powerpc: boot: include compiler_attributes.h
The kernel uses `-include` to include include/linux/compiler_types.h
into all translation units (see scripts/Makefile.lib), which #includes
compiler_attributes.h.
arch/powerpc/boot/ uses different compiler flags from the rest of the
kernel. As such, it doesn't contain the definitions from these headers,
and redefines a few that it needs.
For the purpose of enabling -Wimplicit-fallthrough for ppc, include
compiler_attributes.h via `-include`.
It was also noted in 6a9dc5fd6170 that we could -D__KERNEL__ and
-include compiler_types.h like the main kernel does, though testing that
produces a whole sea of warnings to cleanup. This approach is minimally
invasive. And it also helps to entice a cleanup.
Signed-off-by: Nick Desaulniers <[email protected]>
Tested-by: Nathan Chancellor <[email protected]>
Reviewed-by: Nathan Chancellor <[email protected]>
Acked-by: Gustavo A. R. Silva <[email protected]>
Acked-by: Miguel Ojeda <[email protected]>
Acked-by: Michael Ellerman <[email protected]>
Link: https://github.com/ClangBuiltLinux/linux/issues/236
[ Gustavo: Massage a bit as per Miguel's suggestion. ]
Signed-off-by: Gustavo A. R. Silva <[email protected]>
Diffstat (limited to 'lib/assoc_array.c')
0 files changed, 0 insertions, 0 deletions
