From: Madhavan Srinivasan <maddy@linux.vnet.ibm.com>
To: Michael Ellerman <mpe@ellerman.id.au>, Anju T <anju@linux.vnet.ibm.com>
Cc: hemant@linux.vnet.ibm.com, linuxppc-dev@lists.ozlabs.org,
linux-kernel@vger.kernel.org, acme@redhat.com, dsahern@gmail.com,
naveen.n.rao@linux.vnet.ibm.com, sukadev@linux.vnet.ibm.com,
jolsa@redhat.com, khandual@linux.vnet.ibm.com
Subject: Re: [PATCH V10 2/4] perf/powerpc: add support for sampling intr machine state
Date: Mon, 25 Jan 2016 08:58:17 +0530 [thread overview]
Message-ID: <56A59651.6010903@linux.vnet.ibm.com> (raw)
In-Reply-To: <1453286426.14751.19.camel@ellerman.id.au>
On Wednesday 20 January 2016 04:10 PM, Michael Ellerman wrote:
> On Mon, 2016-01-11 at 15:58 +0530, Anju T wrote:
>> diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
>> index 9a7057e..c4ce60d 100644
>> --- a/arch/powerpc/Kconfig
>> +++ b/arch/powerpc/Kconfig
>> @@ -119,6 +119,7 @@ config PPC
>> select GENERIC_ATOMIC64 if PPC32
>> select ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE
>> select HAVE_PERF_EVENTS
>> + select HAVE_PERF_REGS
>> select HAVE_REGS_AND_STACK_ACCESS_API
>> select HAVE_HW_BREAKPOINT if PERF_EVENTS && PPC_BOOK3S_64
>> select ARCH_WANT_IPC_PARSE_VERSION
>> diff --git a/arch/powerpc/perf/perf_regs.c b/arch/powerpc/perf/perf_regs.c
>> new file mode 100644
>> index 0000000..d32581763
>> --- /dev/null
>> +++ b/arch/powerpc/perf/perf_regs.c
> ...
>> +
>> +u64 perf_reg_abi(struct task_struct *task)
>> +{
>> + return PERF_SAMPLE_REGS_ABI_64;
> What is this value used for exactly?
>
> It seems like on 32-bit kernels we should be returning PERF_SAMPLE_REGS_ABI_32.
Yes. you are right. But even in 64bit kernel, based on the application
we need to return 32 to 64 abi. Damn my bad. missed 32bit part
all together.
Maddy
>
>> +}
>> +
>> +void perf_get_regs_user(struct perf_regs *regs_user,
>> + struct pt_regs *regs,
>> + struct pt_regs *regs_user_copy)
>> +{
>> + regs_user->regs = task_pt_regs(current);
>> + regs_user->abi = perf_reg_abi(current);
>> +}
> cheers
>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
next prev parent reply other threads:[~2016-01-25 3:28 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-11 10:28 [PATCH V10 0/4] perf/powerpc: Add ability to sample intr machine state in powerpc Anju T
2016-01-11 10:28 ` [PATCH V10 1/4] perf/powerpc: assign an id to each powerpc register Anju T
2016-01-20 10:38 ` Michael Ellerman
2016-01-21 8:46 ` Anju T
2016-01-11 10:28 ` [PATCH V10 2/4] perf/powerpc: add support for sampling intr machine state Anju T
2016-01-20 10:40 ` Michael Ellerman
2016-01-21 9:57 ` Anju T
2016-01-25 3:28 ` Madhavan Srinivasan [this message]
2016-01-11 10:28 ` [PATCH v10 3/4] tools/perf: Map the ID values with register names Anju T
2016-01-20 10:46 ` Michael Ellerman
2016-01-21 10:02 ` Anju T
2016-01-11 10:28 ` [PATCH V1 4/4] tool/perf: Add sample_reg_mask to include all perf_regs regs Anju T
-- strict thread matches above, loose matches on Subject: below --
2016-01-11 5:59 [PATCH V10 0/4] perf/powerpc: Add ability to sample intr machine state in powerpc Anju T
2016-01-11 5:59 ` [PATCH V10 2/4] perf/powerpc: add support for sampling intr machine state Anju T
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=56A59651.6010903@linux.vnet.ibm.com \
--to=maddy@linux.vnet.ibm.com \
--cc=acme@redhat.com \
--cc=anju@linux.vnet.ibm.com \
--cc=dsahern@gmail.com \
--cc=hemant@linux.vnet.ibm.com \
--cc=jolsa@redhat.com \
--cc=khandual@linux.vnet.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mpe@ellerman.id.au \
--cc=naveen.n.rao@linux.vnet.ibm.com \
--cc=sukadev@linux.vnet.ibm.com \
/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.