Powerpc: maple_defconfig: kernel/rtas_pci.c:46:5: error: no previous prototype for function 'rtas_read_config' [-Werror,-Wmissing-prototypes]

From: Naresh Kamboju
Date: Mon Nov 27 2023 - 05:24:39 EST


Following Powerpc maple_defconfig and other builds failed with gcc-13 / 8
and clang toolchains on Linux next-20231127 tag.

build:
* gcc-8-cell_defconfig
* gcc-8-maple_defconfig
* gcc-8-tinyconfig
* gcc-13-tinyconfig
* gcc-13-cell_defconfig
* gcc-13-maple_defconfig
* clang-17-cell_defconfig
* clang-17-tinyconfig
* clang-17-maple_defconfig
* clang-nightly-cell_defconfig
* clang-nightly-maple_defconfig
* clang-nightly-tinyconfig

Reported-by: Linux Kernel Functional Testing <lkft@xxxxxxxxxx>

Build logs:
-----------
arch/powerpc/kernel/rtas_pci.c:46:5: error: no previous prototype for
function 'rtas_read_config' [-Werror,-Wmissing-prototypes]
46 | int rtas_read_config(struct pci_dn *pdn, int where, int size, u32 *val)
| ^
arch/powerpc/kernel/rtas_pci.c:46:1: note: declare 'static' if the
function is not intended to be used outside of this translation unit
46 | int rtas_read_config(struct pci_dn *pdn, int where, int size, u32 *val)
| ^
| static
arch/powerpc/kernel/rtas_pci.c:98:5: error: no previous prototype for
function 'rtas_write_config' [-Werror,-Wmissing-prototypes]
98 | int rtas_write_config(struct pci_dn *pdn, int where, int size, u32 val)
| ^
arch/powerpc/kernel/rtas_pci.c:98:1: note: declare 'static' if the
function is not intended to be used outside of this translation unit
98 | int rtas_write_config(struct pci_dn *pdn, int where, int size, u32 val)
| ^
| static
2 errors generated.
make[5]: *** [scripts/Makefile.build:243:
arch/powerpc/kernel/rtas_pci.o] Error 1

steps to reproduce:

# tuxmake --runtime podman --target-arch powerpc --toolchain clang-17
--kconfig maple_defconfig LLVM=1 LLVM_IAS=0
LD=powerpc64le-linux-gnu-ld



Links:
- https://qa-reports.linaro.org/lkft/linux-next-master/build/next-20231127/testrun/21324129/suite/build/test/clang-17-maple_defconfig/log
- https://qa-reports.linaro.org/lkft/linux-next-master/build/next-20231127/testrun/21324129/suite/build/test/clang-17-maple_defconfig/history/
- https://storage.tuxsuite.com/public/linaro/lkft/builds/2Yk9XaK95NuGJL9barjaXrOWxib/

--
Linaro LKFT
https://lkft.linaro.org