xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Paul Durrant <Paul.Durrant@citrix.com>
To: Ross Lagerwall <ross.lagerwall@citrix.com>,
	Xen-devel <xen-devel@lists.xen.org>
Cc: Stefano Stabellini <sstabellini@kernel.org>,
	Wei Liu <wei.liu2@citrix.com>,
	Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>,
	Andrew Cooper <Andrew.Cooper3@citrix.com>,
	"Tim (Xen.org)" <tim@xen.org>,
	George Dunlap <George.Dunlap@citrix.com>,
	Jan Beulich <jbeulich@suse.com>,
	Ian Jackson <Ian.Jackson@citrix.com>
Subject: Re: [PATCH v1 2/5] xen: Provide XEN_DMOP_add_to_physmap
Date: Fri, 20 Oct 2017 10:04:20 +0000	[thread overview]
Message-ID: <1c641a44ec694e09b9de90ed4bdca696@AMSPEX02CL03.citrite.net> (raw)
In-Reply-To: <3956eb00-eeed-73af-c625-f93cea756422@citrix.com>



> -----Original Message-----
> From: Ross Lagerwall [mailto:ross.lagerwall@citrix.com]
> Sent: 20 October 2017 10:37
> To: Paul Durrant <Paul.Durrant@citrix.com>; Xen-devel <xen-
> devel@lists.xen.org>
> Cc: Stefano Stabellini <sstabellini@kernel.org>; Wei Liu
> <wei.liu2@citrix.com>; Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>;
> George Dunlap <George.Dunlap@citrix.com>; Andrew Cooper
> <Andrew.Cooper3@citrix.com>; Ian Jackson <Ian.Jackson@citrix.com>; Tim
> (Xen.org) <tim@xen.org>; Jan Beulich <jbeulich@suse.com>
> Subject: Re: [Xen-devel] [PATCH v1 2/5] xen: Provide
> XEN_DMOP_add_to_physmap
> 
> On 10/20/2017 10:15 AM, Paul Durrant wrote:
> >> -----Original Message-----
> snip>> diff --git a/xen/arch/x86/hvm/dm.c b/xen/arch/x86/hvm/dm.c
> >> index 32ade95..432a863 100644
> >> --- a/xen/arch/x86/hvm/dm.c
> >> +++ b/xen/arch/x86/hvm/dm.c
> >> @@ -640,6 +640,22 @@ static int dm_op(const struct dmop_args
> *op_args)
> >>           break;
> >>       }
> >>
> >> +    case XEN_DMOP_add_to_physmap:
> >> +    {
> >> +        const struct xen_dm_op_add_to_physmap *data =
> >> +            &op.u.add_to_physmap;
> >> +        struct xen_add_to_physmap xatp = {
> >> +            .domid = op_args->domid,
> >> +            .space = XENMAPSPACE_gmfn,
> >> +            .idx = data->idx,
> >> +            .gpfn = data->gpfn,
> >> +        };
> >> +
> >
> > Where does xatp.size get set? Looks like you're missing a parameter.
> >
> xatp.size is only used for XENMAPSPACE_gmfn_range which is not
> supported
> by this interface. size gets set to 0 by the C99 designated initializer.
> 
> Based on your other comments, would it make sense to instead use
> XENMAPSPACE_gmfn_range and have the caller set the size?

Yes... my eyes had read XENMAPSPACE_gmfn_range in the first place, hence my confusion over the size parameter.

> 
> As it is currently, QEMU does only populate VRAM one page at a time
> (using xen_xc_domain_add_to_physmap)

Ouch, yes, I'd forgotten that.

> so it is already slow but it could
> be improved.

Indeed. I think we should shoot for a better semantic given that it's a new op.

  Paul

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

  reply	other threads:[~2017-10-20 10:04 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-18 14:03 [PATCH v1 0/5] Add dmops to allow use of VGA with restricted QEMU Ross Lagerwall
2017-10-18 14:03 ` [PATCH v1 1/5] xen/mm: Make xenmem_add_to_physmap global Ross Lagerwall
2017-10-20  9:09   ` Paul Durrant
2017-10-18 14:03 ` [PATCH v1 2/5] xen: Provide XEN_DMOP_add_to_physmap Ross Lagerwall
2017-10-20  9:15   ` Paul Durrant
2017-10-20  9:20     ` Paul Durrant
2017-10-20  9:36     ` Ross Lagerwall
2017-10-20 10:04       ` Paul Durrant [this message]
2017-10-18 14:03 ` [PATCH v1 3/5] xen: Provide XEN_DMOP_pin_memory_cacheattr Ross Lagerwall
2017-10-20  9:19   ` Paul Durrant
2017-10-18 14:03 ` [PATCH v1 4/5] tools: libxendevicemodel: Provide xendevicemodel_add_to_physmap Ross Lagerwall
2017-10-19 15:00   ` Ian Jackson
2017-10-20  9:22   ` Paul Durrant
2017-10-27 11:45     ` Wei Liu
2017-10-27 12:06       ` Ross Lagerwall
2017-10-18 14:03 ` [PATCH v1 5/5] tools: libxendevicemodel: Provide xendevicemodel_pin_memory_cacheattr Ross Lagerwall
2017-10-19 15:01   ` Ian Jackson
2017-10-20  9:23   ` Paul Durrant

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=1c641a44ec694e09b9de90ed4bdca696@AMSPEX02CL03.citrite.net \
    --to=paul.durrant@citrix.com \
    --cc=Andrew.Cooper3@citrix.com \
    --cc=George.Dunlap@citrix.com \
    --cc=Ian.Jackson@citrix.com \
    --cc=jbeulich@suse.com \
    --cc=konrad.wilk@oracle.com \
    --cc=ross.lagerwall@citrix.com \
    --cc=sstabellini@kernel.org \
    --cc=tim@xen.org \
    --cc=wei.liu2@citrix.com \
    --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).