All of lore.kernel.org
 help / color / mirror / Atom feed
From: Julien Grall <julien.grall@linaro.org>
To: Thomas Leonard <talex5@gmail.com>
Cc: xen-devel@lists.xenproject.org,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
	David Scott <Dave.Scott@eu.citrix.com>,
	Samuel Thibault <samuel.thibault@ens-lyon.org>,
	Anil Madhavapeddy <anil@recoil.org>
Subject: Re: [PATCH ARM v4 10/12] mini-os: get RAM base and size from the FDT
Date: Thu, 19 Jun 2014 12:24:49 +0100	[thread overview]
Message-ID: <53A2C881.2000604@linaro.org> (raw)
In-Reply-To: <CAG4opy9pwKNkZFRebXU5QFpFyD_dfAxUJ8wWVwqVCzouo2Ae6A@mail.gmail.com>

On 06/19/2014 09:39 AM, Thomas Leonard wrote:
> On 18 June 2014 18:38, Julien Grall <julien.grall@linaro.org> wrote:
>> Hi Thomas,
>>
>> On 06/18/2014 04:08 PM, Thomas Leonard wrote:
>>> +        const char *device_type = fdt_getprop(device_tree, node, "device_type", NULL);
>>> +        if (device_type && !strcmp(device_type, "memory"))
>>> +        {
>>> +            /* Note: we assume there's only a single region of memory.
>>> +             * Since Xen is already translating our "physical"
>>> +             * addresses to the real physical RAM, there's no
>>> +             * reason for it to give us multiple blocks. */
>>
>> This comment looks wrong to me. Even tho, Xen is providing a stage-2
>> translation to show you a virtual layout (your guest physical memory),
>> the new layout in Xen upstream may contain multiple banks. The first
>> bank will contain up to 3G of RAM.
> 
> Hi Julien,

Hello Thomas,

> At the Hackathon, we decided Mini-OS could always rely on Xen to
> provide the memory in a single block:
> 
> "ARM guests are allowed to assume one bank of memory. We need to
> document this in the ABI. ARM guests should assume the presence of an
> FDT."

I'm not against only supporting one bank... I pointed that your comment
is wrong and doesn't reflect this sentence.

I didn't attend to this meeting, but I guess it was meant that the guest
can assume there is always one bank of memory.

I would change your comment into:

"Xen will always provide us at least one bank of memory. Mini-os will
use the first bank for the time-being"

> http://lists.xenproject.org/archives/html/mirageos-devel/2014-06/msg00004.html
> 
> A lot of the value of running on Xen is that we only have to support a
> small number of configurations, because Xen hides the details of the
> physical hardware. I assume the only reason for using the (very
> flexible) FDT format to provide this information is that it's simpler
> for full OSs which already use FDTs.

As specified in the ABI, the guest layout may change from time to time.
Actually, the layout is not compatible between Xen 4.4 and 4.5.

Unless you want your OS tight to a Xen specific version, I don't think
we want that for mini-os. You have to correctly support FDT and retrieve
every information (MMIO, IRQ) from it.

> Is the ARM guest ABI documented somewhere?

You can find the guest layout described in xen/include/public/arch-arm.h

Regards

-- 
Julien Grall

  reply	other threads:[~2014-06-19 11:24 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-18 15:08 [PATCH ARM v4 00/12] mini-os: initial ARM support Thomas Leonard
2014-06-18 15:08 ` [PATCH ARM v4 01/12] mini-os: build fixes Thomas Leonard
2014-06-18 16:26   ` Ian Campbell
2014-06-18 17:41   ` Samuel Thibault
2014-06-18 15:08 ` [PATCH ARM v4 02/12] mini-os: fixed shutdown thread Thomas Leonard
2014-06-18 15:08 ` [PATCH ARM v4 03/12] mini-os: fixed format string error in unbind_evtchn Thomas Leonard
2014-06-18 16:28   ` Ian Campbell
2014-06-18 17:42   ` Samuel Thibault
2014-06-18 15:08 ` [PATCH ARM v4 04/12] mini-os: use unbind_evtchn in unbind_all_ports Thomas Leonard
2014-06-18 16:30   ` Ian Campbell
2014-06-18 17:44   ` Samuel Thibault
2014-06-18 15:08 ` [PATCH ARM v4 05/12] mini-os: made off_t type signed Thomas Leonard
2014-06-18 16:31   ` Ian Campbell
2014-06-18 17:44   ` Samuel Thibault
2014-06-18 15:08 ` [PATCH ARM v4 06/12] mini-os: switched initial C entry point to arch_init Thomas Leonard
2014-06-18 15:08 ` [PATCH ARM v4 07/12] mini-os: initial ARM support Thomas Leonard
2014-06-18 17:48   ` Samuel Thibault
2014-06-18 22:40   ` Julien Grall
2014-06-23 15:10     ` Thomas Leonard
2014-06-23 16:55       ` Julien Grall
2014-06-23 22:33         ` Samuel Thibault
2014-06-18 15:08 ` [PATCH ARM v4 08/12] mini-os: arm: show registers, stack and exception vector on fault Thomas Leonard
2014-06-18 15:08 ` [PATCH ARM v4 09/12] mini-os: import libfdt Thomas Leonard
2014-06-18 18:02   ` Samuel Thibault
2014-06-18 15:08 ` [PATCH ARM v4 10/12] mini-os: get RAM base and size from the FDT Thomas Leonard
2014-06-18 17:38   ` Julien Grall
2014-06-19  8:39     ` Thomas Leonard
2014-06-19 11:24       ` Julien Grall [this message]
2014-07-02 15:51         ` Ian Campbell
2014-06-18 15:08 ` [PATCH ARM v4 11/12] mini-os: get GIC addresses from FDT Thomas Leonard
2014-06-18 17:25   ` Julien Grall
2014-06-19  8:50     ` Thomas Leonard
2014-06-19 10:58       ` Julien Grall
2014-06-19 16:14         ` Thomas Leonard
2014-06-19 16:20           ` Julien Grall
2014-07-02 15:55       ` Ian Campbell
2014-06-18 15:08 ` [PATCH ARM v4 12/12] mini-os: added ARM grant table initialisation Thomas Leonard
2014-06-18 17:27   ` Julien Grall
2014-06-25 16:41     ` Thomas Leonard
2014-06-25 16:50       ` Ian Campbell
2014-06-18 18:05   ` Samuel Thibault

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=53A2C881.2000604@linaro.org \
    --to=julien.grall@linaro.org \
    --cc=Dave.Scott@eu.citrix.com \
    --cc=anil@recoil.org \
    --cc=samuel.thibault@ens-lyon.org \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=talex5@gmail.com \
    --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 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.