xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: David Vrabel <david.vrabel@citrix.com>
To: Ian Campbell <Ian.Campbell@citrix.com>,
	Andrew Cooper <andrew.cooper3@citrix.com>
Cc: xen-devel@lists.xen.org, julien.grall@linaro.org, tim@xen.org,
	stefano.stabellini@eu.citrix.com
Subject: Re: [PATCH] xen: arm: configure correct dom0_gnttab_start/size
Date: Thu, 11 Sep 2014 17:51:58 +0100	[thread overview]
Message-ID: <5411D32E.1020101@citrix.com> (raw)
In-Reply-To: <1410451505.567.7.camel@kazak.uk.xensource.com>

On 11/09/14 17:05, Ian Campbell wrote:
> On Thu, 2014-09-11 at 16:54 +0100, Andrew Cooper wrote:
>> Why it is hard coded at all? (x86 appears to manage fine.)  Without it
>> being variably-located, there will always be a risk of collisions like this.
> 
> For x86 PV (and shadow?) you can establish a mapping of the gnttab from
> a virtual address directly to the machine address without needing a p2m
> entry, via whichever hypercall it is which does that.
> 
> For HAP (and shadow?) you need a p2m mapping to get at the grant table,
> so somewhere has to be found in the physical address space where it can
> go.
> 
> In theory a guest kernel could try and find some io space which it isn't
> using but to help them out we give them a hint.
> 
> For x86 HVM the IOBAR of the platform device as a handy place to put the
> hint, for ARM domU we have a defined region in our address map which we
> use and communicate via device tree.
> 
> But for ARM dom0 the physical address space layout follows the host,
> figuring out a free bit of space is a bit tricky so each platform is
> currently required (except some don't and there is a broken default) to
> say where is a safe place to use (i.e. a person has to read the
> datasheet and figure it out).

Linux x86 PVH dom0 and domU uses ballooned pages and they're vmap()'d in
into a contiguous bit of virtual address space.

Perhaps something similar could be considered for ARM in the future?
This would be common code between ARM and x86 PVH.

David

  reply	other threads:[~2014-09-11 16:51 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-11 15:21 [PATCH] xen: arm: configure correct dom0_gnttab_start/size Ian Campbell
2014-09-11 15:37 ` Ian Campbell
2014-09-11 15:54 ` Andrew Cooper
2014-09-11 16:05   ` Ian Campbell
2014-09-11 16:51     ` David Vrabel [this message]
2014-09-12  9:56       ` Ian Campbell
2014-09-11 20:11 ` Julien Grall
2014-09-12  9:54   ` Ian Campbell
2014-09-12 19:20     ` Julien Grall
2014-11-04 10:17 ` Ian Campbell
2014-11-04 10:20   ` Stefano Stabellini
2014-11-04 12:48     ` Julien Grall
2014-11-04 17:20       ` Konrad Rzeszutek Wilk
2014-11-05 10:59         ` Ian Campbell
2014-11-04 12:46 ` Julien Grall

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=5411D32E.1020101@citrix.com \
    --to=david.vrabel@citrix.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=julien.grall@linaro.org \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=tim@xen.org \
    --cc=xen-devel@lists.xen.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).