From nobody Mon Feb 9 05:13:41 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9AAF73164C1; Fri, 23 Jan 2026 13:32:15 +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=1769175137; cv=none; b=B8IsY1Wl/Yv/q2kdGJ746vxC/mw8f2ACtUMfVkl2t6gSpnb21sIv7qzmdhRwgO+yWVek+MKD7KJKXestZeGK85mwWH2TJYrq4zQkewx7ZmJmLekSf7OkfAXKr6lyOoGrQzpVQt6Hu931ymDCcCjjp9TdQVsGk+izokkJfYceHWY= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769175137; c=relaxed/simple; bh=pZJHIS1TzJr9+FiQn4WT97OcG2JDBEl64HyYP/h5m5g=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=IOZtWWmfoeBw5/oouYRFtMF9ff8JbaTBnzIudi4UGH0uwzYJ87aqtO+XFhzcxUai4mF3I4rGQgioiZQJ/Lp6mkl+Sxu9Xziy9/G3j3mBi8HcwrjVyrun1xwsjuPhQeAtcmrGEVxsgo+We1+pvlGpGJAE5hZVz9sf40kmiVX157Q= 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 6F37A1515; Fri, 23 Jan 2026 05:32:08 -0800 (PST) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 21D643F632; Fri, 23 Jan 2026 05:32:12 -0800 (PST) From: Leo Yan Date: Fri, 23 Jan 2026 13:32:03 +0000 Subject: [PATCH v2 1/2] tools: Fix bitfield dependency failure 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: <20260123-perf_fix_bitfield-h-v2-1-cc8f8752607c@arm.com> References: <20260123-perf_fix_bitfield-h-v2-0-cc8f8752607c@arm.com> In-Reply-To: <20260123-perf_fix_bitfield-h-v2-0-cc8f8752607c@arm.com> To: Arnaldo Carvalho de Melo , Namhyung Kim , Ian Rogers , James Clark Cc: linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, coresight@lists.linaro.org, Leo Yan , Thomas Voegtle , Greg KH , Sasha Levin , stable@vger.kernel.org X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1769175130; l=2314; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=pZJHIS1TzJr9+FiQn4WT97OcG2JDBEl64HyYP/h5m5g=; b=BRAsB+ERbc3tr8DEU+XnlKutDrpwcmG2h2RV0UnbmO6XEyXeN7KX/OGZ6lWKYPAJ3vRw8CNlw LjFVEQp6zooCQl79DMubrcVieXTNJk9RYukv4nuzAUQ1Co/I5Aripwg X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= A perf build failure was reported by Thomas Voegtle on stable kernel v6.6.120: CC tests/sample-parsing.o CC util/intel-pt-decoder/intel-pt-pkt-decoder.o CC util/perf-regs-arch/perf_regs_csky.o CC util/arm-spe-decoder/arm-spe-pkt-decoder.o CC util/perf-regs-arch/perf_regs_loongarch.o In file included from util/arm-spe-decoder/arm-spe-pkt-decoder.h:10, from util/arm-spe-decoder/arm-spe-pkt-decoder.c:14: /local/git/linux-stable-rc/tools/include/linux/bitfield.h: In function = =E2=80=98le16_encode_bits=E2=80=99: /local/git/linux-stable-rc/tools/include/linux/bitfield.h:166:31: error: = implicit declaration of function =E2=80=98cpu_to_le16=E2=80=99; did you mean =E2=80=98htole16=E2= =80=99? [-Werror=3Dimplicit-function-declaration] ____MAKE_OP(le##size,u##size,cpu_to_le##size,le##size##_to_cpu) \ ^~~~~~~~~ /local/git/linux-stable-rc/tools/include/linux/bitfield.h:149:9: note: in= definition of macro =E2=80=98____MAKE_OP=E2=80=99 return to((v & field_mask(field)) * field_multiplier(field)); \ ^~ /local/git/linux-stable-rc/tools/include/linux/bitfield.h:170:1: note: in= expansion of macro =E2=80=98__MAKE_OP=E2=80=99 __MAKE_OP(16) Fix this by including linux/kernel.h, which provides the required definitions. The issue was not found on the mainline due to the relevant C files have included kernel.h. It'd be good to merge this change on mainline as well for robustness. Fixes: 64d86c03e144 ("perf arm-spe: Extend branch operations") Reported-by: Thomas Voegtle Closes: https://lore.kernel.org/stable/3a44500b-d7c8-179f-61f6-e51cb50d3512= @lio96.de/ To: Greg KH To: Sasha Levin Cc: stable@vger.kernel.org Signed-off-by: Leo Yan --- tools/include/linux/bitfield.h | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/include/linux/bitfield.h b/tools/include/linux/bitfield.h index 6093fa6db2600b3246007b2236d7c0076b02343b..ddf81f24956ba069b2c1a7b096a= 6c9bf92fc9182 100644 --- a/tools/include/linux/bitfield.h +++ b/tools/include/linux/bitfield.h @@ -8,6 +8,7 @@ #define _LINUX_BITFIELD_H =20 #include +#include #include =20 /* --=20 2.34.1 From nobody Mon Feb 9 05:13:41 2026 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3559C32470E; Fri, 23 Jan 2026 13: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=1769175138; cv=none; b=sDikZ9Wzs/9ks5UIiaLZRbZEHiIxy5lQW87qjYsDAItYfmiUj2y4BxZ+QeTBvRVeTimRhvAKFv5wkhv3ZCTnpR3YJ9BNHIi5/18u24TkPmEzsVHMn+6mTOlIBte+5Py38Etm+8jLLqPqJOTyt4CSQ+zPVNHa2m4TOTUDgM3xuMw= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1769175138; c=relaxed/simple; bh=ZxHX4YkPlbx4BRnksFGZAsZa9BN1G5reRF7wQzkIwgQ=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=HFLyOV1fsyTJ6/qQrTVfkyI6xB71TeI4UBTVxTDdgeLMBYLQFJ6rTxckIdUbrq+0EXrCzgNie3jk03HAlPsxwDQ40PEihLj+1muKduiZG2VAzmGIQppPbiO9QmvZNDy1hSS8x/6zyaYJCgko5gUE2Tis8WfXUwWEdMmKPW/8rKY= 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 14DDC1476; Fri, 23 Jan 2026 05:32:10 -0800 (PST) Received: from e132581.arm.com (e132581.arm.com [10.1.196.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 54E483F632; Fri, 23 Jan 2026 05:32:15 -0800 (PST) From: Leo Yan Date: Fri, 23 Jan 2026 13:32:04 +0000 Subject: [PATCH v2 2/2] perf: Remove redundant kernel.h 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: <20260123-perf_fix_bitfield-h-v2-2-cc8f8752607c@arm.com> References: <20260123-perf_fix_bitfield-h-v2-0-cc8f8752607c@arm.com> In-Reply-To: <20260123-perf_fix_bitfield-h-v2-0-cc8f8752607c@arm.com> To: Arnaldo Carvalho de Melo , Namhyung Kim , Ian Rogers , James Clark Cc: linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, coresight@lists.linaro.org, Leo Yan X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1769175130; l=1148; i=leo.yan@arm.com; s=20250604; h=from:subject:message-id; bh=ZxHX4YkPlbx4BRnksFGZAsZa9BN1G5reRF7wQzkIwgQ=; b=l0WzgVj0aO+ezMUxHOueM9x7z9S/26BHYyBSNU6MuGZ4aPJALLx6cf8KSom+sTH3lZb6ctzPz lyROXNagZShAq9zjchDAen74Jj2fGpbt5FEWMS5BPbSnL+kKAcR0Rbe X-Developer-Key: i=leo.yan@arm.com; a=ed25519; pk=k4BaDbvkCXzBFA7Nw184KHGP5thju8lKqJYIrOWxDhI= Now that the bitfield dependency is resolved, the explicit inclusion of kernel.h is no longer needed. Remove the redundant include. Signed-off-by: Leo Yan --- tools/perf/arch/arm64/util/header.c | 1 - tools/perf/util/cs-etm.c | 1 - 2 files changed, 2 deletions(-) diff --git a/tools/perf/arch/arm64/util/header.c b/tools/perf/arch/arm64/ut= il/header.c index f445a2dd6293442645404d7c42c3f7a2992bd9c9..cbc0ba101636bf275101385c662= f5f3881c8f7c4 100644 --- a/tools/perf/arch/arm64/util/header.c +++ b/tools/perf/arch/arm64/util/header.c @@ -1,4 +1,3 @@ -#include #include #include #include diff --git a/tools/perf/util/cs-etm.c b/tools/perf/util/cs-etm.c index 12b55c2bc2ca4f5d7df6b26ddbffc18b7904800e..95f439c96180d354f2bc08356a8= 44c1a79d5a148 100644 --- a/tools/perf/util/cs-etm.c +++ b/tools/perf/util/cs-etm.c @@ -6,7 +6,6 @@ * Author: Mathieu Poirier */ =20 -#include #include #include #include --=20 2.34.1