[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v3 1/3] introduce GFN notification for translated domains



> -----Original Message-----
> From: Jan Beulich <jbeulich@xxxxxxxx>
> Sent: 25 November 2019 10:51
> To: Durrant, Paul <pdurrant@xxxxxxxxxx>
> Cc: xen-devel@xxxxxxxxxxxxxxxxxxxx; Andrew Cooper
> <andrew.cooper3@xxxxxxxxxx>; Ian Jackson <ian.jackson@xxxxxxxxxx>; Roger
> Pau Monné <roger.pau@xxxxxxxxxx>; Sander Eikelenboom
> <linux@xxxxxxxxxxxxxx>; George Dunlap <George.Dunlap@xxxxxxxxxxxxx>;
> Stefano Stabellini <sstabellini@xxxxxxxxxx>; Konrad Wilk
> <konrad.wilk@xxxxxxxxxx>; Juergen Gross <jgross@xxxxxxxx>; Julien Grall
> <julien@xxxxxxx>; Wei Liu <wl@xxxxxxx>
> Subject: Re: [Xen-devel] [PATCH v3 1/3] introduce GFN notification for
> translated domains
> 
> On 25.11.2019 11:37,  Durrant, Paul  wrote:
> >> -----Original Message-----
> >> From: Xen-devel <xen-devel-bounces@xxxxxxxxxxxxxxxxxxxx> On Behalf Of
> Jan
> >> Beulich
> >> Sent: 25 November 2019 09:58
> >>
> >> --- a/xen/arch/x86/hvm/hvm.c
> >> +++ b/xen/arch/x86/hvm/hvm.c
> >> @@ -4304,9 +4304,17 @@ static int hvmop_set_param(
> >>          if ( a.value > SHUTDOWN_MAX )
> >>              rc = -EINVAL;
> >>          break;
> >> +
> >>      case HVM_PARAM_IOREQ_SERVER_PFN:
> >> -        d->arch.hvm.ioreq_gfn.base = a.value;
> >> +        if ( d->arch.hvm.params[HVM_PARAM_NR_IOREQ_SERVER_PAGES] )
> >> +            rc = notify_gfn(
> >> +                     d,
> >> +                     _gfn(a.value + d->arch.hvm.params
> >> +                                    [HVM_PARAM_NR_IOREQ_SERVER_PAGES]
> -
> >> 1));
> >
> > IIRC the PFN is typically set by the toolstack before the number of
> > pages, so the notify will be for a.value - 1, i.e. the previous gfn.
> > Is that a problem?
> 
> There's an if() around the invocation to avoid this situation, so I'm
> afraid I don't understand the question.

D'oh... Missed it. Sorry for the noise.

  Paul

> 
> Jan
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.