All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Vrabel <david.vrabel@citrix.com>
To: "Tian, Kevin" <kevin.tian@intel.com>, Tim Deegan <tim@xen.org>
Cc: "keir@xen.org" <keir@xen.org>,
	"Xen-devel@lists.xen.org" <Xen-devel@lists.xen.org>,
	"Paul.Durrant@citrix.com" <Paul.Durrant@citrix.com>,
	"Yu, Zhang" <yu.c.zhang@linux.intel.com>,
	David Vrabel <david.vrabel@citrix.com>,
	"JBeulich@suse.com" <JBeulich@suse.com>,
	Malcolm Crossley <malcolm.crossley@citrix.com>
Subject: Re: One question about the hypercall to translate gfn to mfn.
Date: Mon, 12 Jan 2015 11:14:32 +0000	[thread overview]
Message-ID: <54B3AC98.7080105@citrix.com> (raw)
In-Reply-To: <AADFC41AFE54684AB9EE6CBC0274A5D126132427@SHSMSX101.ccr.corp.intel.com>

On 09/01/15 08:02, Tian, Kevin wrote:
>> From: Tim Deegan [mailto:tim@xen.org]
>> Sent: Thursday, January 08, 2015 8:43 PM
>>
>> Hi,
>>
>>>> Not really.  The IOMMU tables are also 64-bit so there must be enough
>>>> addresses to map all of RAM.  There shouldn't be any need for these
>>>> mappings to be _contiguous_, btw.  You just need to have one free
>>>> address for each mapping.  Again, following how grant maps work, I'd
>>>> imagine that PVH guests will allocate an unused GFN for each mapping
>>>> and do enough bookkeeping to make sure they don't clash with other GFN
>>>> users (grant mapping, ballooning, &c).  PV guests will probably be
>>>> given a BFN by the hypervisor at map time (which will be == MFN in
>>>> practice) and just needs to pass the same BFN to the unmap call later
>>>> (it can store it in the GTT meanwhile).
>>>
>>> if possible prefer to make both consistent, i.e. always finding unused GFN?
>>
>> I don't think it will be possible.  PV domains are already using BFNs
>> supplied by Xen (in fact == MFN) for backend grant mappings, which
>> would conflict with supplying their own for these mappings.  But
>> again, I think the kernel maintainers for Xen may have a better idea
>> of how these interfaces are used inside the kernel.  For example,
>> it might be easy enough to wrap the two systems inside a common API
>> inside linux.   Again, following how grant mapping works seems like
>> the way forward.
>>
> 
> So Konrad, do you have any insight here? :-)

Malcolm took two pages of this notebook explaining to me how he thought
it should work (in combination with his PV IOMMU work), so I'll let him
explain.

David

  parent reply	other threads:[~2015-01-12 11:14 UTC|newest]

Thread overview: 59+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-09 10:10 One question about the hypercall to translate gfn to mfn Yu, Zhang
2014-12-09 10:19 ` Paul Durrant
2014-12-09 10:37   ` Yu, Zhang
2014-12-09 10:50     ` Jan Beulich
2014-12-10  1:07       ` Tian, Kevin
2014-12-10  8:39         ` Jan Beulich
2014-12-10  8:47           ` Tian, Kevin
2014-12-10  9:16             ` Jan Beulich
2014-12-10  9:51               ` Tian, Kevin
2014-12-10 10:07                 ` Jan Beulich
2014-12-10 11:04                 ` Malcolm Crossley
2014-12-10  8:50           ` Tian, Kevin
2014-12-09 10:51     ` Malcolm Crossley
2014-12-10  1:22       ` Tian, Kevin
2014-12-09 10:38 ` Jan Beulich
2014-12-09 10:46 ` Tim Deegan
2014-12-09 11:05   ` Paul Durrant
2014-12-09 11:11     ` Ian Campbell
2014-12-09 11:17       ` Paul Durrant
2014-12-09 11:23         ` Jan Beulich
2014-12-09 11:28           ` Malcolm Crossley
2014-12-09 11:29         ` Ian Campbell
2014-12-09 11:43           ` Paul Durrant
2014-12-10  1:48             ` Tian, Kevin
2014-12-10 10:11               ` Ian Campbell
2014-12-11  1:50                 ` Tian, Kevin
2014-12-10  1:14   ` Tian, Kevin
2014-12-10 10:36     ` Jan Beulich
2014-12-11  1:45       ` Tian, Kevin
2014-12-10 10:55     ` Tim Deegan
2014-12-11  1:41       ` Tian, Kevin
2014-12-11 16:46         ` Tim Deegan
2014-12-12  7:24           ` Tian, Kevin
2014-12-12 10:54             ` Jan Beulich
2014-12-15  6:25               ` Tian, Kevin
2014-12-15  8:44                 ` Jan Beulich
2014-12-15  9:05                   ` Tian, Kevin
2014-12-15  9:22                     ` Jan Beulich
2014-12-15 11:16                       ` Tian, Kevin
2014-12-15 11:27                         ` Jan Beulich
2014-12-15 15:22                       ` Stefano Stabellini
2014-12-15 16:01                         ` Jan Beulich
2014-12-15 16:15                           ` Stefano Stabellini
2014-12-15 16:28                             ` David Vrabel
2014-12-15 16:28                             ` Jan Beulich
2014-12-18 15:46             ` Tim Deegan
2015-01-06  8:56               ` Tian, Kevin
2015-01-08 12:43                 ` Tim Deegan
2015-01-09  8:02                   ` Tian, Kevin
2015-01-09 20:08                     ` Konrad Rzeszutek Wilk
2015-01-12 11:14                     ` David Vrabel [this message]
2014-12-11 21:29         ` Tim Deegan
2014-12-12  6:29           ` Tian, Kevin
2014-12-18 16:08             ` Tim Deegan
2014-12-18 17:01               ` Andrew Cooper
2015-01-05 15:49             ` George Dunlap
2015-01-06  8:42               ` Tian, Kevin
2015-01-06 10:35                 ` Ian Campbell
2014-12-12  7:30           ` Tian, Kevin

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=54B3AC98.7080105@citrix.com \
    --to=david.vrabel@citrix.com \
    --cc=JBeulich@suse.com \
    --cc=Paul.Durrant@citrix.com \
    --cc=Xen-devel@lists.xen.org \
    --cc=keir@xen.org \
    --cc=kevin.tian@intel.com \
    --cc=malcolm.crossley@citrix.com \
    --cc=tim@xen.org \
    --cc=yu.c.zhang@linux.intel.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 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.