Re: [Xen-devel] [PATCH for-4.10 2/2] xen/arm: p2m: Add more debug in get_page_from_gva

2017-11-16 Thread Stefano Stabellini
On Thu, 16 Nov 2017, Julien Grall wrote: > On 11/16/2017 01:36 AM, Stefano Stabellini wrote: > > On Wed, 15 Nov 2017, Julien Grall wrote: > > > The function get_page_from_gva is used by copy_*_guest helpers to > > > translate a guest virtual address to a machin

Re: [Xen-devel] Next Xen Arm Community call - Wednesday 22nd November

2017-11-16 Thread Stefano Stabellini
___ > From: Julien Grall <julien.gr...@linaro.org> > Sent: Thursday, November 16, 2017 1:54:51 PM > To: xen-devel; Edgar E. Iglesias; lars.ku...@citrix.com; > scamp...@codeaurora.org; stewart.hildebr...@dornerworks.com; Stefano > Stabellini; anastassios.na...@onapp.com;

Re: [Xen-devel] [PATCH for-4.10 2/2] xen/arm: p2m: Add more debug in get_page_from_gva

2017-11-15 Thread Stefano Stabellini
ps://lists.xen.org/archives/html/xen-devel/2017-11/msg00942.html > > Signed-off-by: Julien Grall <julien.gr...@linaro.org> Acked-by: Stefano Stabellini <sstabell...@kernel.org> fixed on commit > --- > xen/arch/arm/p2m.c | 13 + > 1 file changed, 13 insertio

Re: [Xen-devel] [PATCH for-4.10 1/2] xen/arm: mm: Change the return value of gvirt_to_maddr

2017-11-15 Thread Stefano Stabellini
may be unitialized) with the new ^ uninitialized > construction. > > Signed-off-by: Julien Grall <julien.gr...@linaro.org> Acked-by: Stefano Stabellini <sstabell...@kernel.org> I fixed on commit > --- > xen/a

Re: [Xen-devel] [PATCH 03/12] ARM: VGIC: remove gic_clear_pending_irqs()

2017-11-15 Thread Stefano Stabellini
On Fri, 10 Nov 2017, Andre Przywara wrote: > Hi, > > On 26/10/17 01:14, Stefano Stabellini wrote: > > On Thu, 19 Oct 2017, Andre Przywara wrote: > >> gic_clear_pending_irqs() was not only misnamed, but also misplaced, as > >> a function solely dealing with

Re: [Xen-devel] [PATCH v3] xen-disk: use an IOThread per instance

2017-11-15 Thread Stefano Stabellini
On Wed, 15 Nov 2017, Paul Durrant wrote: > Anthony, Stefano, > > Ping? Acked-by: Stefano Stabellini <sstabell...@kernel.org> Unless Anthony or somebody else object, I'll queue it up in my "next" branch (which I'll send upstream after 2.11 is out). Cheers, Stefano

