Linux Perf Users
 help / color / mirror / Atom feed
From: Leo Yan <leo.yan@arm.com>
To: Arnaldo Carvalho de Melo <acme@kernel.org>,
	 Namhyung Kim <namhyung@kernel.org>, Jiri Olsa <jolsa@kernel.org>,
	 Ian Rogers <irogers@google.com>,
	Adrian Hunter <adrian.hunter@intel.com>,
	 James Clark <james.clark@linaro.org>
Cc: linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org,
	 Leo Yan <leo.yan@arm.com>
Subject: [PATCH 0/2] tools build: Fix arm64's unistd_64.h dependency
Date: Thu, 04 Dec 2025 16:53:40 +0000	[thread overview]
Message-ID: <20251204-perf_fix_syscall_header-v1-0-b8e27f74ed6a@arm.com> (raw)

Arm64's unistd.h is included in the tools build, but its dependent
header unistd_64.h is missing.  This results in only a partial set of UAPI
headers being available, forcing tools to generate unistd_64.h dynamically.

Because unistd.h is widely used across the tools directory, relying on a
dynamically generated header is fragile, especially when a tool builds in
multiple stages, each of which may include unistd.h.

This series addresses the issue by adding a generated unistd_64.h
directly to the tools tree, ensuring the header is available from the
start and eliminating build failures due to header dependency.

This series has been tested with Arm64 cross-compilation and confirmed
that the BPF feature is enabled in perf.  It also verifies libperf
in-source builds with applying this series.

Signed-off-by: Leo Yan <leo.yan@arm.com>
---
Leo Yan (2):
      tools headers: Add arm64's unistd_64.h
      Revert "perf tools: Fix arm64 build by generating unistd_64.h"

 tools/arch/arm64/include/uapi/asm/unistd_64.h | 330 ++++++++++++++++++++++++++
 tools/lib/perf/Makefile                       |  14 +-
 tools/perf/Makefile.config                    |   1 -
 3 files changed, 332 insertions(+), 13 deletions(-)
---
base-commit: 267c2e633af6e9461477bed91e428993f8b36ee8
change-id: 20251203-perf_fix_syscall_header-e280fa931d44

Best regards,
-- 
Leo Yan <leo.yan@arm.com>


             reply	other threads:[~2025-12-04 16:53 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-12-04 16:53 Leo Yan [this message]
2025-12-04 16:53 ` [PATCH 1/2] tools headers: Add arm64's unistd_64.h Leo Yan
2025-12-04 16:53 ` [PATCH 2/2] Revert "perf tools: Fix arm64 build by generating unistd_64.h" Leo Yan
2025-12-04 18:19   ` Ian Rogers
2025-12-05 16:21     ` Leo Yan
2025-12-05 17:16       ` Ian Rogers
2025-12-09 10:49         ` Leo Yan
2025-12-09 16:37           ` Ian Rogers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20251204-perf_fix_syscall_header-v1-0-b8e27f74ed6a@arm.com \
    --to=leo.yan@arm.com \
    --cc=acme@kernel.org \
    --cc=adrian.hunter@intel.com \
    --cc=irogers@google.com \
    --cc=james.clark@linaro.org \
    --cc=jolsa@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=namhyung@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox