All of lore.kernel.org
 help / color / mirror / Atom feed
From: Leo Yan <leo.yan@arm.com>
To: James Clark <james.clark@linaro.org>
Cc: John Garry <john.g.garry@oracle.com>,
	Will Deacon <will@kernel.org>, Mike Leach <mike.leach@arm.com>,
	Leo Yan <leo.yan@linux.dev>,
	Suzuki K Poulose <suzuki.poulose@arm.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Ingo Molnar <mingo@redhat.com>,
	Arnaldo Carvalho de Melo <acme@kernel.org>,
	Namhyung Kim <namhyung@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Alexander Shishkin <alexander.shishkin@linux.intel.com>,
	Jiri Olsa <jolsa@kernel.org>, Ian Rogers <irogers@google.com>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Suyash Mahar <smahar@meta.com>, Amir Ayupov <aaupov@fb.com>,
	Arnaldo Carvalho de Melo <acme@redhat.com>,
	linux-arm-kernel@lists.infradead.org, coresight@lists.linaro.org,
	linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 4/6] perf: cs-etm: Respect --no-itrace option
Date: Fri, 4 Sep 2026 18:45:03 +0100	[thread overview]
Message-ID: <20260904174503.GC8904@e132581.arm.com> (raw)
In-Reply-To: <20260821-james-cs-hw_id-output-failure-v1-4-9d532ddabcc3@linaro.org>

On Fri, Aug 21, 2026 at 10:50:32AM +0100, James Clark wrote:

[...]

> @@ -3603,27 +3603,49 @@ int cs_etm__process_auxtrace_info_full(union perf_event *event,
>  	int err = 0;
>  	int aux_hw_id_found;
>  	int i;
> -	u64 *ptr = NULL;
> +	u64 *ptr = (u64 *) auxtrace_info->priv;
>  	u64 **metadata = NULL;
>  
> -	/* First the global part */
> -	ptr = (u64 *) auxtrace_info->priv;
> -	num_cpu = ptr[CS_PMU_TYPE_CPUS] & 0xffffffff;
> +	etm = zalloc(sizeof(*etm));
> +	if (!etm)
> +		return -ENOMEM;
> +
> +	session->auxtrace = &etm->auxtrace;
> +	etm->auxtrace.free = cs_etm__free;
> +	etm->auxtrace.evsel_is_auxtrace = cs_etm__evsel_is_auxtrace;
> +	etm->auxtrace.process_event = cs_etm__process_event;
> +	etm->auxtrace.process_auxtrace_event = cs_etm__process_auxtrace_event;
> +	etm->auxtrace.flush_events = cs_etm__flush_events;
> +	etm->auxtrace.free_events = cs_etm__free_events;
> +	etm->pmu_type = (unsigned int) ((ptr[CS_PMU_TYPE_CPUS] >> 32) & 0xffffffff);
> +
> +	/*
> +	 * Don't go further than the minimum required to identify this event as
> +	 * auxtrace with cs_etm__evsel_is_auxtrace() so unleader_auxtrace()
> +	 * works.
> +	 */
> +	if (auxtrace__dont_decode(session))
> +		return 0;

TBH, I don't look in details, currently auxtrace__dont_decode() only
exits in the common util/auxtrace.c, why other AUX trace can work well
the option but cs-etm.c needs particular initialization?

Seems to me, we even don't need to do any initialization in cs-etm.c
if the no-itrace flag is set.

  parent reply	other threads:[~2026-09-04 17:45 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-21  9:50 [PATCH 0/6] perf: cs-etm: HW_ID improvements James Clark
2026-08-21  9:50 ` [PATCH 1/6] perf: cs-etm: Don't add global v0 HW_IDs to unformatted queues James Clark
2026-08-21 10:03   ` sashiko-bot
2026-09-04 16:43   ` Leo Yan
2026-08-21  9:50 ` [PATCH 2/6] perf cs-etm: Free partially created queues James Clark
2026-08-21 10:05   ` sashiko-bot
2026-09-04 17:12   ` Leo Yan
2026-08-21  9:50 ` [PATCH 3/6] perf cs-etm: Synthesize missing HW_ID mappings for raw trace James Clark
2026-08-21 10:06   ` sashiko-bot
2026-09-04 17:29   ` Leo Yan
2026-08-21  9:50 ` [PATCH 4/6] perf: cs-etm: Respect --no-itrace option James Clark
2026-08-21 10:08   ` sashiko-bot
2026-08-24  9:53   ` Adrian Hunter
2026-09-04 17:45   ` Leo Yan [this message]
2026-08-21  9:50 ` [PATCH 5/6] perf/core: Return errors from perf_report_aux_output_id() James Clark
2026-08-21 10:10   ` sashiko-bot
2026-08-21  9:50 ` [PATCH 6/6] coresight: perf: Retry failed HW_ID writes James Clark
2026-08-21 10:01   ` James Clark
2026-08-21 10:11   ` sashiko-bot

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=20260904174503.GC8904@e132581.arm.com \
    --to=leo.yan@arm.com \
    --cc=aaupov@fb.com \
    --cc=acme@kernel.org \
    --cc=acme@redhat.com \
    --cc=adrian.hunter@intel.com \
    --cc=alexander.shishkin@linux.intel.com \
    --cc=coresight@lists.linaro.org \
    --cc=irogers@google.com \
    --cc=james.clark@linaro.org \
    --cc=john.g.garry@oracle.com \
    --cc=jolsa@kernel.org \
    --cc=leo.yan@linux.dev \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mike.leach@arm.com \
    --cc=mingo@redhat.com \
    --cc=namhyung@kernel.org \
    --cc=peterz@infradead.org \
    --cc=smahar@meta.com \
    --cc=suzuki.poulose@arm.com \
    --cc=will@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.