From: Daniel Axtens <dja@axtens•net>
To: Athira Rajeev <atrajeev@linux•vnet.ibm.com>,
mpe@ellerman•id.au, acme@kernel•org, jolsa@kernel•org
Cc: kjain@linux•ibm.com, maddy@linux•vnet.ibm.com,
linuxppc-dev@lists•ozlabs.org, rnsastry@linux•ibm.com
Subject: Re: [V2 3/4] powerpc/perf: Expose instruction and data address registers as part of extended regs
Date: Fri, 01 Oct 2021 16:40:26 +1000 [thread overview]
Message-ID: <87lf3dmen9.fsf@linkitivity.dja.id.au> (raw)
In-Reply-To: <20210930122055.1390-4-atrajeev@linux.vnet.ibm.com>
Athira Rajeev <atrajeev@linux•vnet.ibm.com> writes:
> Patch adds support to include Sampled Instruction Address Register
This is a nit and doesn't require a new revision, but I think this
should read "Include Sampled Instruction Address ...", not "Patch adds
support to include Sampled Instruction ..." - see
https://www.kernel.org/doc/html/v5.11/process/submitting-patches.html#describe-your-changes
> (SIAR) and Sampled Data Address Register (SDAR) SPRs as part of extended
> registers. Update the definition of PERF_REG_PMU_MASK_300/31 and
> PERF_REG_EXTENDED_MAX to include these SPR's.
> diff --git a/arch/powerpc/perf/perf_regs.c b/arch/powerpc/perf/perf_regs.c
> index b931eed482c9..51d31b65e423 100644
> --- a/arch/powerpc/perf/perf_regs.c
> +++ b/arch/powerpc/perf/perf_regs.c
> @@ -90,7 +90,11 @@ static u64 get_ext_regs_value(int idx)
> return mfspr(SPRN_SIER2);
> case PERF_REG_POWERPC_SIER3:
> return mfspr(SPRN_SIER3);
> + case PERF_REG_POWERPC_SDAR:
> + return mfspr(SPRN_SDAR);
> #endif
> + case PERF_REG_POWERPC_SIAR:
> + return mfspr(SPRN_SIAR);
I was initially confused about why SIAR was outside the CONFIG_PPC64
block and SDAR was inside. But it turns out that SIAR is also defined
for a 32 bit platform, so that makes sense.
I'm not an expert on how the perf subsystem works, but this all seems
consistent with the surrounding code and it seems to do what the commit
message says, so on that limited basis:
Reviewed-by: Daniel Axtens <dja@axtens•net>
Kind regards,
Daniel
next prev parent reply other threads:[~2021-10-01 6:41 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-09-30 12:20 [V2 0/4] powerpc/perf: Add instruction and data address registers to extended regs Athira Rajeev
2021-09-30 12:20 ` [V2 1/4] powerpc/perf: Refactor the code definition of perf reg extended mask Athira Rajeev
2021-10-05 5:52 ` Michael Ellerman
2021-09-30 12:20 ` [V2 2/4] tools/perf: Refactor the code definition of perf reg extended mask in tools side header file Athira Rajeev
2021-10-01 6:20 ` Daniel Axtens
2021-10-01 10:18 ` Athira Rajeev
2021-10-01 11:29 ` Michael Ellerman
2021-09-30 12:20 ` [V2 3/4] powerpc/perf: Expose instruction and data address registers as part of extended regs Athira Rajeev
2021-10-01 6:40 ` Daniel Axtens [this message]
2021-09-30 12:20 ` [V2 4/4] tools/perf: Add perf tools support to expose " Athira Rajeev
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=87lf3dmen9.fsf@linkitivity.dja.id.au \
--to=dja@axtens$(echo .)net \
--cc=acme@kernel$(echo .)org \
--cc=atrajeev@linux$(echo .)vnet.ibm.com \
--cc=jolsa@kernel$(echo .)org \
--cc=kjain@linux$(echo .)ibm.com \
--cc=linuxppc-dev@lists$(echo .)ozlabs.org \
--cc=maddy@linux$(echo .)vnet.ibm.com \
--cc=mpe@ellerman$(echo .)id.au \
--cc=rnsastry@linux$(echo .)ibm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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