lkml.org 
[lkml]   [2020]   [Nov]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH v6 20/21] perf arm_spe: Decode memory tagging properties
On Tue, Nov 03, 2020 at 06:51:01AM +0000, Leo Yan wrote:
> On Mon, Nov 02, 2020 at 04:25:36PM +0000, Dave Martin wrote:
> > On Fri, Oct 30, 2020 at 02:57:23AM +0000, Leo Yan wrote:
> > > From: Andre Przywara <andre.przywara@arm.com>
> > >
> > > When SPE records a physical address, it can additionally tag the event
> > > with information from the Memory Tagging architecture extension.
> > >
> > > Decode the two additional fields in the SPE event payload.
> > >
> > > [leoy: Refined patch to use predefined macros]
> > >
> > > Signed-off-by: Andre Przywara <andre.przywara@arm.com>
> > > Signed-off-by: Leo Yan <leo.yan@linaro.org>
> > > ---
> > > tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c | 6 +++++-
> > > tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.h | 2 ++
> > > 2 files changed, 7 insertions(+), 1 deletion(-)
> > >
> > > diff --git a/tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c b/tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c
> > > index 3fca65e9cbbf..9ec3057de86f 100644
> > > --- a/tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c
> > > +++ b/tools/perf/util/arm-spe-decoder/arm-spe-pkt-decoder.c
> > > @@ -371,6 +371,7 @@ static int arm_spe_pkt_desc_addr(const struct arm_spe_pkt *packet,
> > > char *buf, size_t buf_len)
> > > {
> > > int ns, el, idx = packet->index;
> > > + int ch, pat;
> > > u64 payload = packet->payload;
> > > int err = 0;
> > >
> > > @@ -388,9 +389,12 @@ static int arm_spe_pkt_desc_addr(const struct arm_spe_pkt *packet,
> > > "VA 0x%llx", payload);
> > > case SPE_ADDR_PKT_HDR_INDEX_DATA_PHYS:
> > > ns = !!SPE_ADDR_PKT_GET_NS(payload);
> > > + ch = !!SPE_ADDR_PKT_GET_CH(payload);
> > > + pat = SPE_ADDR_PKT_GET_PAT(payload);
> > > payload = SPE_ADDR_PKT_ADDR_GET_BYTES_0_6(payload);
> > > return arm_spe_pkt_snprintf(&err, &buf, &buf_len,
> > > - "PA 0x%llx ns=%d", payload, ns);
> > > + "PA 0x%llx ns=%d ch=%d, pat=%x",
> >
> > Nit: given that this data is all closely related, do we really want the
> > extra comma here?
>
> No reason for adding comma. Will remove it.

OK, I'm happy for my Reviewed-by to stand.

[...]

Cheers
---Dave

\
 
 \ /
  Last update: 2020-11-03 13:14    [W:0.091 / U:0.332 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site