Re: [Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-15 Thread Stefano Stabellini
On Wed, 15 Nov 2017, Boris Ostrovsky wrote: > On 11/15/2017 04:50 PM, Stefano Stabellini wrote: > > > > Sorry, code style issue: one missing space in the comment. I'll send it > > again separately > > > I've already fixe

Re: [Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-15 Thread Stefano Stabellini
On Wed, 15 Nov 2017, Stefano Stabellini wrote: > On Wed, 15 Nov 2017, Boris Ostrovsky wrote: > > On 11/15/2017 02:09 PM, Stefano Stabellini wrote: > > > On Wed, 15 Nov 2017, Juergen Gross wrote: > > >>>>> while

Re: [Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-15 Thread Stefano Stabellini
On Wed, 15 Nov 2017, Boris Ostrovsky wrote: > On 11/15/2017 02:09 PM, Stefano Stabellini wrote: > > On Wed, 15 Nov 2017, Juergen Gross wrote: > >>>>> while(mutex_is_locked(>active.in_mutex.owner) || > >>>>>

Re: [Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-15 Thread Stefano Stabellini
t take out_mutex. Next times you call mutex_trylock() in_mutex is going to fail. It's an endless loop. Solve the problem by waiting until the global refcount is 1 instead (the refcount is 1 when the only active pvcalls frontend function is pvcalls_front_release). Reported-by: Dan Carpenter <dan.carpen...@or

Re: [Xen-devel] [PATCH] xen/pvcalls: Add MODULE_LICENSE()

2017-11-15 Thread Stefano Stabellini
drivers/xen/pvcalls-back.c > index b209cd4..02cd33c 100644 > --- a/drivers/xen/pvcalls-back.c > +++ b/drivers/xen/pvcalls-back.c > @@ -1238,3 +1238,7 @@ static void __exit pvcalls_back_fin(void) > } > > module_exit(pvcalls_back_fin); > + > +MODULE_DESCRIPTION("X

Re: [Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-13 Thread Stefano Stabellini
On Mon, 13 Nov 2017, Juergen Gross wrote: > On 11/11/17 00:57, Stefano Stabellini wrote: > > On Tue, 7 Nov 2017, Juergen Gross wrote: > >> On 06/11/17 23:17, Stefano Stabellini wrote: > >>> mutex_trylock() returns 1 if you take the lock and 0 if not. Assume you > &

Re: [Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-13 Thread Stefano Stabellini
On Fri, 10 Nov 2017, Boris Ostrovsky wrote: > On 11/10/2017 06:57 PM, Stefano Stabellini wrote: > > On Tue, 7 Nov 2017, Juergen Gross wrote: > > > On 06/11/17 23:17, Stefano Stabellini wrote: > > > > mutex_trylock() returns 1 if you take the lock and 0 if not. As

Re: [Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-10 Thread Stefano Stabellini
On Tue, 7 Nov 2017, Juergen Gross wrote: > On 06/11/17 23:17, Stefano Stabellini wrote: > > mutex_trylock() returns 1 if you take the lock and 0 if not. Assume you > > take in_mutex on the first try, but you can't take out_mutex. Next times > > you call mutex_trylock() in_m

Re: [Xen-devel] [PATCH 04/12] ARM: VGIC: move gic_remove_irq_from_queues()

2017-11-10 Thread Stefano Stabellini
On Fri, 10 Nov 2017, Andre Przywara wrote: > Hi, > > ... > > >> diff --git a/xen/include/asm-arm/vgic.h b/xen/include/asm-arm/vgic.h > >> index e489d0bf21..8d0ff65708 100644 > >> --- a/xen/include/asm-arm/vgic.h > >> +++ b/xen/include/asm-arm/vgic.h > >> @@ -204,6 +204,7 @@ extern int

Re: [Xen-devel] [PATCH v2] aarch64: advertise the GIC system register interface

2017-11-07 Thread Stefano Stabellini
On Tue, 7 Nov 2017, Peter Maydell wrote: > On 6 November 2017 at 22:16, Stefano Stabellini <sstabell...@kernel.org> > wrote: > > When QEMU emulates a GICv3, it needs to advertise the presence of the > > system register interface, which is done via id_aa64pfr0. > > &

Re: [Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-06 Thread Stefano Stabellini
On Mon, 6 Nov 2017, Boris Ostrovsky wrote: > On 11/06/2017 05:17 PM, Stefano Stabellini wrote: > > mutex_trylock() returns 1 if you take the lock and 0 if not. Assume you > > take in_mutex on the first try, but you can't take out_mutex. Next times > > you call mutex_tryloc

[Xen-devel] [PATCH] xen/pvcalls: fix potential endless loop in pvcalls-front.c

2017-11-06 Thread Stefano Stabellini
. Reported-by: Dan Carpenter <dan.carpen...@oracle.com> Signed-off-by: Stefano Stabellini <sstabell...@kernel.org> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/xen/pvc

[Xen-devel] [PATCH v2] aarch64: advertise the GIC system register interface

2017-11-06 Thread Stefano Stabellini
in machvirt_init. Check on the boolean property from register_cp_regs_for_features and set id_aa64pfr0 accordingly. Signed-off-by: Stefano Stabellini <sstabell...@kernel.org> diff --git a/hw/arm/virt.c b/hw/arm/virt.c index 9e18b41..369d36b 100644 --- a/hw/arm/virt.c +++ b/hw/arm/virt.c @@ -1401,6 +

Re: [Xen-devel] [bug report] xen/pvcalls: implement release command

2017-11-06 Thread Stefano Stabellini
On Sat, 4 Nov 2017, Dan Carpenter wrote: > Hello Stefano Stabellini, > > The patch 235a71c53903: "xen/pvcalls: implement release command" from > Oct 30, 2017, leads to the following static checker warning: > > drivers/xen/pvcalls-front.c:1051 pvcalls_front_rel

Re: [Xen-devel] [RFC] ARM: New (Xen) VGIC design document

2017-11-02 Thread Stefano Stabellini
t;> issues, and a clean design from scratch lead to a very robust and > >>>> capable re-implementation. Interestingly this implementation is fairly > >>>> self-contained, so it seems feasible to copy it. Hopefully we only need > >>>> minor adjustments, po

Re: [Xen-devel] [RFC] ARM: New (Xen) VGIC design document

2017-11-01 Thread Stefano Stabellini
On Wed, 1 Nov 2017, Andre Przywara wrote: > Hi Stefano, > > > On 01/11/17 01:58, Stefano Stabellini wrote: > > On Wed, 11 Oct 2017, Andre Przywara wrote: > > many thanks for going through all of this! No problems, and thanks for your work and for caring ab

Re: [Xen-devel] [PATCH] aarch64: advertise the GIC system register interface

2017-10-31 Thread Stefano Stabellini
On Tue, 31 Oct 2017, Peter Maydell wrote: > On 31 October 2017 at 18:51, Stefano Stabellini <sstabell...@kernel.org> > wrote: > > On Tue, 31 Oct 2017, Peter Maydell wrote: > >> On 31 October 2017 at 17:01, Stefano Stabellini <sstabell...@kernel.org> > >>

Re: [Xen-devel] [RFC] ARM: New (Xen) VGIC design document

2017-10-31 Thread Stefano Stabellini
on is fairly > self-contained, so it seems feasible to copy it. Hopefully we only need > minor adjustments, possibly we can even copy it verbatim with some > additional glue layer code. > > Stefano asked for getting a design overview, to assess the feasibility > of copying the K

Re: [Xen-devel] [PATCH] aarch64: advertise the GIC system register interface

2017-10-31 Thread Stefano Stabellini
On Tue, 31 Oct 2017, Peter Maydell wrote: > On 31 October 2017 at 17:01, Stefano Stabellini <sstabell...@kernel.org> > wrote: > > Fixing QEMU is harder than I expected. Would it be possible to update > > id_aa64pfr0 at CPU reset time? Like cpu->id_aa64pfr0 |= 0x010

Re: [Xen-devel] [PATCH] aarch64: advertise the GIC system register interface

2017-10-31 Thread Stefano Stabellini
On Tue, 31 Oct 2017, Peter Maydell wrote: > On 19 October 2017 at 15:46, Peter Maydell <peter.mayd...@linaro.org> wrote: > > On 18 October 2017 at 01:10, Stefano Stabellini <sstabell...@kernel.org> > > wrote: > >> Advertise the presence of the GIC system regis

[Xen-devel] [PATCH v8 01/13] xen/pvcalls: introduce the pvcalls xenbus frontend

2017-10-30 Thread Stefano Stabellini
Introduce a xenbus frontend for the pvcalls protocol, as defined by https://xenbits.xen.org/docs/unstable/misc/pvcalls.html. This patch only adds the stubs, the code will be added by the following patches. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ost

[Xen-devel] [PATCH v8 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-30 Thread Stefano Stabellini
Also add pvcalls-front to the Makefile. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/Kconfig | 11 +++ drivers/xen/Makefile | 1 + 2 files

[Xen-devel] [PATCH v8 07/13] xen/pvcalls: implement listen command

2017-10-30 Thread Stefano Stabellini
Send PVCALLS_LISTEN to the backend. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 57 +

[Xen-devel] [PATCH v8 11/13] xen/pvcalls: implement poll command

2017-10-30 Thread Stefano Stabellini
ing at the PVCALLS_FLAG_POLL_RET flag. We set the flag from pvcalls_front_event_handler, if the response was for a POLL command. In pvcalls_front_event_handler, get the struct sock_mapping from the poll id (we previously converted struct sock_mapping* to uintptr_t and used it as id). Signed-off-by: Stef

[Xen-devel] [PATCH v8 09/13] xen/pvcalls: implement sendmsg

2017-10-30 Thread Stefano Stabellini
000 cycles. This small optimization turns out to improve performance significantly. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen

[Xen-devel] [PATCH v8 12/13] xen/pvcalls: implement release command

2017-10-30 Thread Stefano Stabellini
-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 98 + drivers/xen/pvcalls-front.h | 1 + 2 files

[Xen-devel] [PATCH v8 10/13] xen/pvcalls: implement recvmsg

2017-10-30 Thread Stefano Stabellini
Implement recvmsg by copying data from the "in" ring. If not enough data is available and the recvmsg call is blocking, then wait on the inflight_conn_req waitqueue. Take the active socket in_mutex so that only one function can access the ring at any given time. Signed-off-by: Stefano

[Xen-devel] [PATCH v8 08/13] xen/pvcalls: implement accept command

2017-10-30 Thread Stefano Stabellini
-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 145 drivers/xen/pvcalls-front.h | 3 + 2 files

[Xen-devel] [PATCH v8 00/13] introduce the Xen PV Calls frontend

2017-10-30 Thread Stefano Stabellini
Stefano Stabellini (13): xen/pvcalls: introduce the pvcalls xenbus frontend xen/pvcalls: implement frontend disconnect xen/pvcalls: connect to the backend xen/pvcalls: implement socket command and handle events xen/pvcalls: implement connect command xen/pvcalls

[Xen-devel] [PATCH v8 05/13] xen/pvcalls: implement connect command

2017-10-30 Thread Stefano Stabellini
mutexes (one of reads and one for writes) will be used to protect the active socket in and out rings from concurrent accesses. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr

[Xen-devel] [PATCH v8 02/13] xen/pvcalls: implement frontend disconnect

2017-10-30 Thread Stefano Stabellini
pvcalls users. Only remove connections once the refcount is zero. Implement pvcalls frontend removal function. Go through the list of active and passive sockets and free them all, one at a time. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <bor

[Xen-devel] [PATCH v8 06/13] xen/pvcalls: implement bind command

2017-10-30 Thread Stefano Stabellini
Send PVCALLS_BIND to the backend. Introduce a new structure, part of struct sock_mapping, to store information specific to passive sockets. Introduce a status field to keep track of the status of the passive socket. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by:

[Xen-devel] [PATCH v8 03/13] xen/pvcalls: connect to the backend

2017-10-30 Thread Stefano Stabellini
a stub functions for the event handler. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 132 1

[Xen-devel] [PATCH v8 04/13] xen/pvcalls: implement socket command and handle events

2017-10-30 Thread Stefano Stabellini
n easily get the struct sock_mapping from the struct socket. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/x

Re: [Xen-devel] [PATCH v7 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-30 Thread Stefano Stabellini
On Mon, 30 Oct 2017, Boris Ostrovsky wrote: > On 10/30/2017 05:42 PM, Stefano Stabellini wrote: > > On Mon, 30 Oct 2017, Boris Ostrovsky wrote: > >> On 10/30/2017 03:48 PM, Stefano Stabellini wrote: > >>> On Mon, 30 Oct 2017, Boris Ostrovsky wrote: > >>>

Re: [Xen-devel] [PATCH v7 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-30 Thread Stefano Stabellini
On Mon, 30 Oct 2017, Boris Ostrovsky wrote: > On 10/30/2017 03:48 PM, Stefano Stabellini wrote: > > On Mon, 30 Oct 2017, Boris Ostrovsky wrote: > >> > >> Build warnings (gcc (GCC) 6.3.1 20161221 (Red Hat 6.3.1-1)) > > Hi Boris, I am trying to repro the warnings be

[Xen-devel] [PATCH 1/2] pvcalls: check return value from copy_from/to_iter

2017-10-30 Thread Stefano Stabellini
Check the return value of copy_from_iter in __write_ring and copy_to_iter in __read_ring. Update "len" accordingly. In the cases where we issue two consecutive copy_from_iter, or two consecutive copy_to_iter, first check return, then goto out if it is not what we expect. Signed-off-b

[Xen-devel] [PATCH 2/2] pvcalls: fix casts to avoid warnings on 32 bit

2017-10-30 Thread Stefano Stabellini
in the poll request. Signed-off-by: Stefano Stabellini <sstabell...@kernel.org> --- drivers/xen/pvcalls-front.c | 18 +- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/xen/pvcalls-front.c b/drivers/xen/pvcalls-front.c index f2dcac88..0c1ec68 100644 --- a/d

Re: [Xen-devel] [PATCH v7 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-30 Thread Stefano Stabellini
On Mon, 30 Oct 2017, Boris Ostrovsky wrote: > On 10/26/2017 04:45 PM, Boris Ostrovsky wrote: > > On 10/26/2017 04:16 PM, Stefano Stabellini wrote: > >> On Thu, 26 Oct 2017, Boris Ostrovsky wrote: > >>> On 10/26/2017 03:11 PM, Stefano Stabellini wrote: > >>&g

Re: [Xen-devel] [BUG] win2008 guest cannot get ip through sriov

2017-10-27 Thread Stefano Stabellini
is fix? Is it > > possible to catch Xen 4.10's qemu-xen? > > I will let Stefano and Anthony providing feedback before giving a release-ack > here. Yes, I think we should backport the commit as it fixes a genuine bug. The backport is not risk-free but it only affects PCI Passthrough. Also

Re: [Xen-devel] [RFC 0/4] TEE mediator framework + OP-TEE mediator

2017-10-27 Thread Stefano Stabellini
On Fri, 27 Oct 2017, Julien Grall wrote: > Hi, > > Just answering to dom0 been 1:1 domain. > > On 24/10/17 22:33, Stefano Stabellini wrote: > > On Tue, 24 Oct 2017, Volodymyr Babchuk wrote: > > > > For this series, I think we need a way to specify which do

Re: [Xen-devel] [PATCH v5.1 2/8] xen: restrict: use xentoolcore_restrict_all

2017-10-27 Thread Stefano Stabellini
On Fri, 27 Oct 2017, Ian Jackson wrote: > Stefano Stabellini writes ("Re: [PATCH v5.1 2/8] xen: restrict: use > xentoolcore_restrict_all"): > > On Fri, 20 Oct 2017, Ian Jackson wrote: > ... > > > Drop individual use of xendevicemodel_restrict a

[Xen-devel] [PULL 2/3] xen: dont try setting max grants multiple times

2017-10-26 Thread Stefano Stabellini
ub-xen is being used to boot it. So instead of letting the generic backend code open the gnttab device do it in blk_connect() and close it again in blk_disconnect. Signed-off-by: Juergen Gross <jgr...@suse.com> Acked-by: Anthony PERARD <anthony.per...@citrix.com> Signed-off-by:

[Xen-devel] [PULL 0/3] xen-20171026-tag

2017-10-26 Thread Stefano Stabellini
The following changes since commit 325a084c1ebccb265a3c8f1dd092ffbbfb448a00: Merge remote-tracking branch 'remotes/stefanberger/tags/pull-tpm-2017-10-24-1' into staging (2017-10-26 09:20:11 +0100) are available in the git repository at:

[Xen-devel] [PULL 3/3] xen: Log errno rather than return value

2017-10-26 Thread Stefano Stabellini
r...@citrix.com> Signed-off-by: Stefano Stabellini <sstabell...@kernel.org> --- hw/i386/xen/xen-hvm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/i386/xen/xen-hvm.c b/hw/i386/xen/xen-hvm.c index d9ccd5d..8028bed 100644 --- a/hw/i386/xen/xen-hvm.c +++ b/hw/i386/xen/xen-

[Xen-devel] [PULL 1/3] xen: add a global indicator for grant copy being available

2017-10-26 Thread Stefano Stabellini
om> Acked-by: Anthony PERARD <anthony.per...@citrix.com> Signed-off-by: Stefano Stabellini <sstabell...@kernel.org> --- hw/block/xen_disk.c | 18 ++ hw/xen/xen_backend.c | 11 +++ include/hw/xen/xen_backend.h | 1 + 3 files changed, 18 ins

Re: [Xen-devel] [PATCH v5.1 5/8] xen: move xc_interface compatibility fallback further up the file

2017-10-26 Thread Stefano Stabellini
t; Signed-off-by: Ian Jackson <ian.jack...@eu.citrix.com> > Acked-by: Anthony PERARD <anthony.per...@citrix.com> Acked-by: Stefano Stabellini <sstabell...@kernel.org> > --- > v2: New patch in v2 of the series > --- > include/hw/xen/xen_common.h | 18 +++---

Re: [Xen-devel] [PATCH v5.1 1/8] xen: link against xentoolcore

2017-10-26 Thread Stefano Stabellini
stable_libs > -lxentoolcore" > then > - xen_stable_libs="-lxendevicemodel $xen_stable_libs" > + xen_stable_libs="-lxendevicemodel $xen_stable_libs -lxentoolcore" Is it on purpose that -lxentoolcore is at the end of this string rather than before $xen_stable_libs? In any case Acked-by: Stefano Stabellini <sstabell...@kernel.org> >xen_ctrl_version=41000 >xen=yes > elif > -- > 2.1.4 > ___ Xen-devel mailing list Xen-devel@lists.xen.org https://lists.xen.org/xen-devel

Re: [Xen-devel] [PATCH v5.1 7/8] os-posix: Provide new -runas : facility

2017-10-26 Thread Stefano Stabellini
CC'ing the maintainers (scripts/get_maintainer.pl is your friend) On Fri, 20 Oct 2017, Ian Jackson wrote: > This allows the caller to specify a uid and gid to use, even if there > is no corresponding password entry. This will be useful in certain > Xen configurations. > > We don't support just

Re: [Xen-devel] [PATCH v5.1 8/8] configure: do_compiler: Dump some extra info under bash

2017-10-26 Thread Stefano Stabellini
CC'ing the maintainers for this. On Fri, 20 Oct 2017, Ian Jackson wrote: > This makes it much easier to find a particular thing in config.log. > > The information may be lacking in other shells, resulting in harmless > empty output. (This is why we don't use the proper ${FUNCNAME[*]} > array

Re: [Xen-devel] [PATCH v5.1 6/8] xen: destroy_hvm_domain: Try xendevicemodel_shutdown

2017-10-26 Thread Stefano Stabellini
On Fri, 20 Oct 2017, Ian Jackson wrote: > xc_interface_open etc. is not going to work if we have dropped > privilege, but xendevicemodel_shutdown will if everything is new > enough. > > xendevicemodel_shutdown is only availabe in Xen 4.10 and later, so > provide a stub for earlier versions. > >

Re: [Xen-devel] [PATCH v5.1 4/8] xen: destroy_hvm_domain: Move reason into a variable

2017-10-26 Thread Stefano Stabellini
On Fri, 20 Oct 2017, Ian Jackson wrote: > We are going to want to reuse this. > > No functional change. > > Signed-off-by: Ian Jackson <ian.jack...@eu.citrix.com> > Reviewed-by: Anthony PERARD <anthony.per...@citrix.com> Acked-by: Stefano Stabellini <sstabell.

Re: [Xen-devel] [PATCH v5.1 3/8] xen: defer call to xen_restrict until just before os_setup_post

2017-10-26 Thread Stefano Stabellini
This patch affects non-Xen components. CC'ing the relevant maintainers. On Fri, 20 Oct 2017, Ian Jackson wrote: > We need to restrict *all* the control fds that qemu opens. Looking in > /proc/PID/fd shows there are many; their allocation seems scattered > throughout Xen support code in qemu. >

Re: [Xen-devel] [PATCH v5.1 2/8] xen: restrict: use xentoolcore_restrict_all

2017-10-26 Thread Stefano Stabellini
On Fri, 20 Oct 2017, Ian Jackson wrote: > And insist that it works. > > Drop individual use of xendevicemodel_restrict and > xenforeignmemory_restrict. These are not actually effective in this > version of qemu, because qemu has a large number of fds open onto > various Xen control devices. > >

Re: [Xen-devel] [PATCH v7 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-26 Thread Stefano Stabellini
On Thu, 26 Oct 2017, Boris Ostrovsky wrote: > On 10/26/2017 04:16 PM, Stefano Stabellini wrote: > > On Thu, 26 Oct 2017, Boris Ostrovsky wrote: > >> On 10/26/2017 03:11 PM, Stefano Stabellini wrote: > >>> Also add pvcalls-front to the Makefile. > >>> >

Re: [Xen-devel] [PATCH v7 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-26 Thread Stefano Stabellini
On Thu, 26 Oct 2017, Boris Ostrovsky wrote: > On 10/26/2017 03:11 PM, Stefano Stabellini wrote: > > Also add pvcalls-front to the Makefile. > > > > Signed-off-by: Stefano Stabellini <stef...@aporeto.com> > > CC: boris.ostrov...@oracle.com > > CC: jgr...@sus

[Xen-devel] [PATCH v7 06/13] xen/pvcalls: implement bind command

2017-10-26 Thread Stefano Stabellini
Send PVCALLS_BIND to the backend. Introduce a new structure, part of struct sock_mapping, to store information specific to passive sockets. Introduce a status field to keep track of the status of the passive socket. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by:

[Xen-devel] [PATCH v7 05/13] xen/pvcalls: implement connect command

2017-10-26 Thread Stefano Stabellini
mutexes (one of reads and one for writes) will be used to protect the active socket in and out rings from concurrent accesses. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr

[Xen-devel] [PATCH v7 09/13] xen/pvcalls: implement sendmsg

2017-10-26 Thread Stefano Stabellini
000 cycles. This small optimization turns out to improve performance significantly. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen

[Xen-devel] [PATCH v7 01/13] xen/pvcalls: introduce the pvcalls xenbus frontend

2017-10-26 Thread Stefano Stabellini
Introduce a xenbus frontend for the pvcalls protocol, as defined by https://xenbits.xen.org/docs/unstable/misc/pvcalls.html. This patch only adds the stubs, the code will be added by the following patches. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ost

[Xen-devel] [PATCH v7 07/13] xen/pvcalls: implement listen command

2017-10-26 Thread Stefano Stabellini
Send PVCALLS_LISTEN to the backend. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 57 +

[Xen-devel] [PATCH v7 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-26 Thread Stefano Stabellini
Also add pvcalls-front to the Makefile. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/Kconfig | 11 +++ drivers/xen/Makefile | 1 + 2 files changed, 12 insertions(+) diff --git a/drivers/xen/Kconfig b/d

[Xen-devel] [PATCH v7 02/13] xen/pvcalls: implement frontend disconnect

2017-10-26 Thread Stefano Stabellini
pvcalls users. Only remove connections once the refcount is zero. Implement pvcalls frontend removal function. Go through the list of active and passive sockets and free them all, one at a time. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> CC: boris.ostrov...@oracle.com C

[Xen-devel] [PATCH v7 04/13] xen/pvcalls: implement socket command and handle events

2017-10-26 Thread Stefano Stabellini
n easily get the struct sock_mapping from the struct socket. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 131 +

[Xen-devel] [PATCH v7 11/13] xen/pvcalls: implement poll command

2017-10-26 Thread Stefano Stabellini
ing at the PVCALLS_FLAG_POLL_RET flag. We set the flag from pvcalls_front_event_handler, if the response was for a POLL command. In pvcalls_front_event_handler, get the struct sock_mapping from the poll id (we previously converted struct sock_mapping* to uint64_t and used it as id). Signed-off-by: Stef

[Xen-devel] [PATCH v7 00/13] introduce the Xen PV Calls frontend

2017-10-26 Thread Stefano Stabellini
out the socket_lock - remove now unused bool lock parameter to pvcalls_front_free_map - XEN_PVCALLS_FRONTEND: default n and select XEN_XENBUS_FRONTEND Stefano Stabellini (13): xen/pvcalls: introduce the pvcalls xenbus frontend xen/pvcalls: implement frontend disconnect xen/pvca

[Xen-devel] [PATCH v7 10/13] xen/pvcalls: implement recvmsg

2017-10-26 Thread Stefano Stabellini
Implement recvmsg by copying data from the "in" ring. If not enough data is available and the recvmsg call is blocking, then wait on the inflight_conn_req waitqueue. Take the active socket in_mutex so that only one function can access the ring at any given time. Signed-off-by: Stefano

[Xen-devel] [PATCH v7 12/13] xen/pvcalls: implement release command

2017-10-26 Thread Stefano Stabellini
-off-by: Stefano Stabellini <stef...@aporeto.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 98 + drivers/xen/pvcalls-front.h | 1 + 2 files changed, 99 insertions(+) diff --git a/drivers/xen/pvcalls-fro

[Xen-devel] [PATCH v7 08/13] xen/pvcalls: implement accept command

2017-10-26 Thread Stefano Stabellini
-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 145 drivers/xen/pvcalls-front.h | 3 + 2 files

[Xen-devel] [PATCH v7 03/13] xen/pvcalls: connect to the backend

2017-10-26 Thread Stefano Stabellini
a stub functions for the event handler. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 132 1

Re: [Xen-devel] [PATCH v6 12/13] xen/pvcalls: implement release command

2017-10-26 Thread Stefano Stabellini
On Thu, 26 Oct 2017, Boris Ostrovsky wrote: > On 10/25/2017 07:00 PM, Stefano Stabellini wrote: > > On Wed, 25 Oct 2017, Boris Ostrovsky wrote: > >> On 10/24/2017 01:33 PM, Stefano Stabellini wrote: > >>> Send PVCALLS_RELEASE to the backend and wait for a r

Re: [Xen-devel] [PATCH 12/12] ARM: VGIC: rework gicv[23]_update_lr to not use pending_irq

2017-10-25 Thread Stefano Stabellini
rom gic-v[23].c. > > Signed-off-by: Andre Przywara <andre.przyw...@arm.com> Reviewed-by: Stefano Stabellini <sstabell...@kernel.org> > --- > xen/arch/arm/gic-v2.c | 14 +++--- > xen/arch/arm/gic-v3.c | 12 ++-- > xen/arch/arm/gic-vgic.c | 3 ++

Re: [Xen-devel] [PATCH 11/12] ARM: VGIC: factor out vgic_get_hw_irq_desc()

2017-10-25 Thread Stefano Stabellini
abstraction. > > Signed-off-by: Andre Przywara <andre.przyw...@arm.com> Acked-by: Stefano Stabellini <sstabell...@kernel.org> > --- > xen/arch/arm/gic-vgic.c| 15 +++ > xen/arch/arm/irq.c | 7 ++- > xen/include/asm-arm/vgic.h | 2

Re: [Xen-devel] [PATCH 10/12] ARM: VGIC: factor out vgic_connect_hw_irq()

2017-10-25 Thread Stefano Stabellini
to be connected to a hardware IRQ (using the hw bit in the LR). > > This removes said accesses to VGIC data structures and improves abstraction. > > Signed-off-by: Andre Przywara <andre.przyw...@arm.com> Acked-by: Stefano Stabellini <sstabell...@kernel.org> &

Re: [Xen-devel] [PATCH 09/12] ARM: VGIC: rework events_need_delivery()

2017-10-25 Thread Stefano Stabellini
; event channel if there are no other pending IRQs. > > Signed-off-by: Andre Przywara <andre.przyw...@arm.com> Reviewed-by: Stefano Stabellini <sstabell...@kernel.org> > --- > xen/arch/arm/vgic.c | 11 +++ > xen/include/asm-arm/event.h | 13 +++-- &

Re: [Xen-devel] [PATCH 08/12] ARM: VGIC: split up gic_dump_info() to cover virtual part separately

2017-10-25 Thread Stefano Stabellini
On Thu, 19 Oct 2017, Andre Przywara wrote: > Currently gic_dump_info() not only dumps the hardware state of the GIC, > but also the VGIC internal virtual IRQ lists. > Split the latter off and move it into vgic.c to observe the abstraction. > > Signed-off-by: Andre Przywara

Re: [Xen-devel] [PATCH 07/12] ARM: VGIC: split gic.c to observe hardware/virtual GIC separation

2017-10-25 Thread Stefano Stabellini
On Thu, 19 Oct 2017, Andre Przywara wrote: > Currently gic.c holds code to handle hardware IRQs as well as code to > bridge VGIC requests to the GIC virtualization hardware. That is true, however, I don't necessarely see "the code to bridge VGIC requests to the GIC virtualization hardware" as

Re: [Xen-devel] [PATCH 05/12] ARM: VGIC: move gic_remove_from_lr_pending()

2017-10-25 Thread Stefano Stabellini
On Thu, 19 Oct 2017, Andre Przywara wrote: > gic_remove_from_lr_pending() was not only misnamed, it also had the wrong > abstraction, as it should not live in gic.c. > Move it into vgic.c and vgic.h, where it belongs, and rename it on the > way. > > Signed-off-by: Andre Przywara

Re: [Xen-devel] [PATCH 04/12] ARM: VGIC: move gic_remove_irq_from_queues()

2017-10-25 Thread Stefano Stabellini
ywara <andre.przyw...@arm.com> Yes, gic_remove_irq_from_queues could be in the vgic. Reviewed-by: Stefano Stabellini <sstabell...@kernel.org> One comment about cosmetics below. > --- > xen/arch/arm/gic.c | 9 - > xen/arch/arm/vgic-v3-its.c | 4

Re: [Xen-devel] [PATCH 03/12] ARM: VGIC: remove gic_clear_pending_irqs()

2017-10-25 Thread Stefano Stabellini
On Thu, 19 Oct 2017, Andre Przywara wrote: > gic_clear_pending_irqs() was not only misnamed, but also misplaced, as > a function solely dealing with the GIC emulation should not live in gic.c. > Move the functionality of this function into its only caller in vgic.c > > Signed-off-by: Andre

Re: [Xen-devel] [PATCH 02/12] ARM: vGIC: fix nr_irq definition

2017-10-25 Thread Stefano Stabellini
s if one wanted to use a rather innocent "nr_irqs" as > a local variable name or as a function parameter. > Drop the optimization and make nr_irqs a normal variable for ARM also. > > Signed-off-by: Andre Przywara <andre.przyw...@arm.com> Reviewed-by: Stefano Stabelli

Re: [Xen-devel] [PATCH 01/12] ARM: remove unneeded gic.h inclusions

2017-10-25 Thread Stefano Stabellini
es. > Remove unneeded inclusions of gic.h from files where they are actually > not needed. > > Signed-off-by: Andre Przywara <andre.przyw...@arm.com> Reviewed-by: Stefano Stabellini <sstabell...@kernel.org> > --- > xen/arch/arm/domain_build.c | 1 - > xen/

Re: [Xen-devel] [PATCH v3 2/2] arm/xen: vpl011: Fix SBSA UART interrupt assertion

2017-10-25 Thread Stefano Stabellini
t; Signed-off-by: Bhupinder Thakur <bhupinder.tha...@linaro.org> > Reviewed-by: Andre Przywara <andre.przyw...@linaro.org> > Signed-off-by: Andre Przywara <andre.przyw...@linaro.org> This is good, only minor cosmetic comments. Acked-by: Stefano Stabellini <sstabell...@kern

Re: [Xen-devel] [PATCH v3 1/2] arm/xen: vpl011: Fix the slow early console SBSA UART output

2017-10-25 Thread Stefano Stabellini
Thakur <bhupinder.tha...@linaro.org> > Reviewed-by: Andre Przywara <andre.przyw...@linaro.org> > Signed-off-by: Andre Przywara <andre.przyw...@linaro.org> Reviewed-by: Stefano Stabellini <sstabell...@kernel.org> > --- > xen/arch/arm/vpl011.c | 21 +++

Re: [Xen-devel] [PATCH v6 02/13] xen/pvcalls: implement frontend disconnect

2017-10-25 Thread Stefano Stabellini
On Wed, 25 Oct 2017, Boris Ostrovsky wrote: > On 10/24/2017 01:33 PM, Stefano Stabellini wrote: > > +static void pvcalls_front_free_map(struct pvcalls_bedata *bedata, > > + struct sock_mapping *map, bool locked) > > +{ > > +} >

Re: [Xen-devel] [PATCH v6 12/13] xen/pvcalls: implement release command

2017-10-25 Thread Stefano Stabellini
On Wed, 25 Oct 2017, Boris Ostrovsky wrote: > On 10/24/2017 01:33 PM, Stefano Stabellini wrote: > > Send PVCALLS_RELEASE to the backend and wait for a reply. Take both > > in_mutex and out_mutex to avoid concurrent accesses. Then, free the > > socket. > > > > For

Re: [Xen-devel] [PATCH v6 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-25 Thread Stefano Stabellini
On Wed, 25 Oct 2017, Boris Ostrovsky wrote: > On 10/24/2017 01:33 PM, Stefano Stabellini wrote: > > Also add pvcalls-front to the Makefile. > > > > Signed-off-by: Stefano Stabellini <stef...@aporeto.com> > > CC: boris.ostrov...@oracle.com > > CC: jgr...@su

Re: [Xen-devel] [RFC 0/4] TEE mediator framework + OP-TEE mediator

2017-10-24 Thread Stefano Stabellini
On Tue, 24 Oct 2017, Volodymyr Babchuk wrote: > > > > >Approach in this RFC is much simpler. Few hooks in arch code + > > > > >additional > > > > >subsystem, which can be easily turned off. > > > > > > > > Stefano do you hav

[Xen-devel] [PATCH v6 11/13] xen/pvcalls: implement poll command

2017-10-24 Thread Stefano Stabellini
ing at the PVCALLS_FLAG_POLL_RET flag. We set the flag from pvcalls_front_event_handler, if the response was for a POLL command. In pvcalls_front_event_handler, get the struct sock_mapping from the poll id (we previously converted struct sock_mapping* to uint64_t and used it as id). Signed-off-by: Stef

[Xen-devel] [PATCH v6 02/13] xen/pvcalls: implement frontend disconnect

2017-10-24 Thread Stefano Stabellini
sockets and free them all, one at a time. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 65 + 1 file changed, 65 insertions(+) diff --git a/drivers/xen/p

[Xen-devel] [PATCH v6 07/13] xen/pvcalls: implement listen command

2017-10-24 Thread Stefano Stabellini
Send PVCALLS_LISTEN to the backend. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ostrovsky <boris.ostrov...@oracle.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-front.c | 57 +

[Xen-devel] [PATCH v6 06/13] xen/pvcalls: implement bind command

2017-10-24 Thread Stefano Stabellini
Send PVCALLS_BIND to the backend. Introduce a new structure, part of struct sock_mapping, to store information specific to passive sockets. Introduce a status field to keep track of the status of the passive socket. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by:

[Xen-devel] [PATCH v6 13/13] xen: introduce a Kconfig option to enable the pvcalls frontend

2017-10-24 Thread Stefano Stabellini
Also add pvcalls-front to the Makefile. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/Kconfig | 9 + drivers/xen/Makefile | 1 + 2 files changed, 10 insertions(+) diff --git a/drivers/xen/Kconfig b/drive

[Xen-devel] [PATCH v6 01/13] xen/pvcalls: introduce the pvcalls xenbus frontend

2017-10-24 Thread Stefano Stabellini
Introduce a xenbus frontend for the pvcalls protocol, as defined by https://xenbits.xen.org/docs/unstable/misc/pvcalls.html. This patch only adds the stubs, the code will be added by the following patches. Signed-off-by: Stefano Stabellini <stef...@aporeto.com> Reviewed-by: Boris Ost

  1   2   3   4   5   6   7   8   9   10   >