From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 29240374739; Wed, 11 Mar 2026 08:30:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217807; cv=none; b=pAUE0TS4XgvTbRsnuXwxNmphrw9GQaQ7pjZ0ZvMF9K/MBxxbDp+2JZwLmaQm6ciTwwJnZ2qiJowCtpvFisMHkifXmes7bfVDFCEDg9qoJzY4gOmjfv7jIJUKdHHS7UC/g3aQaowb8+7bl0izqObpms3R9S05jceYm9GI3Sld2/c= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217807; c=relaxed/simple; bh=8ymoW4HHQoUtYOFJa+6mY7ccDMk6/HOaddOLgnwOTic=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=btNKuRJK5uX2vepjvmRq1OJtgFxSDmcDW4Hr0DJQm97fQyM+2xkqlnjYhDg8NwOgOqClN6fMSf7vucuKYOWFSllkC+RRA96EPSOdx7CdRMmkvnjNN/4x7BXzpJhLf3pdId4KBW1Fw0QuRfTj2c8RdmlxkqHDGT5n7X5JnpN/s+4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 5562D165C; Wed, 11 Mar 2026 01:29:59 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 187EF3F73B; Wed, 11 Mar 2026 01:29:57 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:26 +0000 Subject: [PATCH v4 01/30] tools: lib: thermal: Fix typo Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-1-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=766; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=8ymoW4HHQoUtYOFJa+6mY7ccDMk6/HOaddOLgnwOTic=; b=cvedBwezyVxz3woz/mFMPU1/oGrXh8ose15WeulRq3YItL1fn/zM11RUvC6hEaDB5F3xZMcpU f1JSZ7IFq34CoOmgnW1hWfu7e2TF7IPPuG4XqEx0fYPisOU3IgUc5zR X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= s/CFGLAS/CFLAGS Fixes: 47c4b0de080a ("tools/lib/thermal: Add a thermal library") Signed-off-by: Leo Yan Acked-by: Daniel Lezcano --- tools/lib/thermal/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/lib/thermal/Makefile b/tools/lib/thermal/Makefile index 41aa7a324ff4d76351b89d7d7cf382df3fc14052..09d8f4ba6a0ab7ab9c99ac7f64d= 52d0268bee340 100644 --- a/tools/lib/thermal/Makefile +++ b/tools/lib/thermal/Makefile @@ -66,8 +66,8 @@ override CFLAGS +=3D -fPIC override CFLAGS +=3D $(NL3_CFLAGS) override CFLAGS +=3D $(INCLUDES) override CFLAGS +=3D -fvisibility=3Dhidden -override CFGLAS +=3D -Wl,-L. -override CFGLAS +=3D -Wl,-lthermal +override CFLAGS +=3D -Wl,-L. +override CFLAGS +=3D -Wl,-lthermal =20 all: =20 --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AA2453B6340; Wed, 11 Mar 2026 08:30:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217816; cv=none; b=kA70I2RqnoNeloEKwwdQ6wK1lUhAgOYYjvbbRuo1SuljkocDuBdCNpBwUhqosWETSxziozmKMJOvG/OG6YSmzAEk+D121dA8zhch39wcun4Mng2ZHruoDenUM1LKdpcb4tOs+3LL5CRHvR5k3LdWlr8mCAFbZh/thqq1hyDV+JE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217816; c=relaxed/simple; bh=ohdWzHaQ3kzQcv0Ygt+2e5uE+m+KR3HcpWZZjFWxBlo=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=pUqqSm9hf/L7GJDRdHOa4KErZ/nO4lEXIpSbzRpOUPqQl6z6rH7TCZxJ1DNSZzl/V/Cg4qbitKXKrys5OHqwBufkSLGpCpRaTRordXX1LkFvjjgeOim+Vh9vkvwE0fywFcSN9obOKOPl5wJFmBfunD2xqFP+Y+1KFGQter+uo4Q= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id F2A33204C; Wed, 11 Mar 2026 01:30:06 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id BAEE23F73B; Wed, 11 Mar 2026 01:30:05 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:27 +0000 Subject: [PATCH v4 02/30] tools/thermal: Fix typo Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-2-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=755; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=ohdWzHaQ3kzQcv0Ygt+2e5uE+m+KR3HcpWZZjFWxBlo=; b=FJqxegSrNqNtDnY6jdZzx610+RrtAC5xYp8tEvdouZcNlQ+egr6xx2/3dRU063hvj4BNGrteX /mlqzlsIvKlBGn67wpGdAzO7kiGmE/fsjgipwFhT8qhJ9ifLeWg6Gy4 X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= s/CFGLAS/CFLAGS Fixes: 3b7c5e8adf9c ("tools/thermal: Add util library") Signed-off-by: Leo Yan Acked-by: Daniel Lezcano --- tools/thermal/lib/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/thermal/lib/Makefile b/tools/thermal/lib/Makefile index 056d212f25cf51cd8c02260fbe2ef28dda5e4acb..8c9a37f999b826855dad11c0d95= 74b41d5b24244 100644 --- a/tools/thermal/lib/Makefile +++ b/tools/thermal/lib/Makefile @@ -60,8 +60,8 @@ override CFLAGS +=3D $(EXTRA_WARNINGS) override CFLAGS +=3D -Werror -Wall override CFLAGS +=3D -fPIC override CFLAGS +=3D $(INCLUDES) -override CFGLAS +=3D -Wl,-L. -override CFGLAS +=3D -Wl,-lthermal +override CFLAGS +=3D -Wl,-L. +override CFLAGS +=3D -Wl,-lthermal =20 all: =20 --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 713232741DF; Wed, 11 Mar 2026 08:30:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217826; cv=none; b=hul7wgxrmmWZTS1hGb3Xk+hufU/V1za0Q8/HiCtJpwsjkDvhqIGdcLscxWkJi7T3UWGD7RZeWpIx+T4xwqqB4Od9GfX4IYtvrEDClvlgXvnL0t0LeBhGYICVC+tcHbUOWXRqtWItwGqD1LYlayxRy25tmuyFU5AjN8x2EcFfWqQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217826; c=relaxed/simple; bh=mkmGFFMWdiiEQbxcc15mMJc9KkOmMYC/dMkN1+6Ji9s=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=qJGsZzxrNWpna4FYylvr7qTi4xCIong/bw+wqSAfXOcJ9PKMFSMnuBt4Hh7+5NDCci1UxfEtLl5M74+FuB92Y1hARIpGRovxT6GeWkv77isvBFhEyo/oEakh/enZ8VV4MNXtiUy6Ajm5hwt/dK5l8MyNx2Ennq2CwSNayFfUnl0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 9F64A204C; Wed, 11 Mar 2026 01:30:14 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 664FD3F73B; Wed, 11 Mar 2026 01:30:13 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:28 +0000 Subject: [PATCH v4 03/30] tools: lib: thermal: Initialize CFLAGS before including Makefile.include Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-3-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=1997; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=mkmGFFMWdiiEQbxcc15mMJc9KkOmMYC/dMkN1+6Ji9s=; b=0hVcsSXNi9/47VYLKM1iq+lFejB1rgTLWX7/mNYrGYlGgEGqSFVH6DyiC19WaQkrCczMMA2d0 E2ZRdzf1Ku4AZb5lSGjAAsBeesU5GmmAhfMlw1uF7aeaJs2FW9/bujm X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= tools/scripts/Makefile.include may expand EXTRA_CFLAGS in a future change. This could alter the initialization of CFLAGS in the thermal Makefile, as the default options "-g -Wall" would never be set once EXTRA_CFLAGS is expanded. Prepare for this by moving the CFLAGS initialization before including tools/scripts/Makefile.include, so it is not affected by the extended EXTRA_CFLAGS. Append EXTRA_CFLAGS to CFLAGS only after including Makefile.include and place it last so that the extra flags propagate properly and can override the default options. Signed-off-by: Leo Yan Acked-by: Daniel Lezcano --- tools/lib/thermal/Makefile | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/tools/lib/thermal/Makefile b/tools/lib/thermal/Makefile index 09d8f4ba6a0ab7ab9c99ac7f64d52d0268bee340..b55fa42cefa47628b7f2fac32fc= 08fcd82580a0e 100644 --- a/tools/lib/thermal/Makefile +++ b/tools/lib/thermal/Makefile @@ -23,6 +23,14 @@ INSTALL =3D install DESTDIR ?=3D DESTDIR_SQ =3D '$(subst ','\'',$(DESTDIR))' =20 +# Defer assigning EXTRA_CFLAGS to CFLAGS until after including +# tools/scripts/Makefile.include, as it may add flags to EXTRA_CFLAGS. +ifdef EXTRA_CFLAGS + CFLAGS :=3D +else + CFLAGS :=3D -g -Wall +endif + include $(srctree)/tools/scripts/Makefile.include include $(srctree)/tools/scripts/Makefile.arch =20 @@ -39,13 +47,6 @@ libdir =3D $(prefix)/$(libdir_relative) libdir_SQ =3D $(subst ','\'',$(libdir)) libdir_relative_SQ =3D $(subst ','\'',$(libdir_relative)) =20 -# Set compile option CFLAGS -ifdef EXTRA_CFLAGS - CFLAGS :=3D $(EXTRA_CFLAGS) -else - CFLAGS :=3D -g -Wall -endif - NL3_CFLAGS =3D $(shell pkg-config --cflags libnl-3.0 2>/dev/null) ifeq ($(NL3_CFLAGS),) NL3_CFLAGS =3D -I/usr/include/libnl3 @@ -68,6 +69,7 @@ override CFLAGS +=3D $(INCLUDES) override CFLAGS +=3D -fvisibility=3Dhidden override CFLAGS +=3D -Wl,-L. override CFLAGS +=3D -Wl,-lthermal +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 all: =20 --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1E3993B9DA3; Wed, 11 Mar 2026 08:30:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217832; cv=none; b=XcLUpDd9VZ6iMnbdrCA57SqOrlxt8dl7RhZnP2CxdklbM7P3u3RMQf5TWgkPtLgKDVCss1ItIn6v25i4oNtbzhQ14atrvFL6IWPHwwjEwdTDv2vv0jFZ61hBxzsNvZMkipVfXETUYNi+1dQDW4Lzx6K2Xh3Ir2HJyHDcHn+Otco= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217832; c=relaxed/simple; bh=BFehMj28QR2IYXlxOIJtUAyqZ+kYk51QCcp6lZ5W+HY=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=PyZj9+I1PoZbhLwLdIIYCfPgDrWKuxTctI2lty3GOTjvTjVx4Lw2r6eTFl9wGGNwEXAV1UVM14l5l+cZAaF0rMw9mudHVq7FCHfbJIVqFO7RweUhe6M/51Wa1ZoxQUUpg1PtET1i2ZsPGH9wwwXg/RaNx2hHR1iF+a2AffJeCdA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 4A4E120E3; Wed, 11 Mar 2026 01:30:22 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 12E153F73B; Wed, 11 Mar 2026 01:30:20 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:29 +0000 Subject: [PATCH v4 04/30] tools/thermal: Initialize CFLAGS before including Makefile.include Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-4-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=1994; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=BFehMj28QR2IYXlxOIJtUAyqZ+kYk51QCcp6lZ5W+HY=; b=cIChBhbXzWOGCjFWyrlvI7qAP1G9ikd5pzspc3mYPH7b69uzYJJGJzbQ64GG7BjcqRzI4Viho XVaQszhOcWNDEszo+vW5EZ4+yU+A2Dwir+C+jbkOmsgst7zAt6PcxHw X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= tools/scripts/Makefile.include may expand EXTRA_CFLAGS in a future change. This could alter the initialization of CFLAGS in the thermal Makefile, as the default options "-g -Wall" would never be set once EXTRA_CFLAGS is expanded. Prepare for this by moving the CFLAGS initialization before including tools/scripts/Makefile.include, so it is not affected by the extended EXTRA_CFLAGS. Append EXTRA_CFLAGS to CFLAGS only after including Makefile.include and place it last so that the extra flags propagate properly and can override the default options. Acked-by: Daniel Lezcano Signed-off-by: Leo Yan --- tools/thermal/lib/Makefile | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/tools/thermal/lib/Makefile b/tools/thermal/lib/Makefile index 8c9a37f999b826855dad11c0d9574b41d5b24244..333b711bc7f0f9610e165ff7dc7= 2c42980c59c99 100644 --- a/tools/thermal/lib/Makefile +++ b/tools/thermal/lib/Makefile @@ -23,6 +23,14 @@ INSTALL =3D install DESTDIR ?=3D DESTDIR_SQ =3D '$(subst ','\'',$(DESTDIR))' =20 +# Defer assigning EXTRA_CFLAGS to CFLAGS until after including +# tools/scripts/Makefile.include, as it may add flags to EXTRA_CFLAGS. +ifdef EXTRA_CFLAGS + CFLAGS :=3D +else + CFLAGS :=3D -g -Wall +endif + include $(srctree)/tools/scripts/Makefile.include include $(srctree)/tools/scripts/Makefile.arch =20 @@ -39,13 +47,6 @@ libdir =3D $(prefix)/$(libdir_relative) libdir_SQ =3D $(subst ','\'',$(libdir)) libdir_relative_SQ =3D $(subst ','\'',$(libdir_relative)) =20 -# Set compile option CFLAGS -ifdef EXTRA_CFLAGS - CFLAGS :=3D $(EXTRA_CFLAGS) -else - CFLAGS :=3D -g -Wall -endif - INCLUDES =3D \ -I/usr/include/libnl3 \ -I$(srctree)/tools/lib/thermal/include \ @@ -62,6 +63,7 @@ override CFLAGS +=3D -fPIC override CFLAGS +=3D $(INCLUDES) override CFLAGS +=3D -Wl,-L. override CFLAGS +=3D -Wl,-lthermal +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 all: =20 --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D7C5C3BADA6; Wed, 11 Mar 2026 08:30:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217841; cv=none; b=arbjPaCXVQW9+3926bMHjwTrGZjHLUjd/G3aXw/b7QMm/QSDEEhIPAHAHdhtPdzEsHrFuC/4pARrsoF9a3LhGZiOJ9M4lPfmPCaBkhJFu6Gg56MY8vbL/11FFokqU8v51Pt4Sy8JlVNt0QK5i5jjwMCcsXFuSXXKd41bTXc5mqQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217841; c=relaxed/simple; bh=WM6eh+uCyejH6wIt9/C1ZZ9YLOLPrcxUmJlFRRJ40zM=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=u5noK+3pX31glcDCkSJNXT2DuAGv5ZMgZpMMFbBQHltixc0y/WBeUJJ2+IY8qNEbryXXPA7o4PntvsIBoF79l59wA1fjnmbGwqy3ErrbIHi8WWRxo34oAw5dH414e/reYg0OU9SBeGy4IHdwAC54tE3dTIrcb7HiFcXTpSpsn9I= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id F139D2050; Wed, 11 Mar 2026 01:30:29 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id B1DB33F73B; Wed, 11 Mar 2026 01:30:28 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:30 +0000 Subject: [PATCH v4 05/30] bpftool: Avoid adding EXTRA_CFLAGS to HOST_CFLAGS Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-5-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=1436; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=WM6eh+uCyejH6wIt9/C1ZZ9YLOLPrcxUmJlFRRJ40zM=; b=AX5ygT7o789kWjNCr+Hi0sW7qCH4wNnmL5QDZ0Yc3lbK4gd64g8HZbJl9gVupvu2p0xA2UtXS LOU0a3HayNNCatI4O8VFT2uixNICvIfcAAguFQ5pRzrfiCUEvlm+Gm0 X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Prepare for future changes where EXTRA_CFLAGS may include flags not applicable to the host compiler. Move the HOST_CFLAGS assignment before appending EXTRA_CFLAGS to CFLAGS so that HOST_CFLAGS does not inherit flags from EXTRA_CFLAGS. Acked-by: Quentin Monnet Signed-off-by: Leo Yan --- tools/bpf/bpftool/Makefile | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/tools/bpf/bpftool/Makefile b/tools/bpf/bpftool/Makefile index 519ea5cb8ab1c0ee31acc67fc5f96b40e21005c2..3e7d8359e1b2a81a29a47544be8= 539e3b191a0e8 100644 --- a/tools/bpf/bpftool/Makefile +++ b/tools/bpf/bpftool/Makefile @@ -81,6 +81,12 @@ CFLAGS +=3D -DPACKAGE=3D'"bpftool"' -D__EXPORTED_HEADERS= __ \ ifneq ($(BPFTOOL_VERSION),) CFLAGS +=3D -DBPFTOOL_VERSION=3D'"$(BPFTOOL_VERSION)"' endif + +# This must be done before appending EXTRA_CFLAGS to CFLAGS to avoid +# including flags that are not applicable to the host compiler. +HOST_CFLAGS :=3D $(subst -I$(LIBBPF_INCLUDE),-I$(LIBBPF_BOOTSTRAP_INCLUDE)= ,\ + $(subst $(CLANG_CROSS_FLAGS),,$(CFLAGS))) + ifneq ($(EXTRA_CFLAGS),) CFLAGS +=3D $(EXTRA_CFLAGS) endif @@ -88,8 +94,6 @@ ifneq ($(EXTRA_LDFLAGS),) LDFLAGS +=3D $(EXTRA_LDFLAGS) endif =20 -HOST_CFLAGS :=3D $(subst -I$(LIBBPF_INCLUDE),-I$(LIBBPF_BOOTSTRAP_INCLUDE)= ,\ - $(subst $(CLANG_CROSS_FLAGS),,$(CFLAGS))) HOST_LDFLAGS :=3D $(LDFLAGS) =20 INSTALL ?=3D install --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B6E873019D6; Wed, 11 Mar 2026 08:30:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217849; cv=none; b=pm967/HsefFVtUP1wcBI/UnH/JTv2+TH3UAmReUi9XyNbqh3nKmME4sTBlb3D4YPzn9ZPOyyxZdQxWOsmri7Sbqbdea61nj1vMqo0uVP46myFPBaB9b6Dtnh5Rgv0mowHgIXoG2QHgYvOktJazgpICvhYNBAJ2HDdGRpHLEY+8U= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217849; c=relaxed/simple; bh=3JBtHvIDMUinCUvCQDVcAxYVgAKb4KwLtcs/EMqdCS4=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=t0O3L/hTFLL1kNqbC33bRTGt6/T1uNiVAztNQXQYtoXaWfZ5E4EkLqEpnYVmLcjN977+vjMQApbCQ52ZQwiuaAvNO+iE2YOxwH8+2GqxqolY65az5XInmYBVxA7dwGAao3ecevTvGeoUUJqkdRB/7Srs30snq5v29hYZHeE9GV0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id A4A99169C; Wed, 11 Mar 2026 01:30:37 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 64EB53F73B; Wed, 11 Mar 2026 01:30:36 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:31 +0000 Subject: [PATCH v4 06/30] libbpf: Remove duplicate $(CLANG_CROSS_FLAGS) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-6-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=930; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=3JBtHvIDMUinCUvCQDVcAxYVgAKb4KwLtcs/EMqdCS4=; b=p+22TTJrUX/SZDUA8t2BfYihFjcvgWYmi810CV1GqYqJXosdHCZ3lNHmv22rky2XJhVwbXJtN 6wvPb/+rFBcAHwGJVU8Ke273dMt13nzQY6xOcKkGyCjHVzUPaW1L15s X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= tools/scripts/Makefile.include already appends $(CLANG_CROSS_FLAGS) to CFLAGS: CFLAGS +=3D $(CLANG_CROSS_FLAGS) Since Makefile.include is included, the libbpf Makefile appends $(CLANG_CROSS_FLAGS) again, resulting in duplicate flags. Remove the redundant append. Signed-off-by: Leo Yan --- tools/lib/bpf/Makefile | 1 - 1 file changed, 1 deletion(-) diff --git a/tools/lib/bpf/Makefile b/tools/lib/bpf/Makefile index 168140f8e6461bd06db40e23d21a3fb8847ccbf4..b1fbd0211c5edde7be3d98630b1= 6e53e028d9116 100644 --- a/tools/lib/bpf/Makefile +++ b/tools/lib/bpf/Makefile @@ -84,7 +84,6 @@ override CFLAGS +=3D -Werror -Wall override CFLAGS +=3D $(INCLUDES) override CFLAGS +=3D -fvisibility=3Dhidden override CFLAGS +=3D -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=3D64 -override CFLAGS +=3D $(CLANG_CROSS_FLAGS) =20 # flags specific for shared library SHLIB_FLAGS :=3D -DSHARED -fPIC --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 23C7D3358B6; Wed, 11 Mar 2026 08:30:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217854; cv=none; b=BHbZm3Cc1EowPXdyvBGO5KShqF8pI/ehpbnVr0LVg2hJNWY54Mnhg26Np9T+NLIkTLdqf2uM1gJfPncblehQ6KJtyIGJbbPlDQAu6nMly0lM91xC0NxFXjhdtmVZ4mTJtUHXcya/i242S2HF6Jz1WhU4InshdEJ1HBX9cra5T2w= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217854; c=relaxed/simple; bh=lwUdbNhCM4sMoT9afn20u31yKY7rBPrK42zn1LVlLAo=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=lPubWw+eiLalaFIJqcUyaANhm+/R1EoXL4cbySS4yjb3uoyoq98nmf/xn7jZMycwHWTGcmMH+6AQYEFcNDKFYiO13rpyKzjV52Pl4exDcn9Vc45IdzlK4wLHAgfpAUSde5q04aq0qUz0OjuVebeP7UAKxHIsFANTJOSvkL1IX+U= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 59993169C; Wed, 11 Mar 2026 01:30:45 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 1661C3F73B; Wed, 11 Mar 2026 01:30:43 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:32 +0000 Subject: [PATCH v4 07/30] libbpf: Initialize CFLAGS before including Makefile.include Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-7-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=2016; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=lwUdbNhCM4sMoT9afn20u31yKY7rBPrK42zn1LVlLAo=; b=GdKfa01WQ7EkzzQs+te2K50YYy3uDWjVtIqcP10O+ayAEW55IWUt0xlTbNxpXIDO2MzJ87s+m bTBGCOX5yjiAJkYH4vaiiMcN8JenuCarMb1LY19qZ+uUGkCcj54pZjb X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= tools/scripts/Makefile.include may expand EXTRA_CFLAGS in a future change. This could alter the initialization of CFLAGS, as the default options "-g -O2" would never be set once EXTRA_CFLAGS is expanded. Prepare for this by moving the CFLAGS initialization before including tools/scripts/Makefile.include, so it is not affected by the extended EXTRA_CFLAGS. Append EXTRA_CFLAGS to CFLAGS only after including Makefile.include and place it last so that the extra flags propagate properly and can override the default options. Signed-off-by: Leo Yan --- tools/lib/bpf/Makefile | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/tools/lib/bpf/Makefile b/tools/lib/bpf/Makefile index b1fbd0211c5edde7be3d98630b16e53e028d9116..eca584fb061e16013e76827e420= 3f6be0477a73e 100644 --- a/tools/lib/bpf/Makefile +++ b/tools/lib/bpf/Makefile @@ -49,6 +49,14 @@ man_dir_SQ =3D '$(subst ','\'',$(man_dir))' export man_dir man_dir_SQ INSTALL export DESTDIR DESTDIR_SQ =20 +# Defer assigning EXTRA_CFLAGS to CFLAGS until after including +# tools/scripts/Makefile.include, as it may add flags to EXTRA_CFLAGS. +ifdef EXTRA_CFLAGS + CFLAGS :=3D +else + CFLAGS :=3D -g -O2 +endif + include $(srctree)/tools/scripts/Makefile.include =20 # copy a bit from Linux kbuild @@ -70,13 +78,6 @@ LIB_TARGET =3D libbpf.a libbpf.so.$(LIBBPF_VERSION) LIB_FILE =3D libbpf.a libbpf.so* PC_FILE =3D libbpf.pc =20 -# Set compile option CFLAGS -ifdef EXTRA_CFLAGS - CFLAGS :=3D $(EXTRA_CFLAGS) -else - CFLAGS :=3D -g -O2 -endif - # Append required CFLAGS override CFLAGS +=3D -std=3Dgnu89 override CFLAGS +=3D $(EXTRA_WARNINGS) -Wno-switch-enum @@ -84,6 +85,7 @@ override CFLAGS +=3D -Werror -Wall override CFLAGS +=3D $(INCLUDES) override CFLAGS +=3D -fvisibility=3Dhidden override CFLAGS +=3D -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=3D64 +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 # flags specific for shared library SHLIB_FLAGS :=3D -DSHARED -fPIC --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C2D6A3BD25F; Wed, 11 Mar 2026 08:30:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217861; cv=none; b=fP8yRbIBInfv1bWapAAB4sCDuXmh6T34hSgGXLSI/Y2Fd2zZxyEpxFRyuB78YZJPoA46q0Eq5DO6PKYJUnx08L1Fiwvgv5P/27YqAN1da6h9P38acgH9vxSbd3FYtqAhaBkR+4FoYTbF38Pe6BAUKp5phgroE8B1rN/528pOJSE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217861; c=relaxed/simple; bh=Zf23jjDdukq6aA1unK78mG7Z1am+W/Xsg0v3ZsXdH74=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=HYSNHjX1rzukJGKhUcJ9w34llekTDL8gc3RBXTETizzUtxMlgCE+301yO5N1lj/zQYux9yJw/XoVdnRRpjrwxyxVcmokEGyZBzcoJWGbssCbXDnuhDlpGaQzUW0pEcVLQXrcvw4Z7D+XFubs/o23s+dlPgrBIno49OhJJlopEJo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 082E7165C; Wed, 11 Mar 2026 01:30:53 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id BECFA3F73B; Wed, 11 Mar 2026 01:30:51 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:33 +0000 Subject: [PATCH v4 08/30] tools build: Append -fzero-init-padding-bits=all to extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-8-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=2759; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=Zf23jjDdukq6aA1unK78mG7Z1am+W/Xsg0v3ZsXdH74=; b=47Zz9toRF5QkF8s+CZ08X4lfjrR0tXvVy/KZikwKgIuQcXAqb663Gd1JQ//EGeZz5CcnHLFEq fZQi/hIZrCBBuHduE+qaN+JCKaQamsZngJ5wZ3DRv0A+nyak8i0MdxP X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= GCC-15 release claims [1]: {0} initializer in C or C++ for unions no longer guarantees clearing of the whole union (except for static storage duration initialization), it just initializes the first union member to zero. If initialization of the whole union including padding bits is desirable, use {} (valid in C23 or C++) or use -fzero-init-padding-bits=3Dunions option to restore old GCC behavior. As a result, this new behaviour might cause unexpected data when we initialize a union with using the '{ 0 }' initializer. Since commit dce4aab8441d ("kbuild: Use -fzero-init-padding-bits=3Dall"), the kernel has enabled -fzero-init-padding-bits=3Dall to zero padding bits in unions and structures. This commit applies the same option for tools building. The option is not supported by any version older than GCC 15, nor is it supported by LLVM. This patch adds the cc-option and host-cc-option functions to dynamically detect compiler option and append it to the EXTRA_CFLAGS and HOST_EXTRACFLAGS respectively. [1] https://gcc.gnu.org/gcc-15/changes.html Acked-by: Quentin Monnet Signed-off-by: Leo Yan Acked-by: Namhyung Kim --- tools/scripts/Makefile.include | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/tools/scripts/Makefile.include b/tools/scripts/Makefile.include index b5ecf137febcae59f506e107a7f2e2ad72f4bef4..a2397ceae512c1bc54adb15cb1a= 111ff34e28e43 100644 --- a/tools/scripts/Makefile.include +++ b/tools/scripts/Makefile.include @@ -137,6 +137,36 @@ else EXTRA_WARNINGS +=3D -Wshadow endif =20 +# output directory for tests below +TMPOUT =3D .tmp_$$$$ + +# try-run +# Usage: option =3D $(call try-run, $(CC)...-o "$$TMP",option-ok,otherwise) +# Exit code chooses option. "$$TMP" serves as a temporary file and is +# automatically cleaned up. +try-run =3D $(shell set -e; \ + TMP=3D$(TMPOUT)/tmp; \ + trap "rm -rf $(TMPOUT)" EXIT; \ + mkdir -p $(TMPOUT); \ + if ($(1)) >/dev/null 2>&1; \ + then echo "$(2)"; \ + else echo "$(3)"; \ + fi) + +# cc-option +# Usage: CFLAGS +=3D $(call cc-option,-march=3Dwinchip-c6,-march=3Di586) +cc-option =3D $(call try-run, \ + $(CC) -Werror $(1) -c -x c /dev/null -o "$$TMP",$(1),$(2)) + +host-cc-option =3D $(call try-run, \ + $(HOSTCC) -Werror $(1) -c -x c /dev/null -o "$$TMP",$(1),$(2)) + +# Explicitly clear padding bits with the initializer '{ 0 }' +FLAG_ZERO_INIT :=3D $(call cc-option,-fzero-init-padding-bits=3Dall) +override EXTRA_CFLAGS +=3D $(FLAG_ZERO_INIT) +HOST_FLAG_ZERO_INIT :=3D $(call host-cc-option,-fzero-init-padding-bits=3D= all) +override HOST_EXTRACFLAGS +=3D $(HOST_FLAG_ZERO_INIT) + ifneq ($(findstring $(MAKEFLAGS), w),w) PRINT_DIR =3D --no-print-directory else --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8249A3BED43; Wed, 11 Mar 2026 08:31:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217869; cv=none; b=e0KZiS8ABvDA9+imtifPuKv1y/MyhbovACWv5yKeWhz4F8DCGHPxsw1tUcGYcFahesTSyq5dBpo5Wg0xM8wXGXNZk4uoPVyBNCxN/bvo1EeMmWZOhIwVvq/LOZlcp2HuCCim1lVsOsUxEIYHVs7KKN03X2y8z3Kojm4HqhRWp20= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217869; c=relaxed/simple; bh=7+wT4XqOtfZrTnarTeuayBt59FLu6mtAfaIIVesnRow=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=QqVFMgUXgENWgMDsj8NXfEfh1DsOjVvZFTUuhIUGnUDJQb8w2UQowQjcvjO8+IcUGlAdYmwEZqE+rkqpFA4HSbzy3Rif2Wsr7IrwrFiGDNey+fD551V7Wo7FANY6vkj4MiXDBlC3PDLZ4SO1s7S+Nr5mtXWZ7hAFsB03wj5ANH0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id AB586165C; Wed, 11 Mar 2026 01:31:00 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 6DE983F73B; Wed, 11 Mar 2026 01:30:59 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:34 +0000 Subject: [PATCH v4 09/30] bpftool: Append extra host flags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-9-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=824; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=7+wT4XqOtfZrTnarTeuayBt59FLu6mtAfaIIVesnRow=; b=o8V1UhLif7/3n1E41IGWqzeAhSiroao04VGZxLJqJy2NvVXcbmsqlbrQToK6bXTdXNceWPZjR m6EVf8ZLQjJD6CUvd0YQ/ijGoI5EtkzwcxivSCPUWfNCtXgqSAkDWm9 X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append HOST_EXTRACFLAGS to HOST_CFLAGS so that additional flags can be applied to the host compiler. Acked-by: Quentin Monnet Signed-off-by: Leo Yan --- tools/bpf/bpftool/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/bpf/bpftool/Makefile b/tools/bpf/bpftool/Makefile index 3e7d8359e1b2a81a29a47544be8539e3b191a0e8..762fcf0e62a189625053798ddde= af17d409fe248 100644 --- a/tools/bpf/bpftool/Makefile +++ b/tools/bpf/bpftool/Makefile @@ -86,6 +86,7 @@ endif # including flags that are not applicable to the host compiler. HOST_CFLAGS :=3D $(subst -I$(LIBBPF_INCLUDE),-I$(LIBBPF_BOOTSTRAP_INCLUDE)= ,\ $(subst $(CLANG_CROSS_FLAGS),,$(CFLAGS))) +HOST_CFLAGS +=3D $(HOST_EXTRACFLAGS) =20 ifneq ($(EXTRA_CFLAGS),) CFLAGS +=3D $(EXTRA_CFLAGS) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 288523C060B; Wed, 11 Mar 2026 08:31:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217876; cv=none; b=OByIYD+VjJP9miMts31l3O1rwX+k+9gHB5DO6X2s9uigrXtEFEM0hCqO7muXvkbna3+SHGRa8fWVLSIP+x+7vTYc1cvAkVSjOFfLz3rpjR0BBwD/3oQk0M1+OLp9FkyGiWmpDH5yZAWUiZXRarFnm2F+uhIJPNwHi808iDWOtM0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217876; c=relaxed/simple; bh=UN0Max7qbwkYOGlwk9cg0egNBdEm8uSkyaEHFi5qcp8=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=VPnQJPFBZ+TsSLUjUZNeP1n8fnpAFv35Snzu2qESmCp4EVsoUauqmoUGqmAq/24OW2xBkFor2c4a8v9OJRSyiP4mSgEN0s6nk8CH03N7RO8q6Yi5KlLANPgN/sDpLCP9cQNnPfIVddhgb+5iEn90TKpv1JFsj+jWy6XWPehKfu4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 5992F204C; Wed, 11 Mar 2026 01:31:08 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 1BF623F73B; Wed, 11 Mar 2026 01:31:07 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:35 +0000 Subject: [PATCH v4 10/30] perf build: Append extra host flags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-10-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=1040; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=UN0Max7qbwkYOGlwk9cg0egNBdEm8uSkyaEHFi5qcp8=; b=tyLt7u8N/XQ5XNMFAn1gVNdusZVnOCnohFRDx9Dg2ztoFoYyhu/wzwwDMsAvtweA1a6PzH/N6 8dUS4dT2jzIDFLDWr2GE9XE24iuoGoH+53PKFub8kvDwd9mljGHhrgZ X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append HOST_EXTRACFLAGS to HOST_CFLAGS so that additional flags can be applied to the host compiler. Signed-off-by: Leo Yan Acked-by: Namhyung Kim --- tools/perf/Makefile.config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/perf/Makefile.config b/tools/perf/Makefile.config index a8dc72cfe48eec52bd9e2352c46c88f5d8047765..f4004ec148a19c784bfe3ee9b5c= c3901a3db25a3 100644 --- a/tools/perf/Makefile.config +++ b/tools/perf/Makefile.config @@ -17,7 +17,7 @@ detected =3D $(shell echo "$(1)=3Dy" >> $(OUTPU= T).config-detected) detected_var =3D $(shell echo "$(1)=3D$($(1))" >> $(OUTPUT).config-detecte= d) =20 CFLAGS :=3D $(EXTRA_CFLAGS) $(filter-out -Wnested-externs,$(EXTRA_WARNINGS= )) -HOSTCFLAGS :=3D $(filter-out -Wnested-externs,$(EXTRA_WARNINGS)) +HOSTCFLAGS :=3D $(HOST_EXTRACFLAGS) $(filter-out -Wnested-externs,$(EXTRA_= WARNINGS)) =20 # This is required because the kernel is built with this and some of the c= ode # borrowed from kernel headers depends on it, e.g. put_unaligned_*(). --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id B40E13C13E5; Wed, 11 Mar 2026 08:31:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217885; cv=none; b=rgMtv9bP9YiTkOVJ2D3IlmDgA7EKbikBF/Tq7Y9PnbIXex3Riciwg27wp/25qr4HSF3EsWEWhTis4Gpj8C9T/GkeuPZTMf6Gs8kaB09KVnM+dfrng8O42jNvnza+/2PFrkXZIezC6T2rKz2qIB/vd8SvunX+LCY28ZQtucU2604= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217885; c=relaxed/simple; bh=QVECXhBfSn3HTksxV9ctf7sdfgmuzFaQvCXjb24QcOs=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=eDlLErSJXrX4TYzSs1ZruYoShNwTBf5IDq4mVXmcvqd2ZyKziGOaPh9njZFU706vbgP35maRbBsUkVMYTKZL9dIQQcNFu4zj3FdJO3XD9ASFJJkVATR3Y+rOBx4jvsKasbohbqIUhnjvqOHvr0zetWKKvc9SRKoaxXNVXvzU9a0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 0A555204C; Wed, 11 Mar 2026 01:31:16 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id C09BD3F73B; Wed, 11 Mar 2026 01:31:14 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:36 +0000 Subject: [PATCH v4 11/30] tools/bpf: build: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-11-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=742; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=QVECXhBfSn3HTksxV9ctf7sdfgmuzFaQvCXjb24QcOs=; b=bIAxNwmOymk0GpiAaVvrHDRp4zoqlZhN/YE1uT56gMePf0cKZmiUiXmjq2pb1hCQGe6u48WZN B5nG5LY0wxNDit08WTIFvQxc9DL22E8utTEzFhtFjxZJtzTHfxwt9Hd X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Signed-off-by: Leo Yan --- tools/bpf/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/bpf/Makefile b/tools/bpf/Makefile index fd2585af1252669c59228af3a77320e449e1a1ab..9c19e81f3c274767c3b9b94c907= cbbe3ce9fe78c 100644 --- a/tools/bpf/Makefile +++ b/tools/bpf/Makefile @@ -11,6 +11,7 @@ INSTALL ?=3D install CFLAGS +=3D -Wall -O2 CFLAGS +=3D -D__EXPORTED_HEADERS__ -I$(srctree)/tools/include/uapi \ -I$(srctree)/tools/include +CFLAGS +=3D $(EXTRA_CFLAGS) =20 # This will work when bpf is built in tools env. where srctree # isn't set and when invoked from selftests build, where srctree --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A3F343B3896; Wed, 11 Mar 2026 08:31:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217892; cv=none; b=SSw3VqYSO+JiYl9qjdgYcTrwCIt6XE7iy17VYbV7xy5pKR66RUJI66toe7Rz9DRKIQh/idFAtoGfGvh5950F0vHuHRk204IenIgzRrNX8eKznwetA0rXKN7fHz77QtEE5BEcAE4XwoBPoB/I1nor/zqTZzmUFUBiufQ8B0rWWh0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217892; c=relaxed/simple; bh=0TpM015mdI0CN+mqigvDg23igDU/tcPA05QcOwRCOOA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=SGJfqx8/8AFQsA2VulGDNjuAhRB9QKHbY72cjMYijcvunuuCNM06PvQRTYydf0Qni15q24R5TwLgVvy16cp8f3W0/9eK86/WpU34wcmCXDqLaeALp7XOt2cZF9bovRKTmRWqI5M0UqivyxkUh+6QBXY9i39KcXAK3MsJC66vF8w= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id AB7F4204C; Wed, 11 Mar 2026 01:31:23 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 6F5263F73B; Wed, 11 Mar 2026 01:31:22 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:37 +0000 Subject: [PATCH v4 12/30] tools build: Append extra host cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-12-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=1108; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=0TpM015mdI0CN+mqigvDg23igDU/tcPA05QcOwRCOOA=; b=vRreUdsyXWQNLlb/b4gWKbcFMxmIWUB6gQRht43f0yrh1LFE63vZE4JZbA+8WWfA9Se2dolUz oRgNPLZEFGBATxo4/V9b62ZON5235HZmMdrLhpyjK8KScoNxj6VxP1F X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append HOST_EXTRACFLAGS to HOSTCFLAGS so that additional flags can be applied to the host compiler. Signed-off-by: Leo Yan --- tools/build/Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/build/Makefile b/tools/build/Makefile index 3a5a3808ab2a1dedd40f35ea322913e8a0788130..a86ce3d99e2bb1c005942d9c321= 91e6eaa55cf50 100644 --- a/tools/build/Makefile +++ b/tools/build/Makefile @@ -40,14 +40,16 @@ endif FIXDEP :=3D $(OUTPUT)fixdep FIXDEP_IN :=3D $(OUTPUT)fixdep-in.o =20 +HOSTCFLAGS :=3D $(HOST_EXTRACFLAGS) $(KBUILD_HOSTCFLAGS) + # To track fixdep's dependencies properly, fixdep needs to run on itself. # Build it twice the first time. $(FIXDEP_IN): FORCE $(Q)if [ ! -f $(FIXDEP) ]; then \ - $(MAKE) $(build)=3Dfixdep HOSTCFLAGS=3D"$(KBUILD_HOSTCFLAGS)"; \ + $(MAKE) $(build)=3Dfixdep HOSTCFLAGS=3D"$(HOSTCFLAGS)"; \ rm -f $(FIXDEP).o; \ fi - $(Q)$(MAKE) $(build)=3Dfixdep HOSTCFLAGS=3D"$(KBUILD_HOSTCFLAGS)" + $(Q)$(MAKE) $(build)=3Dfixdep HOSTCFLAGS=3D"$(HOSTCFLAGS)" =20 =20 $(FIXDEP): $(FIXDEP_IN) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 16C75253B42; Wed, 11 Mar 2026 08:31:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217900; cv=none; b=ndNMhxIJIyZAM5J3dVrGELRGEpET6NRPZzmUvX60hnPMvCrEcKeKZSQ3sNKFwQNlF6X6ST5ziWSTm1n/19R7pniCG/XzRl73Civ5coV5pb54uZCGSZH1J+jvZfN3R0JZBcDe4K2ms23OBQ3EwYUX5ue2WFh7zuG1HmSkwntTHAU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217900; c=relaxed/simple; bh=k31Kk/i0K4ZvTRnARLSwM6pAc2QmOSVp+PsTzUqEpMA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=bbX4B1j/nrVq5f8pE/izTmrQkzAtjwR22LENm97ouLOqwsO2dnM+9wTWHg6HVEvIdwGBcZ6RYj29eqz/zQukO5qmwfWHckWSppVNsZnowfPt2tMhy8EXLXQFVSxhJMXa230ckXSeGisZsTSihM0QGuxLxkWrBqOd8iIQrWijo2w= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 5CB44204C; Wed, 11 Mar 2026 01:31:31 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 1F9A73F73B; Wed, 11 Mar 2026 01:31:30 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:38 +0000 Subject: [PATCH v4 13/30] tools: bootconfig: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-13-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=793; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=k31Kk/i0K4ZvTRnARLSwM6pAc2QmOSVp+PsTzUqEpMA=; b=oRJIIXqGhZ/R9FmHKI36iS0sekjPQXbmXw4UgP4uonj5AquD5lM1/pVmKISP0fZKcmW8QOYhX ZcIfeVnrlWCCVQxIY6k6edHM0nT8+jL/oTrF3nbSk1JH46EZN6N7Tu/ X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Acked-by: Masami Hiramatsu (Google) Signed-off-by: Leo Yan --- tools/bootconfig/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/bootconfig/Makefile b/tools/bootconfig/Makefile index 90eb47c9d8de67b0ccc74a8de0af3a7e0b97feeb..4490df707585acf356153b78cb8= 7760f622a6190 100644 --- a/tools/bootconfig/Makefile +++ b/tools/bootconfig/Makefile @@ -11,6 +11,7 @@ endif =20 LIBSRC =3D $(srctree)/lib/bootconfig.c $(srctree)/include/linux/bootconfig= .h override CFLAGS +=3D -Wall -g -I$(CURDIR)/include +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 ALL_TARGETS :=3D bootconfig ALL_PROGRAMS :=3D $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS)) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 94A81139D; Wed, 11 Mar 2026 08:31:45 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217906; cv=none; b=DehKiLNkBJB1E0zyUN3s7JsEZGxCGL7WGcS9RScevj9hh7kG+Bjmp21LjozTmBpDl5QWFeGfpHis/V7wM5mL/+bdch62540r4FXJsPpXzcQSPyUU679pppRd+oRPvYrBL3Q4ajLM3dUi6l3YUrjyipT+MolX+7/VeFOBVuG50kw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217906; c=relaxed/simple; bh=8OSCWf/mIU6b3XiEwF8s9we+Qi0eYqNHuTh8/Qvzcfc=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=BbCDHh+rFwo+/D7OI3bpvf+leW1U4OO9WOOh3iNepU0IYkfiHRywR9GX+bee9Gs4RncRGsdfqqqIEBMaFfhp9ilDgKk21pDQf5T2bdkp1s1m83zxknV78C6c4a3FR+J/gqvyu1UsyorLXg9r/ML8bOw9mxLjkQTA4gmRakeKUTA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 0870C204C; Wed, 11 Mar 2026 01:31:39 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id C1E6A3F73B; Wed, 11 Mar 2026 01:31:37 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:39 +0000 Subject: [PATCH v4 14/30] tools: counter: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-14-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=728; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=8OSCWf/mIU6b3XiEwF8s9we+Qi0eYqNHuTh8/Qvzcfc=; b=7INJFa03ZkddNAonl4bXmZ+Dpde0OZZSmIlpf8fuwkzMLSEL8jPhHIvxopW6VhVrxK/Dojyj/ 7Y4ncOBDc5oCTyr8uknuRcv9Vh8j3qTt8uDov4Cf87sQfvXWyNDDoka X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Signed-off-by: Leo Yan --- tools/counter/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/counter/Makefile b/tools/counter/Makefile index d82d35a520f610260abb43f6ae28e56d73268231..1495c0e03d9c00653a24bc92b24= d83340dbb4909 100644 --- a/tools/counter/Makefile +++ b/tools/counter/Makefile @@ -14,6 +14,7 @@ MAKEFLAGS +=3D -r =20 override CFLAGS +=3D -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include \ -I$(srctree)/tools/include +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 ALL_TARGETS :=3D counter_example counter_watch_events ALL_PROGRAMS :=3D $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS)) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 4B2873AC0D6; Wed, 11 Mar 2026 08:31:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217914; cv=none; b=qCVmJUxAyst44P4dNLW1IXshgVlUmFgskFLOZpE0/EtLxZ1uHEf7Y7hFoQM4bhj1gaMUH0rDBEgS3NrP14Em4ouWTXocVXr6omCHbQMU6tGJ3U2kluZuqTKtz9i/7z2plcBaKzKpCZ6LNzZ9phnW33kg+qpv98KPeatNyYMDWAM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217914; c=relaxed/simple; bh=u0baSWrAsWfZfQ+02tVwtELldH7JfFDkqdw4XEPinVI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=VMuC8xfp99DpjSvl4XW8GzOFCQMwV5vaHZSsx7zFYTxxgkXoMZNTVK9RjtzhbC4O1U7JWpXGGPk2z8gomyt/0Av4aoQMbHdOmTBRp+Mr+rhCc8vQZ8ohH2u66DFZGLAytqvfUIVaI6Jr9MuQvttyxfJyqKBZ3zAwHR9x5yP46Sk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id A98D8204C; Wed, 11 Mar 2026 01:31:46 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 6FDDC3F73B; Wed, 11 Mar 2026 01:31:45 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:40 +0000 Subject: [PATCH v4 15/30] tools: dma: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-15-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=709; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=u0baSWrAsWfZfQ+02tVwtELldH7JfFDkqdw4XEPinVI=; b=oy+0S6v6BcKRSD8PUkXqBV2b0hMwplHa1NjmTEJofylP4Ivn+/tEq9IKuAP8P9Det5tU/0FR9 H0U18nUVaQsD+kMHuvldL091xrbD4tkcF/mR7Q7CR6ItiHTTk1X45hT X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Acked-by: Qinxin Xia Signed-off-by: Leo Yan --- tools/dma/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/dma/Makefile b/tools/dma/Makefile index e4abf37bf020ca613b6dca340299198cb887126a..86d3d2e361110b664b885c0e942= 3660a2d5e8221 100644 --- a/tools/dma/Makefile +++ b/tools/dma/Makefile @@ -17,6 +17,7 @@ endif MAKEFLAGS +=3D -r =20 override CFLAGS +=3D -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 ALL_TARGETS :=3D dma_map_benchmark ALL_PROGRAMS :=3D $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS)) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 147C83B9DBC; Wed, 11 Mar 2026 08:32:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217924; cv=none; b=Ux0O6AidIsNcrzLobL64O8yC3Zy/9ta09Imd8gwXVfOEpHyS8Mk/jxruAczKUV93ftGqYyrbG20ZaZJTowXp+lTr5ykg4lv7ZbYbikpEkN2gr66Ou/jwQvl1TPgmUVp4gogNJlBdKHMWPBom6iDyTNmfAg1KxUPjolBN9G4XaGI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217924; c=relaxed/simple; bh=J24uTRo5JzVWWMRzOuokKmYRbu145MN2/Re9B/pDvrA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=hkON77geie8mHSzFmVT9mxWh1D2Wg+irnPFfr7nO6vBpJikafO949H3sLmjzJlpAQKmuNNPfeIZc4BVRBf1F0UWC3OA1X6UibmmGVNwmqWjp+TMDIV5QnqQHcmoaVzoQq9uEtLPpR/COuzNCKey1zsmnUIwEoBcfNhX0BgRcisQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 747C4204C; Wed, 11 Mar 2026 01:31:54 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 1DA043F73B; Wed, 11 Mar 2026 01:31:53 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:41 +0000 Subject: [PATCH v4 16/30] tools: gpio: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-16-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan , Bartosz Golaszewski X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=766; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=J24uTRo5JzVWWMRzOuokKmYRbu145MN2/Re9B/pDvrA=; b=5HOj0C5P9eVgQw50PEoOK2X6SSBOjTo0e3sK3wt5hU0nwh1f4PackkEMvhpWIQhQKMDjuFGqi wVVXFiRB3iiBL/MibdLByqm6+dG99mBDG2SL87vDpsQxKTabvu5KJD1 X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Acked-by: Bartosz Golaszewski Signed-off-by: Leo Yan --- tools/gpio/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/gpio/Makefile b/tools/gpio/Makefile index 342e056c8c665ac075041ff7c7ca7ba94c691187..05a0057ec361626f41ca87e5295= 691364f03d2cb 100644 --- a/tools/gpio/Makefile +++ b/tools/gpio/Makefile @@ -17,6 +17,7 @@ endif MAKEFLAGS +=3D -r =20 override CFLAGS +=3D -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 ALL_TARGETS :=3D lsgpio gpio-hammer gpio-event-mon gpio-watch ALL_PROGRAMS :=3D $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS)) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E76A53C342C; Wed, 11 Mar 2026 08:32:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217931; cv=none; b=fz3VX+9NHM1NJg6moSjo7ptL9AoWaISLpITNPhgLufRto0amJRDp49w4Dq/1JXDo1akOBZ05edwDxuAxiOcjGqzsuRRCd+DKgUrJUxaQhprN/PIPNcBSTujTeXUi/dwxmLA6Yu41rpyPQpgSGlnjQXdR1yibSY4rj0TqxJa1iac= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217931; c=relaxed/simple; bh=hGyktyHY0K6JN8j/3c0flG6pW5kwtw4MxiSqaD6tx9c=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=I0oFwfXF3RgWmBygwUA0L1RCUZVVlWdyKTLRziAJum9hDmwMW5t71AG+lqSsT/vO6T2mJ/R2Ye/hO1ABjmNUX+ObKhQPFhywNRJ3YlsovRQrO079xvKzaVhboCwUogl1KPdrSrgNfiCRYHq16ZloABJ8ZIYwa3vQJirYGXogqt8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 1DFA7169C; Wed, 11 Mar 2026 01:32:02 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id DA4F13F73B; Wed, 11 Mar 2026 01:32:00 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:42 +0000 Subject: [PATCH v4 17/30] tools: hv: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-17-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=734; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=hGyktyHY0K6JN8j/3c0flG6pW5kwtw4MxiSqaD6tx9c=; b=PUW7FKm6Q5/DL0Atupz04pAqGJGRxguCQszfzDEmZJjnAc+9v1yAxwXrxO0ir9S7B/j7swX3v 6EJv+mQryqUCmeht+GCz6X7i7JNSOXP4UtppEj+5AvWKeyLDdAdFiJk X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Reviewed-by: Haiyang Zhang Signed-off-by: Leo Yan --- tools/hv/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/hv/Makefile b/tools/hv/Makefile index 34ffcec264ab0fdf7075d25456ef012cb866796b..a85f2208a8e3c9532b0d2cc750f= c2a872ab4bb07 100644 --- a/tools/hv/Makefile +++ b/tools/hv/Makefile @@ -18,6 +18,7 @@ MAKEFLAGS +=3D -r =20 override CFLAGS +=3D -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include override CFLAGS +=3D -Wno-address-of-packed-member +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 ALL_TARGETS :=3D hv_kvp_daemon hv_vss_daemon ifneq ($(ARCH), aarch64) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9C8883B9DA3; Wed, 11 Mar 2026 08:32:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217937; cv=none; b=kl3bqpF3WbLt66frJenNN8LKI2p6CfX3tcufIpnWNTx5pOlWAWMX6hAyHA9yK47jIKCw7JEW7kKfbqK8pr+8eugOl6Lr+SZsogY6+yiPtv3pWbhoKO7zcI+cZEel0hjfz3vhUA/g/qTv91p4LybgZz3GeVleSDdNXW7YsryjFWQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217937; c=relaxed/simple; bh=shLDpO8XlHX34iAqVyQqT7FnDz22Px7FA3i34fj+quI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=hv9fBqvNkgueI8hypLG+ivgf6ap5RbAzFmo5fPko4vAHMGn2jR0NZdos/Le37habjkTB+zzcHda1lI2/z/0rGK3drxBOKcMSJGCwABNoYK4kFQSN6/2fe1csXCW+Ymie9c0jfKQcJzVmwz4aQJQdL1fHbfug+mEC5SscLYSJTC0= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id BFA2A169C; Wed, 11 Mar 2026 01:32:09 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 862DD3F73B; Wed, 11 Mar 2026 01:32:08 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:43 +0000 Subject: [PATCH v4 18/30] tools: iio: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-18-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217789; l=689; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=shLDpO8XlHX34iAqVyQqT7FnDz22Px7FA3i34fj+quI=; b=V3uCzrJILmudPN8U5HMeYHHtUo3ijit1FoVg3BWeJDiVxw7bjoduS1pcvqeFUweJC5VrMBjw6 xw+RY0Iql/5AP9DUQD/sKA9VN4KN0CQCPNAyUWF5P1lK9M+U3SGB2JA X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Signed-off-by: Leo Yan Acked-by: Jonathan Cameron --- tools/iio/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/iio/Makefile b/tools/iio/Makefile index 3bcce0b7d10f42208765be83dac047faa2e0ceb1..f0428421792d1cbe5ff71b01b67= f23eb908fa714 100644 --- a/tools/iio/Makefile +++ b/tools/iio/Makefile @@ -13,6 +13,7 @@ endif MAKEFLAGS +=3D -r =20 override CFLAGS +=3D -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include +override CFLAGS +=3D $(EXTRA_CFLAGS) =20 ALL_TARGETS :=3D iio_event_monitor lsiio iio_generic_buffer ALL_PROGRAMS :=3D $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS)) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0D8B0352C35; Wed, 11 Mar 2026 08:32:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217946; cv=none; b=aaSUXKalNrmNIG6fTz5myKy97F3FLEIdj9ZPobc4Sbp6c63TcbYy59Qebn7PbUEts5QrqFVtn4UKAY5LKKSSPQtx0Mn3FSoNupPY6WaBkE5u07rT8eFujkjjR7vqhH+QrEc0VWGcMfkfH2wqwmgRxW0/AFivwqR4NHmdVTz7Wg4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217946; c=relaxed/simple; bh=wVjQowvxpAB2zn18RKm3JYBDwmaeJ2pheT83qKWdB5M=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Srjd4pzwnsFWC8ziG9Si+FORDQCPL/7kDvbjPFgRvTjhuLhLSZhaPHvai1kL0JuiBOOs/TO2EvWG1lcrrlJc6//7DnLUb/KeK7y5LiTh0WOuF7zZIzvBpdoJSpbIPa36FrCDBGdUK9M4gMdtAL8Q2YW8v/NFcV4CztkPyjWSUH8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 72C0C169C; Wed, 11 Mar 2026 01:32:17 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 33AD13F73B; Wed, 11 Mar 2026 01:32:16 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:44 +0000 Subject: [PATCH v4 19/30] tools: mm: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-19-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=615; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=wVjQowvxpAB2zn18RKm3JYBDwmaeJ2pheT83qKWdB5M=; b=CoL39QtxadBZEId/cPj2uRwU1CT72ZzfUiCu/ovYz7oaaT2TmF6WbFTXTntdk7Nm06jgwgcFE n47MGWPSL0jCnfetQ3f5osp4TwGaX44zMswEU0GTANw1U+MGyNH+Qbm X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Signed-off-by: Leo Yan --- tools/mm/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/mm/Makefile b/tools/mm/Makefile index f5725b5c23aa261994b5b42f37c443bee2edebf2..d48491da2edc95fca57c0707c42= 961fde7b02072 100644 --- a/tools/mm/Makefile +++ b/tools/mm/Makefile @@ -10,6 +10,7 @@ LIB_DIR =3D ../lib/api LIBS =3D $(LIB_DIR)/libapi.a =20 CFLAGS +=3D -Wall -Wextra -I../lib/ -pthread +CFLAGS +=3D $(EXTRA_CFLAGS) LDFLAGS +=3D $(LIBS) -pthread =20 all: $(BUILD_TARGETS) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BE0CF3BC661; Wed, 11 Mar 2026 08:32:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217953; cv=none; b=dufIkiSCNsgHSEqSllEw8TS01fiKYm0TzEwXuMiVcDKnwB8kR0SFc0cdejQDABbnWXILO8EvldjWQfhZBBLcuhhvBzc0FPdO5Lz+0pDUoP5ZacHqBPRgwsvX6W8qr6UDkjp5pnuJnKu2L5mAAQKHubHT7TkDNVYFWLOonvVWK2A= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217953; c=relaxed/simple; bh=cFSMsG9Pr0YdGX8EY/I3Z9KhblrIaRqQRvL58Tq489M=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=DwUCTwpc17hIU9xEkDpuo7cGmqd9wkKc541OtU5QWAhYj90CtLwgIQPQ767b7G1zOVwB5azmLrYPO9afQ3UODjG5bCZ2qcS50sKtEx4NVjPGtj2n18KQiKJGnRC629EGr4j2LdE340NeNzLtux5HJgG/0q+BKSlCdhztbIMr56k= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 1F1E1169C; Wed, 11 Mar 2026 01:32:25 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id D7FF43F73B; Wed, 11 Mar 2026 01:32:23 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:45 +0000 Subject: [PATCH v4 20/30] tools: objtool: Append extra host cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-20-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=851; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=cFSMsG9Pr0YdGX8EY/I3Z9KhblrIaRqQRvL58Tq489M=; b=1QV/D3mTckwFZ/TBe6ak7xJvbouFzaunxLGUbs8rJ9yYhCKFOeqBLpj+Z0tPZT1SCXVUoOWfY Q/L9JA3cUSWB+aLZCdZ0yVym8s2+Johz/Eb21iaQ98AzgmEPO0EuL6V X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append HOST_EXTRACFLAGS to HOSTCFLAGS so that additional flags can be applied to the host compiler. Acked-by: Josh Poimboeuf Signed-off-by: Leo Yan --- tools/objtool/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tools/objtool/Makefile b/tools/objtool/Makefile index 76bcd4e85de345048bba0a6e0066c3cf61dac979..716e84cc33eaccb0e4ae592746e= b1888edc2f850 100644 --- a/tools/objtool/Makefile +++ b/tools/objtool/Makefile @@ -60,6 +60,8 @@ INCLUDES :=3D -I$(srctree)/tools/include \ -I$(srctree)/tools/objtool/arch/$(SRCARCH)/include \ -I$(LIBSUBCMD_OUTPUT)/include =20 +HOSTCFLAGS +=3D $(HOST_EXTRACFLAGS) + OBJTOOL_CFLAGS :=3D -std=3Dgnu11 -fomit-frame-pointer -O2 -g $(WARNINGS) \ $(INCLUDES) $(LIBELF_FLAGS) $(LIBXXHASH_CFLAGS) $(HOSTCFLAGS) =20 --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8217E352C35; Wed, 11 Mar 2026 08:32:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217960; cv=none; b=MnLBsbWCSpb8ucbibIOiemUijjvEc8lLVyBqoJTjrHFhI6EtWyb6sKe+3gzzyfrlVYiMuHG9TQ9UzXIUydDzcpgTWpdAeIOAcnhVz8qbPX4r9e4kdFGCzUA1fHSmr2UPmj/dTQt9irXjjrMWQ/L+7HH/IVoVhQ0Df5ORtU6jgWQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217960; c=relaxed/simple; bh=+JjISCoCiswO66KwqDpEEqU/V/TxnMe7dGCpZMrmE4A=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Y2jBCiRa9loWXbPd1dLTO/7iIR/z0qwjptSwqqpJPhBvW6iMjKnbF5WaLRAVYgb+BGoSrhrKP6fsTd9bDj/ZnG4Va7vmuWmH85BXpyzMIJU+DSe/zdxnKh2pcT4jWy+RsQmQEr1ximwQq7jrZu1hRqfhlxgJRvFi4qfzCNslQbA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id C13FD169C; Wed, 11 Mar 2026 01:32:32 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 8784C3F73B; Wed, 11 Mar 2026 01:32:31 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:46 +0000 Subject: [PATCH v4 21/30] tools: power: acpi: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-21-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=763; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=+JjISCoCiswO66KwqDpEEqU/V/TxnMe7dGCpZMrmE4A=; b=9sePHNdwL3j0JzBNERqLPKqpe6pxUWOXmMWCCwJKzDcb9J/8bqxCsH70stQbcHd3ZfcvYRIP/ K0yaO3IcmK6D/5f1V7qJg1SmQFP0UcPX8kSLQSmNOhecXKgnLUFwmrL X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Signed-off-by: Leo Yan --- tools/power/acpi/Makefile.config | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/power/acpi/Makefile.config b/tools/power/acpi/Makefile.c= onfig index cd7106876a5f39dfda38e286c54c3a7c268b34a2..11088deab42ee5a793f978feb9f= 4f7bb7024c48c 100644 --- a/tools/power/acpi/Makefile.config +++ b/tools/power/acpi/Makefile.config @@ -69,6 +69,7 @@ KERNEL_INCLUDE :=3D $(OUTPUT)include ACPICA_INCLUDE :=3D $(srctree)/../../../drivers/acpi/acpica CFLAGS +=3D -D_LINUX -I$(KERNEL_INCLUDE) -I$(ACPICA_INCLUDE) CFLAGS +=3D $(WARNINGS) +CFLAGS +=3D $(EXTRA_CFLAGS) MKDIR =3D mkdir =20 ifeq ($(strip $(V)),false) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2E98A3C5548; Wed, 11 Mar 2026 08:32:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217969; cv=none; b=JRq/ZaEltprGZyy3jaxrSN708BSX8yQitlw677Kp2+z04mk0LMZQ4BLV9hRJotItp8d+QvcjQvTuFbuxx2voGZEDnlrfkTpy+dNxXVUG6fnKr9UDOJgqXBH32KPdrzSVAToDeIail7lt+WKRLUVfQ5YzTSH7SpDmIsDwl9x7U6c= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217969; c=relaxed/simple; bh=Rgzo//pe6jtJkqHszW5b83Q1eWN+jdj6CyAqKjTaoAM=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=BIUCetLHFFC33wFBABbVtC3XrvxRQBLAJoRLK/4/G5jz8mun25EtS+NSbS2JWDYe3Old237Xp15KpE/axACXrG4jJm8WlgQ3Dk6iw4pT98CJg1ppC4kgNHjMSpZh7rw3u4AL25SumSX8KVDSrXwenpki1zUpbNArX9Nh7WwYKLc= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 74DDD169C; Wed, 11 Mar 2026 01:32:40 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 353203F73B; Wed, 11 Mar 2026 01:32:39 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:47 +0000 Subject: [PATCH v4 22/30] tools: power: x86/intel-speed-select: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-22-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=875; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=Rgzo//pe6jtJkqHszW5b83Q1eWN+jdj6CyAqKjTaoAM=; b=FZNXiQvfnTrv2QgmvSBsoqXqJuK1ZpcLzn+ALLJSjwkeY0FSXC0qBjw32zEL/Nyg/tujjo4BU oXJVfvQfI6NClMWtLpLfh83B1LDcgkEXw/f6Y5SJAevrPViCU8CGoon X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Acked-by: Srinivas Pandruvada Signed-off-by: Leo Yan --- tools/power/x86/intel-speed-select/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/power/x86/intel-speed-select/Makefile b/tools/power/x86/= intel-speed-select/Makefile index 6b299aae2ded89c3a70a3649996e258b98001ee7..5947afce9fde7c054647fa3ee0c= 661b60b863f29 100644 --- a/tools/power/x86/intel-speed-select/Makefile +++ b/tools/power/x86/intel-speed-select/Makefile @@ -20,6 +20,7 @@ NL3_CFLAGS =3D -I/usr/include/libnl3 endif =20 override CFLAGS +=3D -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include $(NL3_C= FLAGS) +override CFLAGS +=3D $(EXTRA_CFLAGS) override LDFLAGS +=3D -lnl-genl-3 -lnl-3 =20 ALL_TARGETS :=3D intel-speed-select --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D53BF3BD22A; Wed, 11 Mar 2026 08:32:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217980; cv=none; b=IVP4YrfQssI5sy8TmxL4R5eMa1rp2Wfzwr06xVloMsfpTj8OSp0PWzIqzbApuGlOzKiHY6Alm9A46nCk/LSkcNvc/RKrvD4AwOgGskFGGjUsA/69Tjlwug6oFFEMY9q6A09cqHcknKFamQH886emfNeKCL8fPqhiJuX5DdYhx8I= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217980; c=relaxed/simple; bh=SeDVOquLmPwaUVXLNSt91lMfLrGLKxvtIpmiK9hIWkI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Ye1+q41cyQzM6dEoCIuD9b4CEIzavAtP3+y18DmU8h75t9LifWyzJpT6QJ2lplhsdFDn65kJR9BeX03uctAZeaQ9f6JSyDdsdf63N49nKQE4kFsFU+zfGKXHLJe90S+N+0EbIqWHzSx9J0Ca0iDgLi82nXQeBhKMcoiYHppzN6k= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 1D8D8204C; Wed, 11 Mar 2026 01:32:48 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id D89CA3F73B; Wed, 11 Mar 2026 01:32:46 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:48 +0000 Subject: [PATCH v4 23/30] tools: sched_ext: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-23-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=747; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=SeDVOquLmPwaUVXLNSt91lMfLrGLKxvtIpmiK9hIWkI=; b=9jYmnfHGn/jjuesZBzfIMdolz5U5pjClERId/KEn0LbZtdiCELudBIqBHbKN+P7xJPq/4Zuzl yrKnWKMOotLAEwJIUlieFQPQfvnhy8xviWxByVrCG1SZ3x9DPM/Z9sf X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Signed-off-by: Leo Yan --- tools/sched_ext/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/sched_ext/Makefile b/tools/sched_ext/Makefile index 21554f0896923fa9c2e5b98c85d65d964152e592..e0d705b2fe0ca763fece5137ea4= 3ccb776d18012 100644 --- a/tools/sched_ext/Makefile +++ b/tools/sched_ext/Makefile @@ -92,6 +92,7 @@ endif CFLAGS +=3D -g -O2 -rdynamic -pthread -Wall -Werror $(GENFLAGS) \ -I$(INCLUDE_DIR) -I$(GENDIR) -I$(LIBDIR) \ -I$(TOOLSINCDIR) -I$(APIDIR) -I$(CURDIR)/include +CFLAGS +=3D $(EXTRA_CFLAGS) =20 # Silence some warnings when compiled with clang ifneq ($(LLVM),) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EE15D3C661B; Wed, 11 Mar 2026 08:33:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217986; cv=none; b=JlsM2mxNpU5rugx/eYBzNT1xDRo/wfN17IiyDN4VjU5nlTmIkobJkpzEFa3i1VRGFOc9SYaocrdO7GxJjrM2JuuGfaw1Iket1xmjRdozrkNuerbN34UfYR9j8jkIS/YfOeTFcNqU1DcS9q+p0SUzxYGjoHcewIHdT/621vP7RSU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217986; c=relaxed/simple; bh=Y3fYUfec7IdYKkZMHnIhchrzP1QeLhY68m77wtq8xP4=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=Iey69Q74f/KMitlcKyF2PHksayYOTz4L1bLYAself5B2cGHIhYWPgXTA3V1x2QeIkKPUxt/OSTz/MM4y7hTH3xcLB8VfDpuHT2RBfPdhE2OMI64L2KPYgP+pwJJ9O6FcF9ya1rdTGAqUYRtR05ODbMFs079JMrqBmQu5oiFDCAo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id C76492050; Wed, 11 Mar 2026 01:32:55 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 852FA3F73B; Wed, 11 Mar 2026 01:32:54 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:49 +0000 Subject: [PATCH v4 24/30] tools: spi: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-24-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=694; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=Y3fYUfec7IdYKkZMHnIhchrzP1QeLhY68m77wtq8xP4=; b=v2LHxDlfkujrwW6R53n95L4I80Mu/5kcXO/OJ7OO2rKlateT57eYkl9K5HH26tNq4mwLdJApC wFbCO6wenR/BGgPahEqIFnu23BlmyAF1pyoTJRqP5vuDXcsGp3zc1Ex X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Acked-by: Mark Brown Signed-off-by: Leo Yan --- tools/spi/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/spi/Makefile b/tools/spi/Makefile index 7fccd245a53515ab019529c8e5e91a044eaaa68b..82f9bc6365911b962422633147b= 108fabc70a2db 100644 --- a/tools/spi/Makefile +++ b/tools/spi/Makefile @@ -13,6 +13,7 @@ endif MAKEFLAGS +=3D -r =20 CFLAGS +=3D -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include +CFLAGS +=3D $(EXTRA_CFLAGS) =20 ALL_TARGETS :=3D spidev_test spidev_fdx ALL_PROGRAMS :=3D $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS)) --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 81EB43B777F; Wed, 11 Mar 2026 08:33:10 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217995; cv=none; b=aSL/HDG2Vdx4+Zm2bvhVW3N3z9QKgCJ1/1O5QTb9Vti0UFvKFgvV9RKiUroBfUS8KH8br6og51RjRlzzD+PgFVEqQb5Q5BrFWW0LWGQo/bZtoZhSLBwVXSG6T39I6p4wqxrci6UqN/KymMz+LDaGunDXnZ3he/x3bEUM+NxDGZE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773217995; c=relaxed/simple; bh=kBrxjsAsoUP4ghwPhyQYeg8vEMKcbDL/VfSOIh63ImI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=EpcSrKltv4D4j5ox4tiGszeUFoz1pFJuRPAPBGwsLfaxVG7L9TBTI5GkUjTrFlzd8NiDKShN/nplLrpjPnqG+XG6jN8xpuC96aguSWZXyLbB9xXBtqX73UAxOHqE0vIPpeO69BgA+2DRHWU2hjDtSsvGtPMkpzbKMuY89mOCIfY= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 7C44B2050; Wed, 11 Mar 2026 01:33:03 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 37F133F73B; Wed, 11 Mar 2026 01:33:02 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:50 +0000 Subject: [PATCH v4 25/30] tools: tracing: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-25-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=691; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=kBrxjsAsoUP4ghwPhyQYeg8vEMKcbDL/VfSOIh63ImI=; b=8mK9do+pE4tb3lIKYsADmg1OnlnwfaXtrB25ka/e7RmVDgErTb37shcppVemLwH2CNvXEc6is EQC7jdSMzhGDoPD19FPxjR7UAwx/EEvR3vXKdEbUMGz5Ip2GhPdFIn0 X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Acked-by: Steven Rostedt (Google) Signed-off-by: Leo Yan --- tools/tracing/latency/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/tracing/latency/Makefile b/tools/tracing/latency/Makefile index 257a56b1899f23837de533353e9c2cebdb6035bd..d32a6a13753035355f0e3a05bf8= 8870b8aa55f64 100644 --- a/tools/tracing/latency/Makefile +++ b/tools/tracing/latency/Makefile @@ -57,6 +57,7 @@ ifeq ($(config),1) endif =20 CFLAGS +=3D $(INCLUDES) $(LIB_INCLUDES) +CFLAGS +=3D $(EXTRA_CFLAGS) =20 export CFLAGS OUTPUT srctree =20 --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1F97B3BE638; Wed, 11 Mar 2026 08:33:17 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218001; cv=none; b=eEIkfghzZwp9vt5z1NuSbqrA5FeTFis9jkcbUHUy84DPirj0ikcykysz0XQc6ABMUvveOCjKkO3k3ppYYh+bfUFdgiq2N2Q15BHOrveAv6IzWCgFxE2EWhmcC03ihkjlrqTAIE1dPgoJFcQcg6b0jvbFIFsdtLw08EVi2wo4bL4= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218001; c=relaxed/simple; bh=mYlThUq1iAN/tIV3PsjLtm1fJPfV0aj3FB6Qm/569bA=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=eLSo0xhYzswIIoErqUm4LyqGEA7JM4nuUQwbUaM05zVaogYa3d4QYqOsxpEUgaA/Dl389lsjGcnGNO4g47zRsNDRbFq4L+sjI8FxZA8oF38MfnK43+574FN2CLUe8Q1RSu7OBl2070bE79LgMnAHGd7CyiAosa3ee2TpBNU2g94= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 268A9169C; Wed, 11 Mar 2026 01:33:11 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id E025F3F73B; Wed, 11 Mar 2026 01:33:09 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:51 +0000 Subject: [PATCH v4 26/30] tools: usb: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-26-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=672; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=mYlThUq1iAN/tIV3PsjLtm1fJPfV0aj3FB6Qm/569bA=; b=ZqKUOAXoaR1p3Dqf+sbX6WDJNgQ9oDQ/ElQvCASx/S4q5NII7q5SldKt7AqQqwo4JCSIMvfez 20KpGxL0Xu6A11bwh404cBFYkOnil9sXgcuwKNrmgE4K3urmFsluqfq X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Signed-off-by: Leo Yan --- tools/usb/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/usb/Makefile b/tools/usb/Makefile index c6235667dd46223b646bbab5c82c810221750182..42362dcdf2743dace62a5385a7d= 2707c42bdd3c0 100644 --- a/tools/usb/Makefile +++ b/tools/usb/Makefile @@ -14,6 +14,7 @@ endif MAKEFLAGS +=3D -r =20 override CFLAGS +=3D -O2 -Wall -Wextra -g -D_GNU_SOURCE -I$(OUTPUT)include= -I$(srctree)/tools/include +override CFLAGS +=3D $(EXTRA_CFLAGS) override LDFLAGS +=3D -lpthread =20 ALL_TARGETS :=3D testusb ffs-test --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 69D8F3BB9EA; Wed, 11 Mar 2026 08:33:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218007; cv=none; b=LaCpGcPcpZNnxlKRKWz2yukLF/y4NwwVi3TTU3Ad75I1XYDg+HfHF7EjuMoaVnebX475WJOifKDMuqUnKTligZzNR0OG8mc3NAGW7XVE3/roH23ZzkcE1PBV8L8orIfoP/IES8uXMESyUzOqUIgXge4SWrNb1j/C5Eu5NKL14PI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218007; c=relaxed/simple; bh=pX9AkyBK5nD04U0aTxThC7K8j3uVTzojPCrIo1E31LI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=LBLftTC3C3nzupTy1ikTLJh3MUOfNomsk1/wVWuHFKeleoAQz+AvpWP7CqxN7JyRuaK4YPk5wlO8PqQo2ldzPab+z+ByYvo+5scveVxZTpsmy7xIUFCIpvaDU8JJrBEMA/XXKomWAp09IyBv7pxFKpiveqau0gotEpY+5+gENJo= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id CB9A6169C; Wed, 11 Mar 2026 01:33:18 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 8DFD53F73B; Wed, 11 Mar 2026 01:33:17 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:52 +0000 Subject: [PATCH v4 27/30] selftests/bpf: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-27-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=2248; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=pX9AkyBK5nD04U0aTxThC7K8j3uVTzojPCrIo1E31LI=; b=nBZJq62MofrfzEhaw8naMT+w2SCGyzSrRPVhkd0Rf+zZ5ijGsYHgizsaQs+HHmYcACLZ0eIdV xX5e/j35eppAO6rHwOBPiV3iGzFynmAYQFST2C/qCIc5VkS6Sl64KlX X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. urandom_read is built with clang. Introduce URANDOM_READ_CFLAGS to copy the compiler flags without appending EXTRA_CFLAGS, which may contain incompatible options with clang. Signed-off-by: Leo Yan --- tools/testing/selftests/bpf/Makefile | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tools/testing/selftests/bpf/Makefile b/tools/testing/selftests= /bpf/Makefile index 72a9ba41f95ebb825d25799c07ba3f0311243e45..27112f08c9a5b6cabc41902207d= 00897070b41b4 100644 --- a/tools/testing/selftests/bpf/Makefile +++ b/tools/testing/selftests/bpf/Makefile @@ -71,6 +71,12 @@ ifneq ($(LLVM),) CFLAGS +=3D -Wno-unused-command-line-argument endif =20 +# urandom_read is built with clang. Copy $(CFLAGS) before EXTRA_CFLAGS are +# appended so that it does not inherit potentially incompatible options. +URANDOM_READ_CFLAGS :=3D $(CFLAGS) + +CFLAGS +=3D $(EXTRA_CFLAGS) + # Check whether bpf cpu=3Dv4 is supported or not by clang ifneq ($(shell $(CLANG) --target=3Dbpf -mcpu=3Dhelp 2>&1 | grep 'v4'),) CLANG_CPUV4 :=3D 1 @@ -255,7 +261,7 @@ endif $(OUTPUT)/liburandom_read.so: urandom_read_lib1.c urandom_read_lib2.c libu= random_read.map $(call msg,LIB,,$@) $(Q)$(CLANG) $(CLANG_TARGET_ARCH) \ - $(filter-out -static,$(CFLAGS) $(LDFLAGS)) \ + $(filter-out -static,$(URANDOM_READ_CFLAGS) $(LDFLAGS)) \ $(filter %.c,$^) $(filter-out -static,$(LDLIBS)) \ -Wno-unused-command-line-argument \ -fuse-ld=3D$(LLD) -Wl,-znoseparate-code -Wl,--build-id=3Dsha1 \ @@ -265,7 +271,7 @@ $(OUTPUT)/liburandom_read.so: urandom_read_lib1.c urand= om_read_lib2.c liburandom $(OUTPUT)/urandom_read: urandom_read.c urandom_read_aux.c $(OUTPUT)/libura= ndom_read.so $(call msg,BINARY,,$@) $(Q)$(CLANG) $(CLANG_TARGET_ARCH) \ - $(filter-out -static,$(CFLAGS) $(LDFLAGS)) $(filter %.c,$^) \ + $(filter-out -static,$(URANDOM_READ_CFLAGS) $(LDFLAGS)) $(filter %.= c,$^) \ -Wno-unused-command-line-argument \ -lurandom_read $(filter-out -static,$(LDLIBS)) -L$(OUTPUT) \ -fuse-ld=3D$(LLD) -Wl,-znoseparate-code -Wl,--build-id=3Dsha1 \ --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5549A35BDD7; Wed, 11 Mar 2026 08:33:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218014; cv=none; b=oYXKjQNzpGNZJAptmVCSw96M1GmiALQZsUEQ4JH2f3ojgMXNeaT27khAJZJbFxKE4x8+KXkHDis9o5dzGfBNawxoB59u8SxnuhkFU8kYcdPkdkcBsOAR8U4GTz3QFs53uIAy7b1zxs/VXyosyYmvzxE/l3xMREr/czYKz9YDwU0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218014; c=relaxed/simple; bh=ErtGxs44UF+bC9w6Ob4j1GRQ3qVJEBQDvrbhvtEVczs=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=oTQOBTetI8IlFPLoAG49LuEjpFNqwVujILVIEG+okjZbLUTxqb4lYU/8ZAYTm+PPGuRHhZwQzK3i9zbAYQebVjH/o78HDX0Z87L+0CFDtMx05ox1MfBukMbgRL4fS5vSTE1I7weJDbWBkaHYgEwozDUwUFBZMp5XSPRgvvClwFk= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 7A45C165C; Wed, 11 Mar 2026 01:33:26 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 3F36C3F73B; Wed, 11 Mar 2026 01:33:25 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:53 +0000 Subject: [PATCH v4 28/30] selftests/hid: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-28-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=723; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=ErtGxs44UF+bC9w6Ob4j1GRQ3qVJEBQDvrbhvtEVczs=; b=aOrWFxw+C7av3b2ZdGj6lElieqIPKTXsh+ti9CcfnDhDy8L2m7l44YeiRt7Pje8TN6B77OtyM o+SB+XlC4iJDVZFfXgpI/j4ryLyxBGonh/w+VwVYw4Ypw5Q5m839eFU X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Signed-off-by: Leo Yan Acked-by: Benjamin Tissoires --- tools/testing/selftests/hid/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/testing/selftests/hid/Makefile b/tools/testing/selftests= /hid/Makefile index 50ec9e0406abaf316fba232c5da1967e27d0fa9b..686c5f79ca592c2ce94e37b39ab= 5c3ebe8483f79 100644 --- a/tools/testing/selftests/hid/Makefile +++ b/tools/testing/selftests/hid/Makefile @@ -26,6 +26,7 @@ HOSTPKG_CONFIG :=3D pkg-config =20 CFLAGS +=3D -g -O0 -rdynamic -Wall -Werror -I$(OUTPUT) CFLAGS +=3D -I$(OUTPUT)/tools/include +CFLAGS +=3D $(EXTRA_CFLAGS) =20 LDLIBS +=3D -lelf -lz -lrt -lpthread =20 --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E52073B8D48; Wed, 11 Mar 2026 08:33:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218022; cv=none; b=qh8V4BjcDU90vqre5Cj7W/SluikWrx/LZM+JoIsMNmrDZ9YurQBNvkoMYYp70kDrBVSiIq+b1zWbNU604oBZGXui2xVmD3TFLp8Po6crILJ1X4SJOZZiqDdXtlmrRk9y4BpoqbHaIIlhEeyZSH+5otI1LZa43TpAdevFbOTXcLU= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218022; c=relaxed/simple; bh=2XlQBLl0CVMHfqFKSSQ3A2CBHttJLR+mly0kKHJ0Q0c=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=GQ5jLXzSD72ofXCDC3EFRg/riFly3UA1C2Ta/4NxcifEVgZynD/QlGCQmV0z8/OJ1Nz1Xw64A7mZocA80K62WdawlOMKOZyUADFYQnAuB+/hXuY4egPpRW8VoRsu/T4l54DS+FFgMs7P7186QxVBDHmi3HRtkYNAM/ymT8xwRPU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 2AC23165C; Wed, 11 Mar 2026 01:33:34 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id E27883F73B; Wed, 11 Mar 2026 01:33:32 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:54 +0000 Subject: [PATCH v4 29/30] selftests/nolibc: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-29-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=1294; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=2XlQBLl0CVMHfqFKSSQ3A2CBHttJLR+mly0kKHJ0Q0c=; b=9K5IaDR06OWipAxv9O5CmhRxerF+b/yQ2h/f9KSiQ30L24r/6dcPtf13j3tourAlS+x4kFLAc siec0PyeimzAnGit6Sg4hFNZFjsAO9TiO72Mt3EKO7iHlckhZSR508w X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Include tools/scripts/Makefile.include, which may provide additional flags in EXTRA_CFLAGS, and append to CFLAGS. Since Makefile.include already defines cc-option, remove the redundant definition and include. Signed-off-by: Leo Yan --- tools/testing/selftests/nolibc/Makefile | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tools/testing/selftests/nolibc/Makefile b/tools/testing/selfte= sts/nolibc/Makefile index 0370489d938b540721a4fb814ebb68c463760e73..d1a9c1d5988bdc6a8778ef418aa= a4c5ac1d26a10 100644 --- a/tools/testing/selftests/nolibc/Makefile +++ b/tools/testing/selftests/nolibc/Makefile @@ -3,15 +3,13 @@ TEST_GEN_PROGS :=3D nolibc-test libc-test =20 include ../lib.mk -include $(top_srcdir)/scripts/Makefile.compiler - -cc-option =3D $(call __cc-option, $(CC),,$(1),$(2)) +include $(top_srcdir)/tools/scripts/Makefile.include =20 include Makefile.include =20 $(OUTPUT)/nolibc-test: CFLAGS =3D -nostdlib -nostdinc -static \ -isystem $(top_srcdir)/tools/include/nolibc -isystem $(top_srcdir)/usr/i= nclude \ - $(CFLAGS_NOLIBC_TEST) + $(CFLAGS_NOLIBC_TEST) $(EXTRA_CFLAGS) $(OUTPUT)/nolibc-test: LDLIBS =3D $(if $(LLVM),,-lgcc) $(OUTPUT)/nolibc-test: nolibc-test.c nolibc-test-linkage.c | headers =20 --=20 2.34.1 From nobody Thu Apr 9 03:30:02 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id D2E603B9D94; Wed, 11 Mar 2026 08:33:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218030; cv=none; b=L0Pvz+hMrvVtmkNGK6TiYJyPBcMhUIgrFZ9XMpagnu6odxdZgVFs6nYtV67256rAsNhgBt3UJkDg9YWel94OSteGwz5gDieJF5hWAswM85vW147agt/2abLcxhb0eT4Nr1W3E0ogf0lA8YMNyu30C6VpcyxIPm45ZPXMCJGokVY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773218030; c=relaxed/simple; bh=u6vnl/Tc6siw5/z3VuI7EgUIJilNCagL/0epWPyB+xk=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=BVv6pOgWdu95cpnKANRJRxOjWNuBuWyTnafKUEg+3PCNiIMZ40e4g815ZdxtSPTL+5XC5RTaIGZuzLjHYzcuNWY4DVD+CPlzFgcoOZFNH7j6JqctBYi+OF9du6hUgn/OKE35OVfZ8T5+OBY2LTmUP3SsYOu3o/DWTVq1co8LAHw= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id CFF7B204C; Wed, 11 Mar 2026 01:33:41 -0700 (PDT) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 9349E3F73B; Wed, 11 Mar 2026 01:33:40 -0700 (PDT) From: Leo Yan Date: Wed, 11 Mar 2026 08:29:55 +0000 Subject: [PATCH v4 30/30] selftests/sched_ext: Append extra cflags Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20260311-tools_build_fix_zero_init-v4-30-9e35bdb99cb3@arm.com> References: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> In-Reply-To: <20260311-tools_build_fix_zero_init-v4-0-9e35bdb99cb3@arm.com> To: Arnaldo Carvalho de Melo , Ian Rogers , Namhyung Kim , James Clark , Kees Cook , Quentin Monnet , Nathan Chancellor , Nicolas Schier , Nick Desaulniers , Bill Wendling , Justin Stitt , Alexei Starovoitov , Daniel Borkmann , Andrii Nakryiko , Martin KaFai Lau , Eduard Zingerman , Song Liu , Yonghong Song , John Fastabend , KP Singh , Stanislav Fomichev , Hao Luo , Jiri Olsa , "Rafael J. Wysocki" , Daniel Lezcano , Zhang Rui , Lukasz Luba , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Adrian Hunter , Masami Hiramatsu , William Breathitt Gray , Barry Song , Qinxin Xia , Bartosz Golaszewski , Kent Gibson , "K. Y. Srinivasan" , Haiyang Zhang , Wei Liu , Dexuan Cui , Long Li , Jonathan Cameron , David Lechner , =?utf-8?q?Nuno_S=C3=A1?= , Andy Shevchenko , Andrew Morton , Willy Tarreau , =?utf-8?q?Thomas_Wei=C3=9Fschuh?= , Josh Poimboeuf , Robert Moore , Len Brown , Srinivas Pandruvada , Tejun Heo , David Vernet , Andrea Righi , Changwoo Min , Mark Brown , Steven Rostedt , Gabriele Monaco , Shuah Khan , Jiri Kosina , Benjamin Tissoires Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, llvm@lists.linux.dev, bpf@vger.kernel.org, linux-perf-users@vger.kernel.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1773217790; l=901; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=u6vnl/Tc6siw5/z3VuI7EgUIJilNCagL/0epWPyB+xk=; b=6cWMHhJCPDeg81JeCsWfeQ9vTp+3FcbmTEUMARN/G5S+2HqlMWCLipjOx1DSbFSw0abCd017n JM/ohPESBQRBfF0O2VWjkk7U8+dHdC5yqin76gy0BurR+hvnaBfPPbD X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Append EXTRA_CFLAGS to CFLAGS so that additional flags can be applied to the compiler. Acked-by: Andrea Righi Signed-off-by: Leo Yan --- tools/testing/selftests/sched_ext/Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/testing/selftests/sched_ext/Makefile b/tools/testing/sel= ftests/sched_ext/Makefile index 006300ac6dff88a48104977398d8517753e7e385..2c8fbc9f8666ec4d6f75dbdd760= 2bd4f2b502aed 100644 --- a/tools/testing/selftests/sched_ext/Makefile +++ b/tools/testing/selftests/sched_ext/Makefile @@ -56,6 +56,7 @@ endif CFLAGS +=3D -g -O2 -rdynamic -pthread -Wall -Werror $(GENFLAGS) \ -I$(INCLUDE_DIR) -I$(GENDIR) -I$(LIBDIR) \ -I$(TOOLSINCDIR) -I$(APIDIR) -I$(CURDIR)/include -I$(SCXTOOLSINCDIR) +CFLAGS +=3D $(EXTRA_CFLAGS) =20 # Silence some warnings when compiled with clang ifneq ($(LLVM),) --=20 2.34.1