All of lore.kernel.org
 help / color / mirror / Atom feed
From: Samuel Mendoza-Jonas <sam.mj@au1.ibm.com>
To: Anton Blanchard <anton@samba.org>
Cc: linuxppc-dev@ozlabs.org
Subject: Re: [kexec-lite PATCH] trampoline: Reset primary cpu endian to big-endian
Date: Wed, 8 Jul 2015 13:11:42 +1000	[thread overview]
Message-ID: <559C94EE.8050201@au1.ibm.com> (raw)
In-Reply-To: <20150708115632.725120f1@kryten>

On 08/07/15 11:56, Anton Blanchard wrote:
> Hi Sam,
> 
>> Older big-endian ppc64 kernels don't include the FIXUP_ENDIAN check,
>> meaning if we kexec from a little-endian kernel the target kernel will
>> fail to boot.
>> Returning to big-endian before we enter the target kernel ensures that
>> the target kernel can boot whether or not it includes FIXUP_ENDIAN.
> 
> Thanks!
> 
> I wonder if we can do something simpler, and always enter via rfid.
> Avoids the need for the endian trampoline. Something like:
> 
>   	mtsrr0	r4
> 
> 	mfmsr	r5
> 	clrrdi	r5,r5,1 	/* Clear MSR_LE */
> 	mtsrr1	r5
> 
> 	li	r5,0
> 
> 	rfid
> 
> Anton
> 

Ah that's a neat idea, I'll test and send a V2.

Cheers,
Sam

-- 
-----------
LTC Ozlabs
IBM

      reply	other threads:[~2015-07-08  3:12 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-08  1:25 [kexec-lite PATCH] trampoline: Reset primary cpu endian to big-endian Samuel Mendoza-Jonas
2015-07-08  1:56 ` Anton Blanchard
2015-07-08  3:11   ` Samuel Mendoza-Jonas [this message]

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=559C94EE.8050201@au1.ibm.com \
    --to=sam.mj@au1.ibm.com \
    --cc=anton@samba.org \
    --cc=linuxppc-dev@ozlabs.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 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.