Re: [Xen-devel] [PATCH 1/2] argo: warn sendv() caller when ring is full

2019-06-11 Thread Christopher Clark
ions on -EAGAIN and > still be alerted if the pending message fails to requeue. > > Signed-off-by: Nicholas Tsirakis Thanks for the correct identification of the problem and the patch. Reviewed-by: Christopher Clark > --- > xen/common/argo.c | 6 +- > 1 file changed, 5 i

Re: [Xen-devel] [PATCH 2/2] argo: correctly report pending message length

2019-06-11 Thread Christopher Clark
On Tue, Jun 11, 2019 at 10:11 AM Nicholas Tsirakis wrote: > > When a message is requeue'd in Xen's internal queue, the queue > entry contains the length of the message so that Xen knows to > send a VIRQ to the respective domain when enough space frees up > in the ring. Due to a small bug, however,

Re: [Xen-devel] [PATCH 1/2] argo: warn sendv() caller when ring is full

2019-06-11 Thread Christopher Clark
On Tue, Jun 11, 2019 at 12:16 PM Andrew Cooper wrote: > > On 11/06/2019 19:43, Christopher Clark wrote: > > On Tue, Jun 11, 2019 at 10:11 AM Nicholas Tsirakis > > wrote: > >> In its current state, if the destination ring is full, sendv() > >> will requ

Re: [Xen-devel] [PATCH 2/2] argo: correctly report pending message length

2019-06-11 Thread Christopher Clark
On Tue, Jun 11, 2019 at 12:55 PM Nicholas Tsirakis wrote: > > On Tue, Jun 11, 2019 at 2:49 PM Christopher Clark > wrote: > > > > On Tue, Jun 11, 2019 at 10:11 AM Nicholas Tsirakis > > wrote: > > > > > > When a message is requeue'd in Xen&#x

Re: [Xen-devel] [PATCH v2 1/2] argo: warn sendv() caller when ring is full

2019-06-11 Thread Christopher Clark
On Tue, Jun 11, 2019 at 2:14 PM Nicholas Tsirakis wrote: > > In its current state, if the destination ring is full, sendv() > will requeue the message and return the rc of pending_requeue(), > which will return 0 on success. This prevents the caller from > distinguishing the difference between a s

Re: [Xen-devel] [PATCH v2 2/2] argo: correctly report pending message length

2019-06-11 Thread Christopher Clark
On Tue, Jun 11, 2019 at 2:14 PM Nicholas Tsirakis wrote: > > When a message is requeue'd in Xen's internal queue, the queue > entry contains the length of the message so that Xen knows to > send a VIRQ to the respective domain when enough space frees up > in the ring. Due to a small bug, however,

Re: [Xen-devel] [PATCH v3 2/2] argo: correctly report pending message length

2019-06-12 Thread Christopher Clark
iously" > a domain even when the ring doesn't have enough space. > > This patch makes sure that the msg len is properly reported by > populating it in the event of a write failure. > > Signed-off-by: Nicholas Tsirakis Reviewed-by: Christopher Clark > --- > xen/

Re: [Xen-devel] [PATCH 15/25] argo: implement the sendv op

