From: Ravi Bangoria <ravi.bangoria@linux.vnet.ibm.com>
To: Michael Ellerman <mpe@ellerman.id.au>
Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org,
benh@kernel.crashing.org, paulus@samba.org,
lsorense@csclub.uwaterloo.ca, oohall@gmail.com,
naveen.n.rao@linux.vnet.ibm.com, ast@kernel.org,
chris@distroguy.com, aneesh.kumar@linux.vnet.ibm.com,
bsingharora@gmail.com, anton@samba.org,
paul.gortmaker@windriver.com, bauerman@linux.vnet.ibm.com,
viro@zeniv.linux.org.uk, christophe.leroy@c-s.fr, duwe@lst.de,
oss@buserror.net,
Ravi Bangoria <ravi.bangoria@linux.vnet.ibm.com>
Subject: Re: [PATCH v3 1/2] powerpc: Emulation support for load/store instructions on LE
Date: Tue, 14 Feb 2017 17:05:57 +0530 [thread overview]
Message-ID: <58A2EB9D.4080506@linux.vnet.ibm.com> (raw)
In-Reply-To: <87d1elm5uu.fsf@concordia.ellerman.id.au>
Thanks Michael,
On Tuesday 14 February 2017 03:50 PM, Michael Ellerman wrote:
> Ravi Bangoria <ravi.bangoria@linux.vnet.ibm.com> writes:
>
>> emulate_step() uses a number of underlying kernel functions that were
>> initially not enabled for LE. This has been rectified since.
> When exactly? ie. which commit.
I found couple of commits:
6506b4718b ("powerpc: Fix Unaligned Loads and Stores")
dbc2fbd7c2 ("powerpc: Fix Unaligned LE Floating Point Loads and Stores")
There may be more.
Patch2 is to test emulate_step() for basic load/store instructions and it
seems to be working fine on LE.
>
> Should we backport this? ie. is it actually a bug people are hitting in
> the real world much?
Yes, we should backport this. kernel-space hw-breakpoint feature is broken
on LE without this. This is on ppc64le:
$ sudo cat /proc/kallsyms | grep pid_max
c00000000116998c D pid_max
$ sudo ./perf record -a --event=mem:0xc00000000116998c sleep 10
Before patch:
It does not record any data and throws below warning.
$ dmesg
[ 817.895573] Unable to handle hardware breakpoint. Breakpoint at 0xc00000000116998c will be disabled.
[ 817.895581] ------------[ cut here ]------------
[ 817.895588] WARNING: CPU: 24 PID: 2032 at arch/powerpc/kernel/hw_breakpoint.c:277 hw_breakpoint_handler+0x124/0x230
...
After patch:
It records data properly.
$ sudo ./perf report --stdio
...
# Samples: 36 of event 'mem:0xc00000000116998c'
# Event count (approx.): 36
#
# Overhead Command Shared Object Symbol
# ........ ............. ................ .............
#
63.89% kdumpctl [kernel.vmlinux] [k] alloc_pid
27.78% opal_errd [kernel.vmlinux] [k] alloc_pid
5.56% kworker/u97:4 [kernel.vmlinux] [k] alloc_pid
2.78% systemd [kernel.vmlinux] [k] alloc_pid
>
> cheers
>
next prev parent reply other threads:[~2017-02-14 11:36 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-14 9:16 [PATCH v3 0/2] powerpc: Emulation support for load/store instructions on LE Ravi Bangoria
2017-02-14 9:16 ` [PATCH v3 1/2] " Ravi Bangoria
2017-02-14 10:20 ` Michael Ellerman
2017-02-14 11:35 ` Ravi Bangoria [this message]
2017-03-08 7:25 ` [v3, " Michael Ellerman
2017-02-14 9:16 ` [PATCH v3 2/2] powerpc: emulate_step tests for load/store instructions Ravi Bangoria
2017-02-14 10:41 ` Michael Ellerman
2017-02-14 10:46 ` Michael Ellerman
2017-02-14 11:38 ` Ravi Bangoria
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=58A2EB9D.4080506@linux.vnet.ibm.com \
--to=ravi.bangoria@linux.vnet.ibm.com \
--cc=aneesh.kumar@linux.vnet.ibm.com \
--cc=anton@samba.org \
--cc=ast@kernel.org \
--cc=bauerman@linux.vnet.ibm.com \
--cc=benh@kernel.crashing.org \
--cc=bsingharora@gmail.com \
--cc=chris@distroguy.com \
--cc=christophe.leroy@c-s.fr \
--cc=duwe@lst.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=lsorense@csclub.uwaterloo.ca \
--cc=mpe@ellerman.id.au \
--cc=naveen.n.rao@linux.vnet.ibm.com \
--cc=oohall@gmail.com \
--cc=oss@buserror.net \
--cc=paul.gortmaker@windriver.com \
--cc=paulus@samba.org \
--cc=viro@zeniv.linux.org.uk \
/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;
as well as URLs for NNTP newsgroup(s).