Re: Build regressions/improvements in v5.8-rc5

From: Michael Ellerman
Date: Tue Jul 14 2020 - 04:50:02 EST


Geert Uytterhoeven <geert@xxxxxxxxxxxxxx> writes:
> On Mon, Jul 13, 2020 at 11:51 AM Geert Uytterhoeven
> <geert@xxxxxxxxxxxxxx> wrote:
>> JFYI, when comparing v5.8-rc5[1] to v5.8-rc4[3], the summaries are:
>> - build errors: +3/-0
>
> + /kisskb/src/include/linux/compiler-gcc.h: error: #error Sorry,
> your compiler is too old - please upgrade it.: => 15:3
> + /kisskb/src/include/linux/compiler.h: error: implicit declaration
> of function '_Generic' [-Werror=implicit-function-declaration]: =>
> 309:2
> + /kisskb/src/include/linux/compiler_types.h: error: expected
> expression before 'char': => 265:5
>
> arcompact/axs101_defconfig, which uses a pre-v4.9 gcc:
>
> Compiler: arcompact (arc-buildroot-linux-uclibc-gcc (Buildroot
> 2015.08.1) 4.8.4 / GNU ld (GNU Binutils) 2.23.2)
>
> While at it, you may also want to upgrade
>
> Compiler: arcv2 (arc-linux-gcc.br_real (Buildroot
> 2016.11-git-00613-ge98b4dd) 6.2.1 20160824 / GNU ld (GNU Binutils)
> 2.27.51.20160928)
>
> as it has a buggy definition of size_t, and causes bogus warnings like:
>
>> + /kisskb/src/drivers/gpu/drm/drm_managed.c: warning: format '%zu' expects argument of type 'size_t', but argument 4 has type 'unsigned int' [-Wformat=]: => 205:23
>> + /kisskb/src/drivers/gpu/drm/drm_managed.c: warning: format '%zu' expects argument of type 'size_t', but argument 6 has type 'unsigned int' [-Wformat=]: => 67:23
>> + /kisskb/src/include/linux/kern_levels.h: warning: format '%zd' expects argument of type 'signed size_t', but argument 2 has type 'ssize_t {aka int}' [-Wformat=]: => 5:18
>> + /kisskb/src/kernel/dma/pool.c: warning: format '%zu' expects argument of type 'size_t', but argument 5 has type 'unsigned int' [-Wformat=]: => 249:16

Thanks.

It seems the kernel.org 10.1.0 toolchain can build both arcv2 and
arcompact, so I've added an arc-gcc10 and moved both defconfigs to that
toolchain. Hopefully that will work.

cheers