2019-01-04 Thread Christopher Clark
On Thu, Dec 20, 2018 at 12:33 AM Jan Beulich wrote: > > >>> On 20.12.18 at 06:58, wrote: > > On Wed, Dec 12, 2018 at 3:53 AM Jan Beulich wrote: > >> >>> On 01.12.18 at 02:32, wrote: > >> > +static struct argo_ring_info * > >> > +argo_ring_find_info_by_match(const struct domain *d, uint32_t port

[Xen-devel] [PATCH v3 13/15] xsm, argo: XSM control for any access to argo by a domain

2019-01-06 Thread Christopher Clark
Will inhibit initialization of the domain's argo data structure to prevent receiving any messages or notifications and access to any of the argo hypercall operations. Signed-off-by: Christopher Clark --- v2 self: fix xsm use in soft-reset prior to introduction v1 #5 (#17) feedback Paul

[Xen-devel] [PATCH v3 14/15] xsm, argo: notify: don't describe rings that cannot be sent to

2019-01-06 Thread Christopher Clark
Signed-off-by: Christopher Clark --- xen/common/argo.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/xen/common/argo.c b/xen/common/argo.c index 31535bd..0dc064d 100644 --- a/xen/common/argo.c +++ b/xen/common/argo.c @@ -1172,6 +1172,17 @@ fill_ring_data(const struct domain

[Xen-devel] [PATCH v3 02/15] argo: introduce the argo_op hypercall boilerplate

2019-01-06 Thread Christopher Clark
to be integer multiples of 32 bits in size. This means that the same copy_to_guest and copy_from_guest logic can be relied upon to perform as required without any further intervention. Testing communication with 32 and 64 bit guests has confirmed this works as intended. Signed-off-by: Christopher

[Xen-devel] [PATCH v3 06/15] xen/arm: introduce guest_handle_for_field()

2019-01-06 Thread Christopher Clark
ARM port of c/s bb544585: "introduce guest_handle_for_field()" This helper turns a field of a GUEST_HANDLE into a GUEST_HANDLE. Signed-off-by: Christopher Clark Reviewed-by: Paul Durrant --- xen/include/asm-arm/guest_access.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/x

[Xen-devel] [PATCH v3 15/15] argo: validate hypercall arg structures via compat machinery

2019-01-06 Thread Christopher Clark
structures; the coverage of offset of elements is still retained. Signed-off-by: Christopher Clark --- xen/common/Makefile | 2 +- xen/common/compat/argo.c | 61 2 files changed, 62 insertions(+), 1 deletion(-) create mode 100644 xen/com

[Xen-devel] [PATCH v3 03/15] argo: define argo_dprintk for subsystem debugging

2019-01-06 Thread Christopher Clark
A convenience for working on development of the argo subsystem: setting a #define variable enables additional debug messages. Signed-off-by: Christopher Clark --- v2 #03 feedback, Jan: fix ifdef/define confusion error v1 #04 feedback, Jan: fix dprintk implementation xen/common/argo.c | 9

[Xen-devel] [PATCH v3 12/15] xsm, argo: XSM control for argo message send operation

2019-01-06 Thread Christopher Clark
Default policy: allow. Signed-off-by: Christopher Clark --- v2: reordered commit sequence to after sendv implementation v1 feedback Jan #16: apply const to function signatures v1 version was: Reviewed-by: Paul Durrant xen/common/argo.c | 8 xen/include/xsm/dummy.h

[Xen-devel] [PATCH v3 00/15] Argo: hypervisor-mediated interdomain communication

2019-01-06 Thread Christopher Clark
via fixed constant value fields removed. Christopher Clark (15): argo: Introduce the Kconfig option to govern inclusion of Argo argo: introduce the argo_op hypercall boilerplate argo: define argo_dprintk for subsystem debugging argo: init, destroy and soft-reset, with enable command line opt

[Xen-devel] [PATCH v3 08/15] argo: implement the unregister op

2019-01-06 Thread Christopher Clark
ress space. If the ring had been registered to communicate with a single specified domain (ie. a non-wildcard ring) then the partner domain state is removed from the partner domain's argo send_info hash table. Signed-off-by: Christopher Clark --- v2 feedback Jan: drop cookie, implement teard

[Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-06 Thread Christopher Clark
e files in question is fully owned by Citrix. The ACK also confirms that Citrix is happy for the header files to be published under a BSD license in this series (which is based on [1]). Signed-off-by: Christopher Clark Acked-by: Lars Kurth --- v2 rewrite locking explanation comment v2 header copy

[Xen-devel] [PATCH v3 01/15] argo: Introduce the Kconfig option to govern inclusion of Argo

2019-01-06 Thread Christopher Clark
option depends on EXPERT and Argo is currently an experimental feature. Signed-off-by: Christopher Clark --- v2 #01 feedback, Jan: replace def_bool/prompt with bool v1 #02 feedback, Jan: default Kconfig off, use EXPERT, fix whitespace xen/common/Kconfig | 19 +++ 1 file changed

[Xen-devel] [PATCH v3 09/15] argo: implement the sendv op; evtchn: expose send_guest_global_virq

2019-01-06 Thread Christopher Clark
termine which event channel notifications will be delivered on. This is also likely to simplify establishing future L0/L1 nested hypervisor argo communication. Signed-off-by: Christopher Clark --- The previous double-read of iovs from guest memory has been removed. v2 self: use ring_info b

[Xen-devel] [PATCH v3 10/15] argo: implement the notify op

2019-01-06 Thread Christopher Clark
quent notifications. Limit the maximum number of notify requests in a single operation to a simple fixed limit of 256. Signed-off-by: Christopher Clark --- v2 feedback Jan: drop cookie, implement teardown v2 notify: add flag to indicate ring is shared v2 argument name for fill_ring_data arg i

[Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-06 Thread Christopher Clark
the guest just before being used as an array index. Signed-off-by: Christopher Clark --- v2 self: disallow ring resize via reregister v2 feedback Jan: drop cookie, implement teardown v2 feedback Jan: drop message from argo_message_op v2 self: move hash_index function below locking comment v2 se

[Xen-devel] [PATCH v3 11/15] xsm, argo: XSM control for argo register

2019-01-06 Thread Christopher Clark
, which will allow or deny registration of any-sender rings. This commit modifies the signature of core XSM hook functions in order to apply 'const' to arguments, needed in order for 'const' to be accepted in signature of functions that invoke them. Signed-off-by: Chris

[Xen-devel] [PATCH v3 05/15] errno: add POSIX error codes EMSGSIZE, ECONNREFUSED to the ABI

2019-01-06 Thread Christopher Clark
EMSGSIZE : "Message too large" ECONNREFUSED : "Connection refused". The numeric values assigned to each are taken from Linux, as is the case for the existing error codes. EMSGSIZE : 90 ECONNREFUSED : 111 Signed-off-by: Christopher Clark Acked-by: Jan Beulich ---

Re: [Xen-devel] [PATCH 15/25] argo: implement the sendv op

2019-01-07 Thread Christopher Clark
On Fri, Jan 4, 2019 at 5:37 AM Jan Beulich wrote: > > >>> On 04.01.19 at 09:13, wrote: > > ok, I'm at the point where I'm close to having a version three of the > > series to post that addresses all the feedback so far, plus some > > additional improvements, with the following two items remaining

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-08 Thread Christopher Clark
On Tue, Jan 8, 2019 at 2:09 PM Ross Philipson wrote: > > On 01/07/2019 02:42 AM, Christopher Clark wrote: > > Initialises basic data structures and performs teardown of argo state > > for domain shutdown. > > > > Inclusion of the Argo implementation is dependent on C

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-08 Thread Christopher Clark
On Tue, Jan 8, 2019 at 2:54 PM Jason Andryuk wrote: > > On Mon, Jan 7, 2019 at 2:43 AM Christopher Clark > wrote: > > > > Initialises basic data structures and performs teardown of argo state > > for domain shutdown. > > > > Inclusion of the Argo imp

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-09 Thread Christopher Clark
On Wed, Jan 9, 2019 at 7:56 AM Wei Liu wrote: > > On Sun, Jan 06, 2019 at 11:42:40PM -0800, Christopher Clark wrote: > > The register op is used by a domain to register a region of memory for > > receiving messages from either a specified other domain, or, if specifying a > &

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-09 Thread Christopher Clark
On Wed, Jan 9, 2019 at 10:14 AM Julien Grall wrote: > On Wed, 9 Jan 2019, 12:18 Stefano Stabellini, wrote: >> On Wed, 9 Jan 2019, Julien Grall wrote: >> > Hi, >> > Sorry for the formatting. Sending it from my phone. >> > >> > On Wed, 9 Ja

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-09 Thread Christopher Clark
On Wed, Jan 9, 2019 at 10:28 AM Julien Grall wrote: > > > > On Wed, 9 Jan 2019, 12:54 Wei Liu, wrote: >> >> On Wed, Jan 09, 2019 at 12:02:34PM -0500, Julien Grall wrote: >> > Hi, >> > >> > Sorry for the formatting. Sending it from my phone. &g

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-09 Thread Christopher Clark
On Wed, Jan 9, 2019 at 6:16 AM Jason Andryuk wrote: > On Wed, Jan 9, 2019 at 1:48 AM Christopher Clark > wrote: > > On Tue, Jan 8, 2019 at 2:54 PM Jason Andryuk wrote: > > > On Mon, Jan 7, 2019 at 2:43 AM Christopher Clark > > > wrote: > > > > >

Re: [Xen-devel] [PATCH v3 09/15] argo: implement the sendv op; evtchn: expose send_guest_global_virq

2019-01-09 Thread Christopher Clark
On Wed, Jan 9, 2019 at 10:05 AM Jason Andryuk wrote: > > On Mon, Jan 7, 2019 at 2:43 AM Christopher Clark > wrote: > > > > > @@ -342,6 +357,413 @@ update_tx_ptr(struct argo_ring_info *ring_info, > > uint32_t tx_ptr) > > smp_wmb(); > > } >

Re: [Xen-devel] [PATCH v3 09/15] argo: implement the sendv op; evtchn: expose send_guest_global_virq

2019-01-09 Thread Christopher Clark
Thanks for the review, Roger. Replies inline below. On Wed, Jan 9, 2019 at 10:57 AM Roger Pau Monné wrote: > > to.On Mon, Jan 7, 2019 at 8:44 AM Christopher Clark > wrote: > > > > sendv operation is invoked to perform a synchronous send of buffers > > contained i

Re: [Xen-devel] [PATCH v3 11/15] xsm, argo: XSM control for argo register

2019-01-09 Thread Christopher Clark
On Mon, Jan 7, 2019 at 3:07 PM DeGraaf, Daniel G wrote: > > > From: Christopher Clark > > Subject: [PATCH v3 11/15] xsm, argo: XSM control for argo register > > > > XSM controls for argo ring registration with two distinct cases, where > > the ring being regist

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-10 Thread Christopher Clark
On Wed, Jan 9, 2019 at 6:38 AM Jan Beulich wrote: > > >>> On 09.01.19 at 15:26, wrote: > > On Wed, Jan 9, 2019 at 4:35 AM Jan Beulich wrote: > >> >>> On 08.01.19 at 23:54, wrote: > >> > On Mon, Jan 7, 2019 at 2:43 AM Christopher Clark

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-10 Thread Christopher Clark
On Thu, Jan 10, 2019 at 2:19 AM Roger Pau Monné wrote: > > On Mon, Jan 7, 2019 at 8:44 AM Christopher Clark > wrote: > > > > Initialises basic data structures and performs teardown of argo state > > for domain shutdown. > > diff --git a/xen/common/argo.c b/xe

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-10 Thread Christopher Clark
On Thu, Jan 10, 2019 at 8:16 AM Eric Chanudet wrote: > > On 06/01/19 at 11:42pm, Christopher Clark wrote: > >+partner_rings_remove(struct domain *src_d) > > >+ring_info = ring_find_info(dst_d, &send_info->id); > ring_find_info is defined later (PATC

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-10 Thread Christopher Clark
On Thu, Jan 10, 2019 at 12:11 PM Eric Chanudet wrote: > > On 06/01/19 at 11:42pm, Christopher Clark wrote: > >+/* > >+ * The maximum size of an Argo ring is defined to be: 16GB > >+ * -- which is 0x100 bytes. > >+ * A byte index into the ring is at mos

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-10 Thread Christopher Clark
On Thu, Jan 10, 2019 at 3:25 AM Roger Pau Monné wrote: > > On Mon, Jan 7, 2019 at 8:44 AM Christopher Clark > wrote: > > > > The register op is used by a domain to register a region of memory for > > receiving messages from either a specified other domain, or, if spe

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-10 Thread Christopher Clark
On Thu, Jan 10, 2019 at 3:57 AM Jan Beulich wrote: > > >>> On 10.01.19 at 12:24, wrote: > > On Mon, Jan 7, 2019 at 8:44 AM Christopher Clark > > wrote: > >> +static long > >> +register_ring(struct domain *currd, > > > > If this is

Re: [Xen-devel] [PATCH v3 09/15] argo: implement the sendv op; evtchn: expose send_guest_global_virq

2019-01-10 Thread Christopher Clark
On Thu, Jan 10, 2019 at 4:53 AM Jan Beulich wrote: > > >>> On 10.01.19 at 13:40, wrote: > > On Thu, Jan 10, 2019 at 1:13 PM Jan Beulich wrote: > >> > >> >>> On 10.01.19 at 13:01, wrote: > >> > On Thu, Jan 10, 2019 at 4:10 AM Christ

Re: [Xen-devel] [PATCH v3 09/15] argo: implement the sendv op; evtchn: expose send_guest_global_virq

2019-01-10 Thread Christopher Clark
On Thu, Jan 10, 2019 at 1:41 PM Eric Chanudet wrote: > > On 06/01/19 at 11:42pm, Christopher Clark wrote: > >+memcpy_to_guest_ring(struct argo_ring_info *ring_info, uint32_t offset, > >+ const void *src, XEN_GUEST_HANDLE(uint8_t) src_hnd, > >+

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-14 Thread Christopher Clark
On Fri, Jan 11, 2019 at 1:27 AM Roger Pau Monné wrote: > On Fri, Jan 11, 2019 at 7:04 AM Christopher Clark > wrote: > > > > On Thu, Jan 10, 2019 at 2:19 AM Roger Pau Monné wrote: > > > > > > On Mon, Jan 7, 2019 at 8:44 AM Christopher Clark > > &g

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-14 Thread Christopher Clark
On Fri, Jan 11, 2019 at 3:54 AM Jan Beulich wrote: > > >>> On 07.01.19 at 08:42, wrote: > > --- a/xen/common/argo.c > > +++ b/xen/common/argo.c > > @@ -17,7 +17,177 @@ > > */ > > > > #include > > +#include > > +#include > > +#include > > +#include > > +#include > > #include > > +#inclu

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-14 Thread Christopher Clark
On Mon, Jan 14, 2019 at 6:47 AM Wei Liu wrote: > > Hi all > > The locking scheme seems to be remaining sticking point. The rest are > mostly cosmetic issues (FAOD, they still need to be addressed). Frankly > I don't think there is enough time to address all the technical details, > but let me sum

Re: [Xen-devel] [PATCH v3 10/15] argo: implement the notify op

2019-01-14 Thread Christopher Clark
On Thu, Jan 10, 2019 at 4:22 AM Roger Pau Monné wrote: > > On Mon, Jan 7, 2019 at 8:44 AM Christopher Clark > wrote: > > > > Queries for data about space availability in registered rings and > > causes notification to be sent when space has become available. > >

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-14 Thread Christopher Clark
On Mon, Jan 14, 2019 at 6:58 AM Andrew Cooper wrote: > > On 07/01/2019 07:42, Christopher Clark wrote: > > Initialises basic data structures and performs teardown of argo state > > for domain shutdown. > > > > Inclusion of the Argo implementation is dependent on CON

Re: [Xen-devel] [PATCH v3 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-14 Thread Christopher Clark
On Mon, Jan 14, 2019 at 7:12 AM Jan Beulich wrote: > > >>> On 14.01.19 at 15:58, wrote: > > On 07/01/2019 07:42, Christopher Clark wrote: > >> --- a/xen/common/argo.c > >> +++ b/xen/common/argo.c > >> long > >> do_argo_op(unsigned int c

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-14 Thread Christopher Clark
On Mon, Jan 14, 2019 at 6:19 AM Jan Beulich wrote: > > >>> On 07.01.19 at 08:42, wrote: > > --- a/xen/common/argo.c > > +++ b/xen/common/argo.c > > @@ -23,16 +23,41 @@ > > #include > > #include > > #include > > +#include > > +#include > > #include > > #include > > > > +#define MAX_RIN

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-15 Thread Christopher Clark
On Mon, Jan 14, 2019 at 7:31 AM Andrew Cooper wrote: > > On 07/01/2019 07:42, Christopher Clark wrote: > > diff --git a/docs/misc/xen-command-line.pandoc > > b/docs/misc/xen-command-line.pandoc > > index aea13eb..68d4415 100644 > > --- a/docs/misc/xen-command-line.

Re: [Xen-devel] [PATCH v3 08/15] argo: implement the unregister op

2019-01-15 Thread Christopher Clark
On Thu, Jan 10, 2019 at 3:40 AM Roger Pau Monné wrote: > > On Mon, Jan 7, 2019 at 8:44 AM Christopher Clark > wrote: > > > > Takes a single argument: a handle to the ring unregistration struct, > > which specifies the port and partner domain id or wildcard. > >

Re: [Xen-devel] [PATCH v3 08/15] argo: implement the unregister op

2019-01-15 Thread Christopher Clark
On Mon, Jan 14, 2019 at 7:06 AM Jan Beulich wrote: > > >>> On 07.01.19 at 08:42, wrote: > > @@ -666,6 +667,105 @@ ring_find_info(const struct domain *d, const struct > > argo_ring_id *id) > > return NULL; > > } > > > > +static struct argo_send_info * > > +send_find_info(const struct domain

Re: [Xen-devel] [PATCH v3 10/15] argo: implement the notify op

2019-01-15 Thread Christopher Clark
On Tue, Jan 15, 2019 at 12:06 AM Roger Pau Monné wrote: > > On Mon, Jan 14, 2019 at 10:53:54PM -0800, Christopher Clark wrote: > > On Thu, Jan 10, 2019 at 4:22 AM Roger Pau Monné wrote: > > > > > > On Mon, Jan 7, 2019 at 8:44 AM

Re: [Xen-devel] [PATCH v3 07/15] argo: implement the register op

2019-01-15 Thread Christopher Clark
On Tue, Jan 15, 2019 at 12:36 AM Jan Beulich wrote: > > >>> On 15.01.19 at 08:56, wrote: > > On Mon, Jan 14, 2019 at 6:19 AM Jan Beulich wrote: > >> >>> On 07.01.19 at 08:42, wrote: > >> > +/* > >> > + * A ring must be large enough to transmit messages, so requires > >> > space for: >

[Xen-devel] [PATCH v4 02/14] argo: introduce the argo_op hypercall boilerplate

2019-01-15 Thread Christopher Clark
to be integer multiples of 32 bits in size. This means that the same copy_to_guest and copy_from_guest logic can be relied upon to perform as required without any further intervention. Testing communication with 32 and 64 bit guests has confirmed this works as intended. Signed-off-by: Christopher

[Xen-devel] [PATCH v4 03/14] argo: define argo_dprintk for subsystem debugging

2019-01-15 Thread Christopher Clark
A convenience for working on development of the argo subsystem: setting a #define variable enables additional debug messages. Signed-off-by: Christopher Clark Acked-by: Jan Beulich Reviewed-by: Roger Pau Monné --- v3 added Roger's Reviewed-by v3 added Jan's Ack v2 #03 feedback, Jan:

[Xen-devel] [PATCH v4 00/14] Argo: hypervisor-mediated interdomain communication

2019-01-15 Thread Christopher Clark
remaining to be addressed have been noted with comments in the commit message and at the location in the code. Christopher Clark (14): argo: Introduce the Kconfig option to govern inclusion of Argo argo: introduce the argo_op hypercall boilerplate argo: define argo_dprintk for subsystem debugging

[Xen-devel] [PATCH v4 01/14] argo: Introduce the Kconfig option to govern inclusion of Argo

2019-01-15 Thread Christopher Clark
option depends on EXPERT and Argo is currently an experimental feature. Signed-off-by: Christopher Clark Acked-by: Jan Beulich --- (Jan's ack applies for committing together with at least one patch using the CONFIG_ARGO symbol.) v3 added Jan's Ack v2 #01 feedback, Jan: replace def_b

[Xen-devel] [PATCH v4 11/14] xsm, argo: XSM control for argo register

2019-01-15 Thread Christopher Clark
, which will allow or deny registration of any-sender rings. This commit modifies the signature of core XSM hook functions in order to apply 'const' to arguments, needed in order for 'const' to be accepted in signature of functions that invoke them. Signed-off-by: Christo

[Xen-devel] [PATCH v4 14/14] xsm, argo: notify: don't describe rings that cannot be sent to

2019-01-15 Thread Christopher Clark
Signed-off-by: Christopher Clark Acked-by: Daniel De Graaf --- v3 #10 Roger: drop out label, use return -EFAULT in fill_ring_data v3: Add Daniel's Acked-by xen/common/argo.c | 12 1 file changed, 12 insertions(+) diff --git a/xen/common/argo.c b/xen/common/argo.c index 23

[Xen-devel] [PATCH v4 04/14] argo: init, destroy and soft-reset, with enable command line opt

2019-01-15 Thread Christopher Clark
ader files to be published under a BSD license in this series (which is based on [1]). Signed-off-by: Christopher Clark Acked-by: Lars Kurth Reviewed-by: Ross Philipson This version contains FIXMEs for 4.12: * Replace the hash function to get better distribution across buckets. - Don'

[Xen-devel] [PATCH v4 06/14] xen/arm: introduce guest_handle_for_field()

2019-01-15 Thread Christopher Clark
ARM port of c/s bb544585: "introduce guest_handle_for_field()" This helper turns a field of a GUEST_HANDLE into a GUEST_HANDLE. Signed-off-by: Christopher Clark Reviewed-by: Paul Durrant Reviewed-by: Stefano Stabellini --- v3: Added Stefano's Reviewed-by v2: Added Paul'

[Xen-devel] [PATCH v4 13/14] xsm, argo: XSM control for any access to argo by a domain

2019-01-15 Thread Christopher Clark
Will inhibit initialization of the domain's argo data structure to prevent receiving any messages or notifications and access to any of the argo hypercall operations. Signed-off-by: Christopher Clark Acked-by: Daniel De Graaf --- v3 Daniel/Jan: add to the default xsm policy for enable v

[Xen-devel] [PATCH v4 07/14] argo: implement the register op

2019-01-15 Thread Christopher Clark
of the ring id hash function. This is out of an abundance of caution, since this is a very basic hash function and it operates upon values supplied by the guest just before being used as an array index. Signed-off-by: Christopher Clark -This version contains FIXMEs for 4.12: * find_ring_m

[Xen-devel] [PATCH v4 09/14] argo: implement the sendv op; evtchn: expose send_guest_global_virq

2019-01-15 Thread Christopher Clark
termine which event channel notifications will be delivered on. This is also likely to simplify establishing future L0/L1 nested hypervisor argo communication. Signed-off-by: Christopher Clark --- v3 #07 Jan: rename ring_find_info* to find_ring_info* v3 #07 Jan: fix numeric entries in printk form

[Xen-devel] [PATCH v4 10/14] argo: implement the notify op

2019-01-15 Thread Christopher Clark
k and consequent notifications. Limit the maximum number of notify requests in a single operation to a simple fixed limit of 256. Signed-off-by: Christopher Clark --- v3 #07 Jan: fix format string indention in printks v3 (general) Jan: drop fixed width types for ringbuf_payload_space v3 #07 Jan: r

[Xen-devel] [PATCH v4 05/14] errno: add POSIX error codes EMSGSIZE, ECONNREFUSED to the ABI

2019-01-15 Thread Christopher Clark
EMSGSIZE : "Message too large" ECONNREFUSED : "Connection refused". The numeric values assigned to each are taken from Linux, as is the case for the existing error codes. EMSGSIZE : 90 ECONNREFUSED : 111 Signed-off-by: Christopher Clark Acked-by: Jan Beulich ---

[Xen-devel] [PATCH v4 12/14] xsm, argo: XSM control for argo message send operation

2019-01-15 Thread Christopher Clark
Default policy: allow. Signed-off-by: Christopher Clark Reviewed-by: Paul Durrant Acked-by: Daniel De Graaf --- v3 Daniel/Jan: add to the default xsm policy for the send op v3 Add Daniel's Acked-by v2: reordered commit sequence to after sendv implementation v1 feedback Jan #16: apply con

[Xen-devel] [PATCH v4 08/14] argo: implement the unregister op

2019-01-15 Thread Christopher Clark
ress space. If the ring had been registered to communicate with a single specified domain (ie. a non-wildcard ring) then the partner domain state is removed from the partner domain's argo send_info hash table. Signed-off-by: Christopher Clark --- v3 #08 Jan: pull xfree out of exclusive criti

Re: [Xen-devel] [PATCH v4 07/14] argo: implement the register op

2019-01-15 Thread Christopher Clark
On Tue, Jan 15, 2019 at 6:41 AM Roger Pau Monné wrote: > > On Tue, Jan 15, 2019 at 01:27:39AM -0800, Christopher Clark wrote: > > The register op is used by a domain to register a region of memory for > > receiving messages from either a specified other domain, or, if specify

Re: [Xen-devel] [PATCH v4 00/14] Argo: hypervisor-mediated interdomain communication

2019-01-15 Thread Christopher Clark
On Tue, Jan 15, 2019 at 8:34 AM Roger Pau Monné wrote: > > On Tue, Jan 15, 2019 at 01:27:32AM -0800, Christopher Clark wrote: > > Version four of this patch series. > > > > * Changes are primarily addressing feedback from the v3 series reviews. > > Many points

Re: [Xen-devel] [PATCH v4 04/14] argo: init, destroy and soft-reset, with enable command line opt

2019-01-15 Thread Christopher Clark
On Tue, Jan 15, 2019 at 4:29 AM Roger Pau Monné wrote: > > On Tue, Jan 15, 2019 at 01:27:36AM -0800, Christopher Clark wrote: > > Initialises basic data structures and performs teardown of argo state > > for domain shutdown. > > + > > +/* > > + * The value of

Re: [Xen-devel] [PATCH v4 08/14] argo: implement the unregister op

2019-01-16 Thread Christopher Clark
On Tue, Jan 15, 2019 at 7:07 AM Roger Pau Monné wrote: > > On Tue, Jan 15, 2019 at 01:27:40AM -0800, Christopher Clark wrote: > > Takes a single argument: a handle to the ring unregistration struct, > > which specifies the port and partner domain id or wildcard. > >

Re: [Xen-devel] [PATCH v4 09/14] argo: implement the sendv op; evtchn: expose send_guest_global_virq

2019-01-16 Thread Christopher Clark
On Tue, Jan 15, 2019 at 7:49 AM Roger Pau Monné wrote: > > On Tue, Jan 15, 2019 at 01:27:41AM -0800, Christopher Clark wrote: > > sendv operation is invoked to perform a synchronous send of buffers > > contained in iovs to a remote domain's registered ring. > > >

Re: [Xen-devel] [PATCH v4 10/14] argo: implement the notify op

2019-01-16 Thread Christopher Clark
On Tue, Jan 15, 2019 at 8:19 AM Roger Pau Monné wrote: > > On Tue, Jan 15, 2019 at 01:27:42AM -0800, Christopher Clark wrote: > > Queries for data about space availability in registered rings and > > causes notification to be sent when space has become available. > &

Re: [Xen-devel] [PATCH v3 15/15] argo: validate hypercall arg structures via compat machinery

2019-01-16 Thread Christopher Clark
On Mon, Jan 14, 2019 at 4:57 AM Jan Beulich wrote: > > >>> On 07.01.19 at 08:42, wrote: > > Argo doesn't use compat hypercall or argument translation but can use some > > of the infrastructure for validating the hypercall argument structures to > > ensure that the struct sizes, offsets and compos

Re: [Xen-devel] [PATCH v4 10/14] argo: implement the notify op

2019-01-17 Thread Christopher Clark
On Thu, Jan 17, 2019 at 3:12 AM Roger Pau Monné wrote: > > On Wed, Jan 16, 2019 at 10:54:48PM -0800, Christopher Clark wrote: > > On Tue, Jan 15, 2019 at 8:19 AM Roger Pau Monné > > wrote: > > > > > > On Tue, Jan 15, 2019 at 01:27:42AM -0800, Christopher C

Re: [Xen-devel] [PATCH v4 10/14] argo: implement the notify op

2019-01-18 Thread Christopher Clark
On Fri, Jan 18, 2019 at 1:44 AM Roger Pau Monné wrote: > > On Thu, Jan 17, 2019 at 01:44:32PM -0800, Christopher Clark wrote: > > On Thu, Jan 17, 2019 at 3:12 AM Roger Pau Monné > > wrote: > > > > > > On Wed, Jan 16, 2019 at 10:54:48PM -0800, Christopher

Re: [Xen-devel] [PATCH v4 10/14] argo: implement the notify op

2019-01-18 Thread Christopher Clark
On Fri, Jan 18, 2019 at 3:54 PM Christopher Clark wrote: > > On Fri, Jan 18, 2019 at 1:44 AM Roger Pau Monné wrote: > > > > On Thu, Jan 17, 2019 at 01:44:32PM -0800, Christopher Clark wrote: > > > On Thu, Jan 17, 2019 at 3:12 AM Roger Pau Monné > > > wrote:

Re: [Xen-devel] [PATCH v3 15/15] argo: validate hypercall arg structures via compat machinery

2019-01-20 Thread Christopher Clark
On Thu, Jan 17, 2019 at 3:25 AM Jan Beulich wrote: > > >>> On 17.01.19 at 08:22, wrote: > > Some details of the problem: > > > > Without the macro overrides in place (ie. using the existing > > definitions) the build fails on CHECK_argo_send_addr because this > > struct is defined with types tha

Re: [Xen-devel] [PATCH v4 10/14] argo: implement the notify op

2019-01-20 Thread Christopher Clark
On Sat, Jan 19, 2019 at 4:06 AM Roger Pau Monné wrote: > > On Fri, Jan 18, 2019 at 03:54:14PM -0800, Christopher Clark wrote: > > On Fri, Jan 18, 2019 at 1:44 AM Roger Pau Monné > > wrote: > > > > > > On Thu, Jan 17, 2019 at 01:44:32PM -0800, Christopher

[Xen-devel] [PATCH v5 15/15] MAINTAINERS: add new section for Argo and self as maintainer

2019-01-21 Thread Christopher Clark
Signed-off-by: Christopher Clark --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 96a0518..c4f5316 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -158,6 +158,14 @@ S: Supported F: xen/arch/x86/hvm/svm/ F: xen/arch/x86/cpu

[Xen-devel] [PATCH v5 00/15] Argo: hypervisor-mediated interdomain communication

2019-01-21 Thread Christopher Clark
rings - command line doc edit: no "CONFIG_ARGO" but refers to build config * Switched to use the standard list data structures used by Xen's common code. * Further removal of uses of fixed-width types. * Added a new patch to add Argo to the MAINTAINERS file. Christopher Cla

[Xen-devel] [PATCH v5 06/15] xen/arm: introduce guest_handle_for_field()

2019-01-21 Thread Christopher Clark
ARM port of c/s bb544585: "introduce guest_handle_for_field()" This helper turns a field of a GUEST_HANDLE into a GUEST_HANDLE. Signed-off-by: Christopher Clark Reviewed-by: Paul Durrant Reviewed-by: Stefano Stabellini --- v3: Added Stefano's Reviewed-by v2: Added Paul'

[Xen-devel] [PATCH v5 01/15] argo: Introduce the Kconfig option to govern inclusion of Argo

2019-01-21 Thread Christopher Clark
option depends on EXPERT and Argo is currently an experimental feature. Signed-off-by: Christopher Clark Acked-by: Jan Beulich --- v3 added Jan's Ack v2 #01 feedback, Jan: replace def_bool/prompt with bool v1 #02 feedback, Jan: default Kconfig off, use EXPERT, fix whitespace xen/common/Kc

[Xen-devel] [PATCH v5 03/15] argo: define argo_dprintk for subsystem debugging

2019-01-21 Thread Christopher Clark
A convenience for working on development of the argo subsystem: setting a #define variable enables additional debug messages. Signed-off-by: Christopher Clark Acked-by: Jan Beulich Reviewed-by: Roger Pau Monné --- v3 added Roger's Reviewed-by v3 added Jan's Ack v2 #03 feedback, Jan:

[Xen-devel] [PATCH v5 02/15] argo: introduce the argo_op hypercall boilerplate

2019-01-21 Thread Christopher Clark
to be integer multiples of 32 bits in size. This means that the same copy_to_guest and copy_from_guest logic can be relied upon to perform as required without any further intervention. Testing communication with 32 and 64 bit guests has confirmed this works as intended. Signed-off-by: Christopher

[Xen-devel] [PATCH v5 04/15] argo: init, destroy and soft-reset, with enable command line opt

2019-01-21 Thread Christopher Clark
se in this series (which is based on [1]). Signed-off-by: Christopher Clark Acked-by: Lars Kurth Reviewed-by: Ross Philipson --- v4 Jan: amend the command line doc text referring to build configuration v4 feedback: use standard data structures as per common code v4 Jan: replace hash_index with dj

[Xen-devel] [PATCH v5 10/15] argo: implement the notify op

2019-01-21 Thread Christopher Clark
quent notifications. Limit the maximum number of notify requests in a single operation to a simple fixed limit of 256. Signed-off-by: Christopher Clark --- v4 #10 Roger: consolidate notify flags; infer pending notify if needed v4 bugfix: take L3 before accessing ring_info in fill_ring_data v

[Xen-devel] [PATCH v5 13/15] xsm, argo: XSM control for any access to argo by a domain

2019-01-21 Thread Christopher Clark
Will inhibit initialization of the domain's argo data structure to prevent receiving any messages or notifications and access to any of the argo hypercall operations. Signed-off-by: Christopher Clark Acked-by: Daniel De Graaf --- v3 Daniel/Jan: add to the default xsm policy for enable v

[Xen-devel] [PATCH v5 11/15] xsm, argo: XSM control for argo register

2019-01-21 Thread Christopher Clark
d in order for 'const' to be accepted in signature of functions that invoke them. Signed-off-by: Christopher Clark Acked-by: Daniel De Graaf --- v3 Daniel/Jan: add to the default xsm policy for the register op v3 hoist opt_argo_mac_permissive check to allow default policy to match non-

[Xen-devel] [PATCH v5 07/15] argo: implement the register op

2019-01-21 Thread Christopher Clark
late hypercall args. This hypercall op and its interface currently only supports 4K-sized pages. Signed-off-by: Christopher Clark --- v4 v3#07 Jan: shrink critical sections in register_ring v4 v3#07 Jan: revise register flag MASK in header, note 32-bitness of args v4 feedback: use standard data s

[Xen-devel] [PATCH v5 05/15] errno: add POSIX error codes EMSGSIZE, ECONNREFUSED to the ABI

2019-01-21 Thread Christopher Clark
EMSGSIZE : "Message too large" ECONNREFUSED : "Connection refused". The numeric values assigned to each are taken from Linux, as is the case for the existing error codes. EMSGSIZE : 90 ECONNREFUSED : 111 Signed-off-by: Christopher Clark Acked-by: Jan Beulich ---

[Xen-devel] [PATCH v5 12/15] xsm, argo: XSM control for argo message send operation

2019-01-21 Thread Christopher Clark
Default policy: allow. Signed-off-by: Christopher Clark Reviewed-by: Paul Durrant Acked-by: Daniel De Graaf --- v3 Daniel/Jan: add to the default xsm policy for the send op v3 Add Daniel's Acked-by v2: reordered commit sequence to after sendv implementation v1 feedback Jan #16: apply con

[Xen-devel] [PATCH v5 08/15] argo: implement the unregister op

2019-01-21 Thread Christopher Clark
ress space. If the ring had been registered to communicate with a single specified domain (ie. a non-wildcard ring) then the partner domain state is removed from the partner domain's argo send_info hash table. Signed-off-by: Christopher Clark --- The logic in unregister_ring got pretty heavi

[Xen-devel] [PATCH v5 14/15] xsm, argo: notify: don't describe rings that cannot be sent to

2019-01-21 Thread Christopher Clark
Signed-off-by: Christopher Clark Acked-by: Daniel De Graaf --- v3 #10 Roger: drop out label, use return -EFAULT in fill_ring_data v3: Add Daniel's Acked-by xen/common/argo.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/xen/common/argo.c b/xen/common/argo.c index 46

[Xen-devel] [PATCH v5 09/15] argo: implement the sendv op; evtchn: expose send_guest_global_virq

2019-01-21 Thread Christopher Clark
L0/L1 nested hypervisor argo communication. Signed-off-by: Christopher Clark --- v4 Jan: remove use of fixed-width types from iov_count, ringbuf_insert v4 #07 Jan: shrink critical sections in sendv v3 #07 Jan: header: note 32-bitness of hypercall message tuype arg v4 : use standard data structures

Re: [Xen-devel] [PATCH v3 15/15] argo: validate hypercall arg structures via compat machinery

2019-01-23 Thread Christopher Clark
On Mon, Jan 21, 2019 at 4:03 AM Jan Beulich wrote: > > >>> On 20.01.19 at 22:18, wrote: > > On Thu, Jan 17, 2019 at 3:25 AM Jan Beulich wrote: > >> > >> >>> On 17.01.19 at 08:22, wrote: > > > > 3. A challenge with using the "struct" form, following from the result > > of point 2, occurs when it

[Xen-devel] [PATCH v6 02/15] argo: introduce the argo_op hypercall boilerplate

2019-01-23 Thread Christopher Clark
to be integer multiples of 32 bits in size. This means that the same copy_to_guest and copy_from_guest logic can be relied upon to perform as required without any further intervention. Testing communication with 32 and 64 bit guests has confirmed this works as intended. Signed-off-by: Christopher

[Xen-devel] [PATCH v6 06/15] xen/arm: introduce guest_handle_for_field()

2019-01-23 Thread Christopher Clark
ARM port of c/s bb544585: "introduce guest_handle_for_field()" This helper turns a field of a GUEST_HANDLE into a GUEST_HANDLE. Signed-off-by: Christopher Clark Reviewed-by: Paul Durrant Reviewed-by: Stefano Stabellini === v3: Added Stefano's Reviewed-by v2: Added Paul's

  1   2   3   4   >