xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Dirk Behme <dirk.behme@de.bosch.com>
To: Andre Przywara <andre.przywara@arm.com>,
	Dirk Behme <dirk.behme@gmail.com>,
	Julien Grall <julien.grall@arm.com>,
	xen-devel@lists.xenproject.org
Cc: Stefano Stabellini <sstabellini@kernel.org>
Subject: Re: [PATCH v2] xen: arm64: Add support for Renesas RCar Gen3 H3 Salvator-X platform
Date: Fri, 8 Jul 2016 13:38:19 +0200	[thread overview]
Message-ID: <396467d4-39e0-5312-160c-42533ce97a81@de.bosch.com> (raw)
In-Reply-To: <0a4948e4-9b5f-a6ad-9f16-ab040f6e952f@arm.com>

Hi Andre,

On 05.07.2016 16:29, Andre Przywara wrote:
> Hi,
>
> On 05/07/16 15:22, Dirk Behme wrote:
>> On 05.07.2016 15:45, Andre Przywara wrote:
>>> Hi,
>>>
>>> On 05/07/16 14:34, Julien Grall wrote:
>>>> (CC Andre)
>>>>
>>>> On 05/07/16 14:04, Dirk Behme wrote:
>>>>> On 05.07.2016 14:45, Julien Grall wrote:
>>>>>>
>>>>>>
>>>>>> On 05/07/16 13:09, Dirk Behme wrote:
>>>>>>> Hi Julien,
>>>>>>>
>>>>>>> On 05.07.2016 13:39, Julien Grall wrote:
>>>>>>>> Hi Dirk,
>>>>>>>>
>>>>>>>> On 05/07/16 07:37, Dirk Behme wrote:
>>>>>>>>> Signed-off-by: Dirk Behme <dirk.behme@de.bosch.com>
>>>>>>>>
>>>>>>>> This patch looks good to me, however I would like to see the
>>>>>>>> documentation on the wiki page (see [1]) before giving any formal
>>>>>>>> ack.
>>>>>>>
>>>>>>>
>>>>>>> Ok, many thanks for your review!
>>>>>>>
>>>>>>> Yes, I understood that something more is needed.
>>>>>>>
>>>>>>>
>>>>>>> I just wonder if we keep the patch on the mailing list for a moment.
>>>>>>> With this it's publically available and we can see how's the public
>>>>>>> interest for this board.
>>>>>>>
>>>>>>> Additionally, getting Xen running on this board and describe all
>>>>>>> this in
>>>>>>> the wiki isn't that easy. You either need to modify the flashed
>>>>>>> firmware. Or, like me, load everything via a JTAG debugger ...
>>>>>>
>>>>>> Can you details why you think it is not easy? Why do you have to
>>>>>> modify
>>>>>> the firmware? Is it because it does not boot the hypervisor in EL2?
>>>>>
>>>>>
>>>>> The board boots via ATF, which starts U-Boot in EL1, then. You have to
>>>>> find a way to load Xen into memory (e.g. U-Boot TFTP) and then
>>>>> switch to
>>>>> EL2 to start Xen.
>>>>
>>>> But ATF is running in EL3, right? If so, can ATF just starts U-boot
>>>> in EL2?
>>>>
>>>> I have a board at home (pine64) which also uses ATF and U-Boot and is
>>>> able to boot Xen without any SMC call because the U-Boot is entered
>>>> in EL2.
>>>
>>>  From having a very quick look into the rcar ATF port on github[1] I see:
>>>
>>> +#elif (RCAR_BL33_EXECUTION_EL == BL33_EL2)
>>> +    return (uint32_t)SPSR_64(MODE_EL2, MODE_SP_ELX,
>>> DISABLE_ALL_EXCEPTIONS);
>>>
>>> So if you rebuild ATF with RCAR_BL33_EXECUTION_EL set to BL33_EL2 that
>>> should enter U-Boot in EL2.
>>>
>>> The fix for the Pine64 was equally simple and works fine since then.
>>
>>
>> This is an other solution most probably I meant when talking about
>> "modifying the firmware" ;)
>>
>> I'm somehow unsure about the pros and cons running U-Boot at EL1 versus
>> EL2, though.
>
> It shouldn't matter, really. U-Boot on AArch64 (called armv8 here) is
> able to run in any exception level (in contrast to ARMv7).
> Actually running in EL2 is the architecturally recommended way, even
> with ATF (by default it drops into EL2 when returning to non-secure
> world). On Juno (and the Pine64) is works fine this way.
>
> As U-Boot only uses an identity mapping, many differences between EL2
> and EL1 don't matter.

An understanding question regarding this: We found that running U-Boot 
at EL2 works fine and starting Xen works fine, then, too. So many thanks 
for that hint!

But we found that the Linux native boot case (without Xen) does fail, 
then. I.e. running U-Boot in EL1 starts the native Linux kernel 
successfully. While running U-Boot in EL2 starting the native Linux 
kernel fails, then.

Any idea regarding this?

Who is responsible to switch to EL1 for the native Linux boot case if 
U-Boot runs at EL2?

Best regards

Dirk


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  parent reply	other threads:[~2016-07-08 11:38 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-05  6:37 [PATCH v2] xen: arm64: Add support for Renesas RCar Gen3 H3 Salvator-X platform Dirk Behme
2016-07-05 11:39 ` Julien Grall
2016-07-05 12:09   ` Dirk Behme
2016-07-05 12:45     ` Julien Grall
2016-07-05 13:04       ` Dirk Behme
2016-07-05 13:34         ` Julien Grall
2016-07-05 13:45           ` Andre Przywara
2016-07-05 14:22             ` Dirk Behme
2016-07-05 14:29               ` Andre Przywara
2016-07-06  6:33                 ` Dirk Behme
2016-07-06 13:17                   ` Julien Grall
2016-07-06 14:03                     ` Dirk Behme
2016-07-06 14:21                       ` Julien Grall
2016-07-07 10:39                         ` Dirk Behme
2016-07-07 10:46                           ` Julien Grall
2016-07-08 11:38                 ` Dirk Behme [this message]
2016-07-11  9:25                   ` Andre Przywara
2016-07-11 10:15                     ` Dirk Behme
2016-07-05 13:04     ` Stefano Stabellini

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=396467d4-39e0-5312-160c-42533ce97a81@de.bosch.com \
    --to=dirk.behme@de.bosch.com \
    --cc=andre.przywara@arm.com \
    --cc=dirk.behme@gmail.com \
    --cc=julien.grall@arm.com \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xenproject.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).