From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 1348C3858C39; Thu, 16 Sep 2021 13:29:57 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1348C3858C39 From: "dac324 at yahoo dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/102361] Errors compiling Linux kernel 5.14.4 with CONFIG_FORTIFY=y Date: Thu, 16 Sep 2021 13:29:56 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: dac324 at yahoo dot de X-Bugzilla-Status: WAITING X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Sep 2021 13:29:57 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D102361 --- Comment #5 from DAC324 --- OK, here we go: make -f ./scripts/Makefile.build obj=3Dmm/kfence \ \ need-builtin=3D1 \ need-modorder=3D1 gcc -Wp,-MMD,mm/.memcontrol.o.d -nostdinc -isystem /usr/lib/gcc/x86_64-pc-linux-gnu/12.0.0/include -I./arch/x86/include -I./arch/x86/include/generated -I./include -I./arch/x86/include/uapi -I./arch/x86/include/generated/uapi -I./include/uapi -I./include/generated/= uapi -include ./include/linux/compiler-version.h -include ./include/linux/kconfi= g.h -include ./include/linux/compiler_types.h -D__KERNEL__ -fmacro-prefix-map= =3D./=3D -Wall -Wundef -Werror=3Dstrict-prototypes -Wno-trigraphs -fno-strict-aliasi= ng -fno-common -fshort-wchar -fno-PIE -Werror=3Dimplicit-function-declaration -Werror=3Dimplicit-int -Werror=3Dreturn-type -Wno-format-security -std=3Dgn= u89 -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -mno-avx -fcf-protection=3Dnone -m64 -falign-jumps=3D1 -falign-loops=3D1 -mno-80387 -mno-fp-ret-in-387 -mpreferred-stack-boundary=3D3 -mskip-rax-setup -march=3Dsandybridge -mno-r= ed-zone -mcmodel=3Dkernel -Wno-sign-compare -fno-asynchronous-unwind-tables -mindirect-branch=3Dthunk-extern -mindirect-branch-register -fno-jump-tables -fno-delete-null-pointer-checks -Wno-frame-address -Wno-format-truncation -Wno-format-overflow -Wno-address-of-packed-member -O2 -fno-allow-store-data-races -Wframe-larger-than=3D2048 -fstack-protector-st= rong -Wimplicit-fallthrough=3D5 -Wno-unused-but-set-variable -Wno-unused-const-variable -fno-stack-clash-protection -g -gdwarf-4 -pg -mrecord-mcount -mfentry -DCC_USING_FENTRY -Wdeclaration-after-statement -W= vla -Wno-pointer-sign -Wno-stringop-truncation -Wno-zero-length-bounds -Wno-array-bounds -Wno-stringop-overflow -Wno-restrict -Wno-maybe-uninitial= ized -fno-strict-overflow -fno-stack-check -fconserve-stack -Werror=3Ddate-time -Werror=3Dincompatible-pointer-types -Werror=3Ddesignated-init -Wno-packed-not-aligned -fplugin=3D./scripts/gcc-plugins/structleak_plugin.= so -fplugin-arg-structleak_plugin-byref-all -DSTRUCTLEAK_PLUGIN=20=20=20 -DKBUILD_MODFILE=3D'"mm/memcontrol"' -DKBUILD_BASENAME=3D'"memcontrol"' -DKBUILD_MODNAME=3D'"memcontrol"' -D__KBUILD_MODNAME=3Dkmod_memcontrol -c -o mm/memcontrol.o mm/memcontrol.c In file included from ./include/linux/string.h:262, from ./include/linux/bitmap.h:10, from ./include/linux/cpumask.h:12, from ./arch/x86/include/asm/paravirt.h:17, from ./arch/x86/include/asm/irqflags.h:63, from ./include/linux/irqflags.h:16, from ./include/linux/rcupdate.h:26, from ./include/linux/rculist.h:11, from ./include/linux/pid.h:5, from ./include/linux/sched.h:14, from ./include/linux/cgroup.h:12, from ./include/linux/memcontrol.h:13, from mm/memcontrol.c:29: In function 'memset', inlined from 'uncharge_gather_clear.part.0' at mm/memcontrol.c:6835:2: ./include/linux/fortify-string.h:172:17: error: call to '__write_overflow' declared with attribute error: detected write beyond size of object passed = as 1st parameter 172 | __write_overflow(); | ^~~~~~~~~~~~~~~~~~ make[1]: *** [scripts/Makefile.build:271: mm/memcontrol.o] Error 1 make: *** [Makefile:1851: mm] Error 2=