linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: "Jon Smirl" <jonsmirl@gmail.com>
To: benh@kernel.crashing.org
Cc: ppc-dev <Linuxppc-dev@ozlabs.org>, Nathan Lynch <ntl@pobox.com>
Subject: Re: can't boot mpc5200, powerpc: Enable AT_BASE_PLATFORM aux vector
Date: Fri, 25 Jul 2008 18:51:26 -0400	[thread overview]
Message-ID: <9e4733910807251551m3186fb3cy6796e1a07bb1aea2@mail.gmail.com> (raw)
In-Reply-To: <9e4733910807251546k2388b1afgba52081c20332dc4@mail.gmail.com>

On 7/25/08, Jon Smirl <jonsmirl@gmail.com> wrote:
> On 7/25/08, Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:
>  > On Fri, 2008-07-25 at 17:00 -0500, Nathan Lynch wrote:
>  >  > Jon Smirl wrote:
>  >  > > I've lost my ability to boot on the mpc5200. Reverting this patch fixes it.
>  >  >
>  >  > How does it fail?
>  >  >
>  >  >
>  >  > > @@ -1652,6 +1655,14 @@ struct cpu_spec * __init identify_cpu(unsigned
>  >  > > long offset, unsigned int pvr)
>  >  > >                     } else
>  >  > >                             *t = *s;
>  >  > >                     *PTRRELOC(&cur_cpu_spec) = &the_cpu_spec;
>  >  > > +
>  >  > > +                   /*
>  >  > > +                    * Set the base platform string once; assumes
>  >  > > +                    * we're called with real pvr first.
>  >  > > +                    */
>  >  > > +                   if (powerpc_base_platform == NULL)
>  >  > > +                           powerpc_base_platform = t->platform;
>  >  > > +
>  >  >
>  >  > Hmm, maybe this needs RELOC/PTRRELOC tricks?
>  >
>  >
>  > Hrm... indeed.
>  >
>  >  if (RELOC(powerpc_base_platform))
>  >         RELOC(powerpc_base_platform) = t->platform;

This boots:

#define RELOC(x)        (*PTRRELOC(&(x)))
			if (RELOC(powerpc_base_platform))
			       RELOC(powerpc_base_platform) = t->platform;


>
>
> It completely fails booting, no console or anything.
>
>  Where is RELOC defined, prom_init.c?
>
>  #ifdef CONFIG_PPC64
>  #define RELOC(x)        (*PTRRELOC(&(x)))
>  #define ADDR(x)         (u32) add_reloc_offset((unsigned long)(x))
>  #define OF_WORKAROUNDS  0
>  #else
>  #define RELOC(x)        (x)
>  #define ADDR(x)         (u32) (x)
>  #define OF_WORKAROUNDS  of_workarounds
>  int of_workarounds;
>  #endif
>
>
>
>  >
>  >  try that.
>  >
>  >  Ben.
>
> >
>  >
>  >
>
>
>  --
>  Jon Smirl
>  jonsmirl@gmail.com
>


-- 
Jon Smirl
jonsmirl@gmail.com

  reply	other threads:[~2008-07-25 22:51 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-07-25 21:51 can't boot mpc5200, powerpc: Enable AT_BASE_PLATFORM aux vector Jon Smirl
2008-07-25 22:00 ` Nathan Lynch
2008-07-25 22:15   ` Benjamin Herrenschmidt
2008-07-25 22:46     ` Jon Smirl
2008-07-25 22:51       ` Jon Smirl [this message]
2008-07-25 22:50     ` Nathan Lynch
2008-07-25 22:52       ` Jon Smirl
2008-07-25 22:58         ` Nathan Lynch

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=9e4733910807251551m3186fb3cy6796e1a07bb1aea2@mail.gmail.com \
    --to=jonsmirl@gmail.com \
    --cc=Linuxppc-dev@ozlabs.org \
    --cc=benh@kernel.crashing.org \
    --cc=ntl@pobox.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 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).