From: sashiko-bot@kernel.org
To: "Leo Yan" <leo.yan@arm.com>
Cc: linux-perf-users@vger.kernel.org
Subject: Re: [PATCH] perf test: Record kcore for the CoreSight callchain test
Date: Mon, 28 Sep 2026 09:19:08 +0000 [thread overview]
Message-ID: <20260928091908.E01101F000FF@smtp.kernel.org> (raw)
In-Reply-To: <20260928090644.24346-1-leo.yan@arm.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] perf/test: fail instead of skip when /proc/kcore is inaccessible
--
commit f13d58799b60cb0c738cb7c9e2cb5ed0a5fa9e32
Author: Leo Yan <leo.yan@arm.com>
Subject: perf test: Record kcore for the CoreSight callchain test
The CoreSight callchain test traces both userspace and kernel execution
and checks the callchain across a syscall.
Add --kcore to perf record to save the running kernel image alongside
the trace data so perf script can use it to decode the kernel trace.
> diff --git a/tools/perf/tests/shell/coresight/callchain.sh b/tools/perf/tests/shell/coresight/callchain.sh
> index 13cca7dc11184..b69187f1a37f5 100755
> --- a/tools/perf/tests/shell/coresight/callchain.sh
> +++ b/tools/perf/tests/shell/coresight/callchain.sh
> @@ -43,7 +43,7 @@ record_trace()
>
> mkfifo "$cf" "$af"
>
> - perf record -o "$data" -e cs_etm// --per-thread -D -1 --control fifo:"$cf","$af" -- \
> + perf record --kcore -o "$data" -e cs_etm// --per-thread -D -1 --control fifo:"$cf","$af" -- \
[Severity: Medium]
Will this unconditional --kcore flag cause the test to fail instead of
skipping when /proc/kcore is inaccessible?
If /proc/kcore is missing (e.g., due to CONFIG_PROC_KCORE=n) or restricted
by kernel lockdown, perf record --kcore returns an error. This error causes
record_trace() to fail, which propagates an overall test failure (exit
code 1) instead of gracefully skipping (exit code 2). This may cause false
positive regression reports in kernel CI environments.
Should skip_if_system_is_not_ready() be updated to check [ -r /proc/kcore ]
to ensure the test degrades gracefully?
> perf test --record-ctl fifo:"$cf","$af" -w callchain >/dev/null 2>&1 &&
>
> # It is safe to use 'i3i' with a three-instruction interval, since the
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260928090644.24346-1-leo.yan@arm.com?part=1
prev parent reply other threads:[~2026-09-28 9:19 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-28 9:06 [PATCH] perf test: Record kcore for the CoreSight callchain test Leo Yan
2026-09-28 9:13 ` James Clark
2026-09-28 9:19 ` sashiko-bot [this message]
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=20260928091908.E01101F000FF@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=leo.yan@arm.com \
--cc=linux-perf-users@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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