Re: [PATCH 4/5] xen/memory: Fix acquire_resource size semantics

2020-07-31 Thread Andrew Cooper
On 31/07/2020 15:44, Jan Beulich wrote: > On 28.07.2020 13:37, Andrew Cooper wrote: >> @@ -1026,19 +1047,6 @@ static int acquire_resource( >> if ( xmar.pad != 0 ) >> return -EINVAL; >> >> -if ( guest_handle_is_null(xmar.frame_list) ) >> -{ >> -if ( xmar.nr_frames ) >

Re: [PATCH 4/5] xen/memory: Fix acquire_resource size semantics

2020-07-31 Thread Jan Beulich
On 28.07.2020 13:37, Andrew Cooper wrote: > @@ -1026,19 +1047,6 @@ static int acquire_resource( > if ( xmar.pad != 0 ) > return -EINVAL; > > -if ( guest_handle_is_null(xmar.frame_list) ) > -{ > -if ( xmar.nr_frames ) > -return -EINVAL; > - > -xmar

Re: [PATCH 4/5] xen/memory: Fix acquire_resource size semantics

2020-07-31 Thread Jan Beulich
On 30.07.2020 21:46, Andrew Cooper wrote: > On 30/07/2020 09:31, Paul Durrant wrote: >>> From: Xen-devel On Behalf Of >>> Andrew Cooper >>> Sent: 28 July 2020 12:37 >>> >>> --- a/xen/common/grant_table.c >>> +++ b/xen/common/grant_table.c >>> @@ -4013,6 +4013,25 @@ static int gnttab_get_shared_fr

Re: [PATCH 4/5] xen/memory: Fix acquire_resource size semantics

2020-07-30 Thread Julien Grall
Hi Andrew, On 30/07/2020 20:46, Andrew Cooper wrote: On 30/07/2020 09:31, Paul Durrant wrote: In between these two hypercalls from the utility, the guest can do a v1=>v2 or v2=>v1 switch and make the resource spontaneously appear or disappear. This can only happen on platform where grant-table

Re: [PATCH 4/5] xen/memory: Fix acquire_resource size semantics

2020-07-30 Thread Andrew Cooper
On 30/07/2020 13:54, Julien Grall wrote: > Hi Paul, > > On 30/07/2020 09:31, Paul Durrant wrote: >>> diff --git a/xen/common/memory.c b/xen/common/memory.c >>> index dc3a7248e3..21edabf9cc 100644 >>> --- a/xen/common/memory.c >>> +++ b/xen/common/memory.c >>> @@ -1007,6 +1007,26 @@ static long xatp

Re: [PATCH 4/5] xen/memory: Fix acquire_resource size semantics

2020-07-30 Thread Andrew Cooper
On 30/07/2020 09:31, Paul Durrant wrote: >> -Original Message- >> From: Xen-devel On Behalf Of Andrew >> Cooper >> Sent: 28 July 2020 12:37 >> To: Xen-devel >> Cc: Hubert Jasudowicz ; Stefano Stabellini >> ; Julien >> Grall ; Wei Liu ; Konrad Rzeszutek Wilk >> ; George >> Dunlap ; Andr

Re: [PATCH 4/5] xen/memory: Fix acquire_resource size semantics

2020-07-30 Thread Julien Grall
Hi Paul, On 30/07/2020 09:31, Paul Durrant wrote: diff --git a/xen/common/memory.c b/xen/common/memory.c index dc3a7248e3..21edabf9cc 100644 --- a/xen/common/memory.c +++ b/xen/common/memory.c @@ -1007,6 +1007,26 @@ static long xatp_permission_check(struct domain *d, unsigned int space) r

RE: [PATCH 4/5] xen/memory: Fix acquire_resource size semantics

2020-07-30 Thread Paul Durrant
> -Original Message- > From: Xen-devel On Behalf Of Andrew > Cooper > Sent: 28 July 2020 12:37 > To: Xen-devel > Cc: Hubert Jasudowicz ; Stefano Stabellini > ; Julien > Grall ; Wei Liu ; Konrad Rzeszutek Wilk > ; George > Dunlap ; Andrew Cooper > ; Paul Durrant > ; Jan Beulich ; Micha