From: Michael Ellerman <michael@ellerman.id.au>
To: Christian Kujau <lists@nerdbynature.de>
Cc: Steven Rostedt <rostedt@goodmis.org>, linuxppc-dev@ozlabs.org
Subject: Re: 3.5+: yaboot, Invalid memory access
Date: Tue, 04 Sep 2012 16:51:31 +1000 [thread overview]
Message-ID: <1346741491.7619.12.camel@concordia> (raw)
In-Reply-To: <alpine.DEB.2.01.1209032310220.25392@trent.utfs.org>
On Mon, 2012-09-03 at 23:18 -0700, Christian Kujau wrote:
> On Mon, 30 Jul 2012 at 22:46, Christian Kujau wrote:
> > when trying to upgrade from 3.5 (final) to today's git checkout from
> > Linus' tree, yaboot cannot boot and the following is printed:
> >
> > [...]
> > returning from prom_init
> > Invalid memory access at %SRR0: 00c62fd4 %SRR1: 00003030
>
> Finally got around to do a bisection:
>
> -----------------------------
> b6e3796834faefe4b6e9a2aedfe12665cd51fbc5 is the first bad commit
> commit b6e3796834faefe4b6e9a2aedfe12665cd51fbc5
> Author: Steven Rostedt <srostedt@redhat.com>
> Date: Thu Apr 26 08:31:18 2012 +0000
>
> powerpc: Have patch_instruction detect faults
>
> For ftrace to use the patch_instruction code, it needs to check for
> faults on write. Ftrace updates code all over the kernel, and we need
> to know if code is updated or not due to protections that are placed
> on some portions of the kernel. If ftrace does not detect a fault, it
> will error later on, and it will be much more difficult to find the
> problem.
>
> By changing patch_instruction() to detect faults, then ftrace will be
> able to make use of it too.
>
> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
>
> :040000 040000 83fb0e420524db452c07425e4dc402041428e696 0d1a01acd863237cf388045946ad4446a28df50c M arch
> -----------------------------
>
> The changeset looked pretty harmless to me but I tested with a current
> 3.6+ git checkout and the kernel would only boot when this changeset was
> reverted.
>
> Thoughts?
My guess would be we're calling that quite early and the __put_user()
check is getting confused and failing. That means we'll have left some
code unpatched, which then fails.
Can you try with the patch applied, but instead of returning if the
__put_user() fails, just continue on anyway.
That will isolate if it's something in the __put_user() (I doubt it), or
just that the __put_user() is failing and leaving the code unpatched.
cheers
next prev parent reply other threads:[~2012-09-04 6:51 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-31 5:46 3.5+: yaboot, Invalid memory access Christian Kujau
2012-08-01 2:02 ` Tony Breeds
2012-08-01 7:30 ` Christian Kujau
2012-09-04 6:18 ` Christian Kujau
2012-09-04 6:51 ` Michael Ellerman [this message]
2012-09-04 9:32 ` Christian Kujau
2012-09-05 1:08 ` Benjamin Herrenschmidt
2012-09-05 5:25 ` Christian Kujau
2012-09-05 5:29 ` Benjamin Herrenschmidt
2012-09-04 14:27 ` Steven Rostedt
2012-09-04 19:49 ` Benjamin Herrenschmidt
2012-09-04 19:40 ` Benjamin Herrenschmidt
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=1346741491.7619.12.camel@concordia \
--to=michael@ellerman.id.au \
--cc=linuxppc-dev@ozlabs.org \
--cc=lists@nerdbynature.de \
--cc=rostedt@goodmis.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 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).