Re: [Xen-devel] [PATCH 16/24] xen/arm: mm: Use typesafe mfn for xenheap_mfn_*

2017-06-15 Thread Julien Grall
Hi Stefano, On 16/06/2017 00:12, Stefano Stabellini wrote: On Tue, 13 Jun 2017, Julien Grall wrote: Add more safety when using xenheap_mfn_*. Signed-off-by: Julien Grall --- xen/arch/arm/mm.c| 16 xen/arch/arm/setup.c | 18 +- xen/include/asm-arm/

Re: [Xen-devel] [PATCH] VT-d: fix VF of RC integrated endpoint matched to wrong VT-d unit

2017-06-15 Thread Chao Gao
+ Eric On Fri, Jun 16, 2017 at 02:48:39PM +0800, Chao Gao wrote: >The problem is a VF of RC integrated PF (e.g. PF's BDF is 00:02.0), >we would wrongly use 00:00.0 to search VT-d unit. > >To search VT-d unit for a VF, the BDF of the PF is used. And If the >PF is an Extended Function, the BDF of on

Re: [Xen-devel] [PATCH 04/24] xen/arm: mm: Introduce clear_table and use it

2017-06-15 Thread Julien Grall
Hi Stefano, On 15/06/2017 23:31, Stefano Stabellini wrote: On Tue, 13 Jun 2017, Julien Grall wrote: Add a new helper clear_table to clear a page table entry and invalidate the cache. Signed-off-by: Julien Grall --- xen/arch/arm/mm.c | 22 -- 1 file changed, 12 insertions(

Re: [Xen-devel] [PATCH 03/24] xen/arm: setup: Remove bogus xenheap_mfn_end in setup_mm for arm64

2017-06-15 Thread Julien Grall
Hi Stefano, On 15/06/2017 23:28, Stefano Stabellini wrote: On Tue, 13 Jun 2017, Julien Grall wrote: xenheap_mfn_end is storing an MFN and not a physical address. Thankfully xenheap_mfn_end is not used in the arm64 code. So drop it. That's fine, but in that case I would prefer to move the defi

[Xen-devel] [PATCH] VT-d: fix VF of RC integrated endpoint matched to wrong VT-d unit

2017-06-15 Thread Chao Gao
The problem is a VF of RC integrated PF (e.g. PF's BDF is 00:02.0), we would wrongly use 00:00.0 to search VT-d unit. To search VT-d unit for a VF, the BDF of the PF is used. And If the PF is an Extended Function, the BDF of one traditional function is used. The following line (from acpi_find_matc

[Xen-devel] [xen-4.8-testing baseline-only test] 71568: regressions - trouble: blocked/broken/fail/pass

2017-06-15 Thread Platform Team regression test user
This run is configured for baseline tests only. flight 71568 xen-4.8-testing real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/71568/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-amd64-libvirt-xsm 17 guest-start/

Re: [Xen-devel] EL0 app, stubdoms on ARM conf call

2017-06-15 Thread Dario Faggioli
On Thu, 2017-06-15 at 13:14 -0700, Stefano Stabellini wrote: > On Thu, 15 Jun 2017, Volodymyr Babchuk wrote: > > Hello Stefano, > > On 15 June 2017 at 21:21, Stefano Stabellini > > wrote: > > > Would you be up for joining a conf call to discuss EL0 apps and > > > stubdoms > > > on ARM in preparati

[Xen-devel] [ovmf test] 110467: all pass - PUSHED

2017-06-15 Thread osstest service owner
flight 110467 ovmf real [real] http://logs.test-lab.xenproject.org/osstest/logs/110467/ Perfect :-) All tests in this flight passed as required version targeted for testing: ovmf 53fa87286b9348d285654dda1ab2274241358ffc baseline version: ovmf c314970984065c98a5609

[Xen-devel] [PATCH] libxc: add xc_domain_add_to_physmap_batch to wrap XENMEM_add_to_physmap_batch

2017-06-15 Thread Zhongze Liu
currently there is no wrapper for XENMEM_add_to_physmap_batch in libxc. add a wrapper to do that. Signed-off-by: Zhongze Liu --- Cc: Ian Jackson , Cc: Wei Liu , Cc: Stefano Stabellini --- tools/libxc/include/xenctrl.h | 9 + tools/libxc/xc_domain.c | 44 ++

Re: [Xen-devel] questions on mem_sharing_op*'s and tools/tests/mem-sharing/memshrtool

2017-06-15 Thread Zhongze Liu
2017-06-16 11:50 GMT+08:00 Zhongze Liu : > Hi there, > > I was experimenting with the mem_sharing_op and I found a handy tool: > tools/tests/mem-sharing/memshrtool > I set up two bare metal x86_64 VMS running some simple code in 16-bit > real mode and I tried to share the first physical page among

Re: [Xen-devel] [PATCH 17/44] hexagon: switch to use ->mapping_error for error reporting

2017-06-15 Thread Richard Kuo
On Thu, Jun 08, 2017 at 03:25:42PM +0200, Christoph Hellwig wrote: > Signed-off-by: Christoph Hellwig > --- > arch/hexagon/include/asm/dma-mapping.h | 2 -- > arch/hexagon/kernel/dma.c | 12 +--- > arch/hexagon/kernel/hexagon_ksyms.c| 1 - > 3 files changed, 9 insertion

Re: [Xen-devel] [PATCH 31/44] hexagon: remove arch-specific dma_supported implementation

2017-06-15 Thread Richard Kuo
On Thu, Jun 08, 2017 at 03:25:56PM +0200, Christoph Hellwig wrote: > This implementation is simply bogus - hexagon only has a simple > direct mapped DMA implementation and thus doesn't care about the > address. > > Signed-off-by: Christoph Hellwig > --- > arch/hexagon/include/asm/dma-mapping.h |

[Xen-devel] questions on mem_sharing_op*'s and tools/tests/mem-sharing/memshrtool

2017-06-15 Thread Zhongze Liu
Hi there, I was experimenting with the mem_sharing_op and I found a handy tool: tools/tests/mem-sharing/memshrtool I set up two bare metal x86_64 VMS running some simple code in 16-bit real mode and I tried to share the first physical page among them. so I use: "./memshrtool enable src_dom " "./m

[Xen-devel] [qemu-mainline test] 110458: tolerable FAIL - PUSHED

2017-06-15 Thread osstest service owner
flight 110458 qemu-mainline real [real] http://logs.test-lab.xenproject.org/osstest/logs/110458/ Failures :-/ but no regressions. Tests which are failing intermittently (not blocking): test-armhf-armhf-xl-vhd 5 xen-install fail in 110428 pass in 110458 test-amd64-amd64-xl-qemuu-win7-

[Xen-devel] [xen-unstable-smoke test] 110476: tolerable trouble: broken/pass - PUSHED

2017-06-15 Thread osstest service owner
flight 110476 xen-unstable-smoke real [real] http://logs.test-lab.xenproject.org/osstest/logs/110476/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-arm64-arm64-xl-xsm 1 build-check(1) blocked n/a test-amd64-amd64-libvirt 12 mig

[Xen-devel] [xen-4.7-testing baseline-only test] 71565: tolerable trouble: blocked/broken/fail/pass

2017-06-15 Thread Platform Team regression test user
This run is configured for baseline tests only. flight 71565 xen-4.7-testing real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/71565/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-amd64-amd64-qemuu-nested-intel 16 debian-hvm-ins

[Xen-devel] [linux-4.9 test] 110456: tolerable FAIL - PUSHED

2017-06-15 Thread osstest service owner
flight 110456 linux-4.9 real [real] http://logs.test-lab.xenproject.org/osstest/logs/110456/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-amd64-amd64-rumprun-amd64 16 rumprun-demo-xenstorels/xenstorels.repeat fail REGR. vs. 107358 test-amd64

Re: [Xen-devel] [RFC] ARM PCI Passthrough design document

2017-06-15 Thread Stefano Stabellini
On Tue, 30 May 2017, Julien Grall wrote: > > > In this design document, we are considering that the host bridge driver > > > can > > > be ported in Xen. In the case it is not possible, a interface to forward > > > configuration space access would need to be defined. The interface details > > > is o

Re: [Xen-devel] [RFC] ARM PCI Passthrough design document

2017-06-15 Thread Stefano Stabellini
On Fri, 26 May 2017, Julien Grall wrote: > Hi all, > > The document below is an RFC version of a design proposal for PCI > Passthrough in Xen on ARM. It aims to describe from an high level perspective > the interaction with the different subsystems and how guest will be able > to discover and acce

[Xen-devel] [libvirt test] 110460: tolerable all pass - PUSHED

2017-06-15 Thread osstest service owner
flight 110460 libvirt real [real] http://logs.test-lab.xenproject.org/osstest/logs/110460/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-armhf-armhf-libvirt 13 saverestore-support-checkfail like 110425 test-armhf-armhf-libvirt-raw 12 saveresto

Re: [Xen-devel] [PATCH 00/24] xen/arm: Extend the usage of typesafe MFN

2017-06-15 Thread Stefano Stabellini
Hi Julien, thanks for the series! I committed patches 2, 4-15, 17,18. Cheers, Stefano On Tue, 13 Jun 2017, Julien Grall wrote: > Hello all, > > This patch series extend the usage of typesafe MFN in the ARM code. _mfn(...) > and mfn_x(...) are pushed further down in the call stack. > > Cheers

Re: [Xen-devel] [PATCH 24/24] xen/arm: create_xen_entries: Use typesafe MFN

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Add a bit more safety when using create_xen_entries. > > Also when destroying/modifying mapping, the MFN is currently not used. > Rather than passing _mfn(0) use INVALID_MFN to stay consistent with the > other usage. > > Signed-off-by: Julien Grall Rev

Re: [Xen-devel] [PATCH 23/24] xen/arm: livepatch: Redefine virt_to_mfn to support typesafe

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > The file xen/arch/arm/livepatch.c is using typesafe MFN in most of > the place. The only caller to virt_to_mfn is using with _mfn(...). > > To avoid extra _mfn(...), re-define virt_to_mfn within > xen/arch/arm/livepatch.c to handle typesafe MFN. > > Sign

Re: [Xen-devel] [PATCH 22/24] xen/arm: alternative: Redefine virt_to_mfn to support typesafe

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > The file xen/arch/arm/alternative.c is using typesafe MFN in most of > the place. The only caller to virt_to_mfn is using with _mfn(...). > > To avoid extra _mfn(...), re-define virt_to_mfn within > xen/arch/arm/alternative.c to handle typesafe MFN. > >

Re: [Xen-devel] [PATCH 21/24] xen/arm: domain_build: Redefine virt_to_mfn to support typesafe

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > The file xen/arch/arm/domain_build.c is using typesafe MFN in most of > the place. The only caller to virt_to_mfn is using prefixed with > _mfn(...). > > To avoid extra _mfn(...), re-define virt_to_mfn within > arch/arm/domain_build.c to handle typesafe M

Re: [Xen-devel] [PATCH 20/24] xen/arm: mm: Redefine virt_to_mfn to support typesafe

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > The file xen/arch/arm/mm.c is using the typesafe MFN in most of the > place. This requires all caller of virt_to_mfn to prefixed by _mfn(...). > > To avoid the extra _mfn(...), re-defined virt_to_mfn within arch/arm/mm.c > to handle typesafe MFN. > > Thi

Re: [Xen-devel] [PATCH 19/24] xen/arm: p2m: Redefine mfn_to_page and page_to_mfn to use typesafe

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > The file xen/arch/arm/p2m.c is using typesafe MFN in most of the place. > This requires caller to mfn_to_page and page_to_mfn to use _mfn/mfn_x. > > To avoid extra _mfn/mfn_x, re-define mfn_to_page and page_to_mfn within > xen/arch/arm/p2m.c to handle typ

Re: [Xen-devel] [PATCH 18/24] xen/arm: mm: Use typesafe MFN in dump_pt_walk

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/mm.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/xen/arch/arm/mm.c b/xen/arch/arm/mm.c > index 8573192e3a..452c1e26c3 100644 > --- a/xen

Re: [Xen-devel] [PATCH 17/24] xen/arm: mm: Use typesafe MFN in set_fixmap

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/acpi/lib.c | 4 ++-- > xen/arch/arm/kernel.c | 4 +--- > xen/arch/arm/mm.c | 4 ++-- > xen/arch/arm/platforms/vexpress.c | 2 +- > x

Re: [Xen-devel] [PATCH 16/24] xen/arm: mm: Use typesafe mfn for xenheap_mfn_*

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Add more safety when using xenheap_mfn_*. > > Signed-off-by: Julien Grall > --- > xen/arch/arm/mm.c| 16 > xen/arch/arm/setup.c | 18 +- > xen/include/asm-arm/mm.h | 11 ++- > 3 files changed, 23 inse

Re: [Xen-devel] [PATCH 15/24] xen/arm: Use the newly introduced MFN <-> MADDR and GFN <-> MADDR helpers

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Replace the following constructions: > - _gfn(paddr_to_pfn(...)) => gaddr_to_gfn(...) > - _mfn(paddr_to_pfn(...)) => maddr_to_mfn(...) > - pfn_to_paddr(mfn_x(...)) => mfn_to_maddr(...) > - pfn_to_paddr(gfn_x(...)) => gfn_to_gaddr(...)

Re: [Xen-devel] [PATCH 14/24] xen/arm: Introduce wrappers for MFN <-> MADDR and GFN <-> GADDR

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > The new wrappers will add more safety when converting an address to a > frame number (either machine or guest). A follow-up patch will use them > to simplify the code. > > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/inclu

Re: [Xen-devel] [PATCH 13/24] xen/arm: traps: Replace p2m_lookup(..., ..., NULL) by gfn_to_mfn(..., ...)

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > gfn_to_mfn is a wrapper of p2m_lookup which does not return the > p2m_type. > > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/traps.c | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git

Re: [Xen-devel] [PATCH 12/24] xen/arm: Replace DIV_ROUND_UP(..., PAGE_SIZE) by PFN_UP(...)

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > DIV_ROUND_UP(..., PAGE_SIZE) and PFN_UP(...) are equivalent. > > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/domain_build.c | 4 ++-- > xen/arch/arm/gic-v2.c | 2 +- > xen/arch/arm/gic-v3.c | 8 --

Re: [Xen-devel] [PATCH 11/24] xen/arm: mm: Replace __va(pfn_to_paddr(...)) by mfn_to_virt

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > __va(pfn_to_paddr(...)) and mfn_to_virt are equivalent. > > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/mm.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/xen/arch/arm/mm.c b/xen/arch/

Re: [Xen-devel] [PATCH 10/24] xen/arm: domain_build: Replace paddr_to_pfn(virt_to_maddr(.)) by virt_to_mfn(.)

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > paddr_to_pfn(virt_to_maddr(.)) and virt_to_mfn(.) are equivalent. > > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/domain_build.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/xen/arch/a

Re: [Xen-devel] [PATCH 09/24] xen/arm: Define mfn_to_page/page_to_mfn in term of __mfn_to_page/__page_to_mfn

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > This is matching the x86 side where the __* version is used if you need > to override the helpers in source files. > > At the same time, move the non-underscore version at the end of the > defintion and add a comment to explain them. > > Signed-off-by: J

Re: [Xen-devel] [PATCH 08/24] xen/arm: mm: Use typesafe MFN in mfn_to_xen_entry

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/mm.c | 33 + > 1 file changed, 17 insertions(+), 16 deletions(-) > > diff --git a/xen/arch/arm/mm.c b/xen/arch/arm/mm.c > index d164ed2e

Re: [Xen-devel] [PATCH 07/24] xen/arm: mm: Clean-up mfn_to_xen_entry

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > The physical address is computed from the machine frame number, so > checking if the physical address is page aligned is pointless. > > Furthermore, directly assigned the MFN to the corresponding field in the > entry rather than converting to a physical a

Re: [Xen-devel] [PATCH 06/24] xen/arm: mm: Fix coding style of mfn_to_xen_entry

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Fix the comment coding style and add a newline before the return. > > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/mm.c | 18 -- > 1 file changed, 12 insertions(+), 6 deletions(-) > > diff --git a/

Re: [Xen-devel] [PATCH 05/24] xen/arm: mm: Move mfn_to_xen_entry from page.h to mm.c

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > The file mm.c is the only user of mfn_to_xen_entry. This will also help > to use the typesafe MFN. > > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/mm.c | 65 > +++

Re: [Xen-devel] [PATCH 04/24] xen/arm: mm: Introduce clear_table and use it

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Add a new helper clear_table to clear a page table entry and invalidate > the cache. > > Signed-off-by: Julien Grall > --- > xen/arch/arm/mm.c | 22 -- > 1 file changed, 12 insertions(+), 10 deletions(-) > > diff --git a/xen/arch/ar

Re: [Xen-devel] [PATCH 03/24] xen/arm: setup: Remove bogus xenheap_mfn_end in setup_mm for arm64

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > xenheap_mfn_end is storing an MFN and not a physical address. Thankfully > xenheap_mfn_end is not used in the arm64 code. So drop it. That's fine, but in that case I would prefer to move the definition of xenheap_mfn_end under #ifdef CONFIG_ARM_32. In fac

[Xen-devel] [distros-debian-wheezy test] 71566: tolerable trouble: broken/pass

2017-06-15 Thread Platform Team regression test user
flight 71566 distros-debian-wheezy real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/71566/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: build-arm64 2 hosts-allocate broken never pass build-arm64-pvops

Re: [Xen-devel] [PATCH 02/24] xen/arm: gic-v2: Fix indentation in gicv2_map_hwdom_extra_mappings

2017-06-15 Thread Stefano Stabellini
On Tue, 13 Jun 2017, Julien Grall wrote: > Signed-off-by: Julien Grall Reviewed-by: Stefano Stabellini > --- > xen/arch/arm/gic-v2.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/xen/arch/arm/gic-v2.c b/xen/arch/arm/gic-v2.c > index 270a1362ec..f8124e5e54 10064

Re: [Xen-devel] [PATCH 2/2] xen/arm: lpae: Fix comments coding style

2017-06-15 Thread Andrew Cooper
On 15/06/2017 21:30, Julien Grall wrote: > Also adding one missing full stop. > > Signed-off-by: Julien Grall > --- > xen/include/asm-arm/lpae.h | 45 ++--- > 1 file changed, 30 insertions(+), 15 deletions(-) > > diff --git a/xen/include/asm-arm/lpae.h b/xe

[Xen-devel] [xen-4.9-testing test] 110453: regressions - FAIL

2017-06-15 Thread osstest service owner
flight 110453 xen-4.9-testing real [real] http://logs.test-lab.xenproject.org/osstest/logs/110453/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-i386-xl-qemut-win7-amd64 15 guest-localmigrate/x10 fail REGR. vs. 110417 test-amd6

[Xen-devel] [distros-debian-squeeze test] 71561: tolerable trouble: broken/fail/pass

2017-06-15 Thread Platform Team regression test user
flight 71561 distros-debian-squeeze real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/71561/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-amd64-amd64-i386-squeeze-netboot-pygrub 9 debian-di-install fail like 71523 test-amd64-i

[Xen-devel] [xen-4.6-testing baseline-only test] 71559: regressions - FAIL

2017-06-15 Thread Platform Team regression test user
This run is configured for baseline tests only. flight 71559 xen-4.6-testing real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/71559/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-xtf-amd64-amd64-120 xtf/test-hvm32-

Re: [Xen-devel] EL0 app, stubdoms on ARM conf call

2017-06-15 Thread Volodymyr Babchuk
On 15 June 2017 at 23:14, Stefano Stabellini wrote: >> > If so, would Wednesday the 28th of June at 9AM PST work for you? >> I would prefer later time (like 5PM), but 9AM also works for me. > > Wait, did you get the timezone right? > > 1) 9AM PST = 5PM London = 7PM Kyiv > > > I could do 5PM PST wi

[Xen-devel] [PATCH 1/2] xen/arm: Move LPAE definition in a separate header

2017-06-15 Thread Julien Grall
page.h is getting bigger. Move out every LPAE definitions in a separate header. There is no functional changes. Signed-off-by: Julien Grall --- xen/include/asm-arm/lpae.h | 169 + xen/include/asm-arm/page.h | 152 +--

[Xen-devel] [PATCH 2/2] xen/arm: lpae: Fix comments coding style

2017-06-15 Thread Julien Grall
Also adding one missing full stop. Signed-off-by: Julien Grall --- xen/include/asm-arm/lpae.h | 45 ++--- 1 file changed, 30 insertions(+), 15 deletions(-) diff --git a/xen/include/asm-arm/lpae.h b/xen/include/asm-arm/lpae.h index 1e6a68926e..6244240ca0 1

[Xen-devel] [PATCH 0/2] xen/arm: Move LPAE definition in a separate header.

2017-06-15 Thread Julien Grall
This small patch series is moving out LPAE definition from page.h. This is based on my series "xen/arm: Extend usage of typesafe MFN" [1] due to a small conflict with patch #5. Cheers, [1] https://lists.xen.org/archives/html/xen-devel/2017-06/msg01361.html Julien Grall (2): xen/arm: Move LPAE

Re: [Xen-devel] EL0 app, stubdoms on ARM conf call

2017-06-15 Thread Stefano Stabellini
On Thu, 15 Jun 2017, Volodymyr Babchuk wrote: > Hello Stefano, > > On 15 June 2017 at 21:21, Stefano Stabellini wrote: > > Would you be up for joining a conf call to discuss EL0 apps and stubdoms > > on ARM in preparation for Xen Developer Summit? > > > > If so, would Wednesday the 28th of June a

Re: [Xen-devel] [RFC PATCH v3 06/10] arm/mem_access: Introduce GV2M_EXEC permission

2017-06-15 Thread Julien Grall
Hi Sergej, On 06/15/2017 12:05 PM, Sergej Proskurin wrote: We extend the current implementation by an additional permission, GV2M_EXEC, which will be used to describe execute permissions of PTE's as part of our guest translation table walk implementation. Signed-off-by: Sergej Proskurin Acke

Re: [Xen-devel] [RFC PATCH v3 04/10] arm/mem_access: Add short-descriptor pte typedefs

2017-06-15 Thread Julien Grall
Hi Sergej, On 06/15/2017 12:05 PM, Sergej Proskurin wrote: The current implementation does not provide appropriate types for short-descriptor translation table entries. As such, this commit adds new types, which simplify managing the respective translation table entries. Signed-off-by: Sergej P

Re: [Xen-devel] [RFC PATCH v3 05/10] arm/p2m: Make PTE helpers publicly available

2017-06-15 Thread Julien Grall
Hi Sergej, On 06/15/2017 12:05 PM, Sergej Proskurin wrote: In this commit we make the p2m_* helpers, which access PTE properties in a simplified way, publicly available. This is due to the fact that the helpers will be used in guest_walk.c in one of the following commits. Signed-off-by: Sergej

Re: [Xen-devel] [RFC PATCH v3 04/10] arm/mem_access: Add short-descriptor pte typedefs

2017-06-15 Thread Andrew Cooper
On 15/06/17 20:44, Julien Grall wrote: > Hi Andrew, > > On 06/15/2017 01:03 PM, Andrew Cooper wrote: >> On 15/06/17 12:05, Sergej Proskurin wrote: >>> The current implementation does not provide appropriate types for >>> short-descriptor translation table entries. As such, this commit >>> adds new

Re: [Xen-devel] [RFC PATCH v3 04/10] arm/mem_access: Add short-descriptor pte typedefs

2017-06-15 Thread Julien Grall
Hi Andrew, On 06/15/2017 01:03 PM, Andrew Cooper wrote: On 15/06/17 12:05, Sergej Proskurin wrote: The current implementation does not provide appropriate types for short-descriptor translation table entries. As such, this commit adds new types, which simplify managing the respective translatio

Re: [Xen-devel] [RFC PATCH v3 03/10] arm/mem_access: Add defines supporting PTs with varying page sizes

2017-06-15 Thread Julien Grall
Hi Sergej, On 06/15/2017 12:05 PM, Sergej Proskurin wrote: The ARMv8 architecture supports pages with different (4K, 16K, and 64K) sizes. To enable guest page table walks for various configurations, this commit extends the defines and helpers of the current implementation. Signed-off-by: Sergej

Re: [Xen-devel] EL0 app, stubdoms on ARM conf call

2017-06-15 Thread Volodymyr Babchuk
Hello Stefano, On 15 June 2017 at 21:21, Stefano Stabellini wrote: > Would you be up for joining a conf call to discuss EL0 apps and stubdoms > on ARM in preparation for Xen Developer Summit? > > If so, would Wednesday the 28th of June at 9AM PST work for you? I would prefer later time (like 5PM)

[Xen-devel] [PATCH v4 12/18] xen/pvcalls: implement poll command

2017-06-15 Thread Stefano Stabellini
Implement poll on passive sockets by requesting a delayed response with mappass->reqcopy, and reply back when there is data on the passive socket. Poll on active socket is unimplemented as by the spec, as the frontend should just wait for events and check the indexes on the indexes page. Only sup

[Xen-devel] [PATCH v4 00/18] introduce the Xen PV Calls backend

2017-06-15 Thread Stefano Stabellini
Hi all, this series introduces the backend for the newly introduced PV Calls procotol. PV Calls is a paravirtualized protocol that allows the implementation of a set of POSIX functions in a different domain. The PV Calls frontend sends POSIX function calls to the backend, which implements them an

[Xen-devel] [PATCH v4 14/18] xen/pvcalls: disconnect and module_exit

2017-06-15 Thread Stefano Stabellini
Implement backend_disconnect. Call pvcalls_back_release_active on active sockets and pvcalls_back_release_passive on passive sockets. Implement module_exit by calling backend_disconnect on frontend connections. Signed-off-by: Stefano Stabellini CC: boris.ostrov...@oracle.com CC: jgr...@suse.com

[Xen-devel] [PATCH v4 04/18] xen/pvcalls: xenbus state handling

2017-06-15 Thread Stefano Stabellini
Introduce the code to handle xenbus state changes. Implement the probe function for the pvcalls backend. Write the supported versions, max-page-order and function-calls nodes to xenstore, as required by the protocol. Introduce stub functions for disconnecting/connecting to a frontend. Signed-off

[Xen-devel] [PATCH v4 07/18] xen/pvcalls: implement socket command

2017-06-15 Thread Stefano Stabellini
Just reply with success to the other end for now. Delay the allocation of the actual socket to bind and/or connect. Signed-off-by: Stefano Stabellini CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-back.c | 27 +++ 1 file changed, 27 insertions(

[Xen-devel] [PATCH v4 01/18] xen: introduce the pvcalls interface header

2017-06-15 Thread Stefano Stabellini
Introduce the C header file which defines the PV Calls interface. It is imported from xen/include/public/io/pvcalls.h. Signed-off-by: Stefano Stabellini Reviewed-by: Boris Ostrovsky CC: konrad.w...@oracle.com CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- include/xen/interface/io/pvcall

[Xen-devel] [PATCH v4 13/18] xen/pvcalls: implement release command

2017-06-15 Thread Stefano Stabellini
Release both active and passive sockets. For active sockets, make sure to avoid possible conflicts with the ioworker reading/writing to those sockets concurrently. Set map->release to let the ioworker know atomically that the socket will be released soon, then wait until the ioworker finishes (flus

[Xen-devel] [PATCH v4 02/18] xen/pvcalls: introduce the pvcalls xenbus backend

2017-06-15 Thread Stefano Stabellini
Introduce a xenbus backend 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 Reviewed-by: Boris Ostrovsky CC: boris.ostrov...@oracle.

[Xen-devel] [PATCH v4 10/18] xen/pvcalls: implement listen command

2017-06-15 Thread Stefano Stabellini
Call inet_listen to implement the listen command. Signed-off-by: Stefano Stabellini CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-back.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/drivers/xen/pvcalls-back.c b/drivers/xen/pvcalls-back.c i

[Xen-devel] [PATCH v4 08/18] xen/pvcalls: implement connect command

2017-06-15 Thread Stefano Stabellini
Allocate a socket. Keep track of socket <-> ring mappings with a new data structure, called sock_mapping. Implement the connect command by calling inet_stream_connect, and mapping the new indexes page and data ring. Allocate a workqueue and a work_struct, called ioworker, to perform reads and write

[Xen-devel] [PATCH v4 16/18] xen/pvcalls: implement read

2017-06-15 Thread Stefano Stabellini
When an active socket has data available, increment the io and read counters, and schedule the ioworker. Implement the read function by reading from the socket, writing the data to the data ring. Set in_error on error. Signed-off-by: Stefano Stabellini CC: boris.ostrov...@oracle.com CC: jgr...@

[Xen-devel] [PATCH v4 17/18] xen/pvcalls: implement write

2017-06-15 Thread Stefano Stabellini
When the other end notifies us that there is data to be written (pvcalls_back_conn_event), increment the io and write counters, and schedule the ioworker. Implement the write function called by ioworker by reading the data from the data ring, writing it to the socket by calling inet_sendmsg. Set

[Xen-devel] [PATCH v4 09/18] xen/pvcalls: implement bind command

2017-06-15 Thread Stefano Stabellini
Allocate a socket. Track the allocated passive sockets with a new data structure named sockpass_mapping. It contains an unbound workqueue to schedule delayed work for the accept and poll commands. It also has a reqcopy field to be used to store a copy of a request for delayed work. Reads/writes to

[Xen-devel] [PATCH v4 15/18] xen/pvcalls: implement the ioworker functions

2017-06-15 Thread Stefano Stabellini
We have one ioworker per socket. Each ioworker goes through the list of outstanding read/write requests. Once all requests have been dealt with, it returns. We use one atomic counter per socket for "read" operations and one for "write" operations to keep track of the reads/writes to do. We also u

[Xen-devel] [PATCH v4 06/18] xen/pvcalls: handle commands from the frontend

2017-06-15 Thread Stefano Stabellini
When the other end notifies us that there are commands to be read (pvcalls_back_event), wake up the backend thread to parse the command. The command ring works like most other Xen rings, so use the usual ring macros to read and write to it. The functions implementing the commands are empty stubs f

[Xen-devel] [PATCH v4 11/18] xen/pvcalls: implement accept command

2017-06-15 Thread Stefano Stabellini
Implement the accept command by calling inet_accept. To avoid blocking in the kernel, call inet_accept(O_NONBLOCK) from a workqueue, which get scheduled on sk_data_ready (for a passive socket, it means that there are connections to accept). Use the reqcopy field to store the request. Accept the ne

[Xen-devel] [PATCH v4 05/18] xen/pvcalls: connect to a frontend

2017-06-15 Thread Stefano Stabellini
Introduce a per-frontend data structure named pvcalls_fedata. It contains pointers to the command ring, its event channel, a list of active sockets and a tree of passive sockets (passing sockets need to be looked up from the id on listen, accept and poll commands, while active sockets only on relea

[Xen-devel] [PATCH v4 18/18] xen: introduce a Kconfig option to enable the pvcalls backend

2017-06-15 Thread Stefano Stabellini
Also add pvcalls-back to the Makefile. Signed-off-by: Stefano Stabellini CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/Kconfig | 12 drivers/xen/Makefile | 1 + 2 files changed, 13 insertions(+) diff --git a/drivers/xen/Kconfig b/drivers/xen/Kconfig index f15

[Xen-devel] [PATCH v4 03/18] xen/pvcalls: initialize the module and register the xenbus backend

2017-06-15 Thread Stefano Stabellini
Keep a list of connected frontends. Use a semaphore to protect list accesses. Signed-off-by: Stefano Stabellini Reviewed-by: Boris Ostrovsky CC: boris.ostrov...@oracle.com CC: jgr...@suse.com --- drivers/xen/pvcalls-back.c | 22 ++ 1 file changed, 22 insertions(+) diff --gi

Re: [Xen-devel] [PATCH 2/2] x86/altp2m: Add a hvmop for setting the suppress #VE bit

2017-06-15 Thread Tamas K Lengyel
On Fri, Jun 9, 2017 at 10:51 AM, Adrian Pop wrote: > Introduce a new hvmop, HVMOP_altp2m_set_suppress_ve, which allows a > privileged domain to change the value of the #VE suppress bit for a > page. > > Add a libxc wrapper for invoking this hvmop. > > Signed-off-by: Adrian Pop > --- > tools/libx

Re: [Xen-devel] [PATCH v3 06/18] xen/pvcalls: handle commands from the frontend

2017-06-15 Thread Stefano Stabellini
On Thu, 15 Jun 2017, Boris Ostrovsky wrote: > On 06/14/2017 05:03 PM, Stefano Stabellini wrote: > > On Mon, 12 Jun 2017, Boris Ostrovsky wrote: > >>> + > >>> static void pvcalls_back_work(struct work_struct *work) > >>> { > >>> + struct pvcalls_fedata *priv = container_of(work, > >>> + st

Re: [Xen-devel] [PATCH 1/2] x86/mm: Change default value for suppress #VE in set_mem_access()

2017-06-15 Thread Tamas K Lengyel
On Fri, Jun 9, 2017 at 10:51 AM, Adrian Pop wrote: > From: Vlad Ioan Topan > > The default value for the "suppress #VE" bit set by set_mem_access() > currently depends on whether the call is made from the same domain (the > bit is set when called from another domain and cleared if called from > t

Re: [Xen-devel] [PATCH 15/24] xen/arm: Use the newly introduced MFN <-> MADDR and GFN <-> MADDR helpers

2017-06-15 Thread Tamas K Lengyel
On Tue, Jun 13, 2017 at 10:13 AM, Julien Grall wrote: > Replace the following constructions: > - _gfn(paddr_to_pfn(...)) => gaddr_to_gfn(...) > - _mfn(paddr_to_pfn(...)) => maddr_to_mfn(...) > - pfn_to_paddr(mfn_x(...)) => mfn_to_maddr(...) > - pfn_to_paddr(gfn_x(...)) => gfn

Re: [Xen-devel] [RFC PATCH v3 10/10] arm/mem_access: Walk the guest's pt in software

2017-06-15 Thread Tamas K Lengyel
On Thu, Jun 15, 2017 at 5:05 AM, Sergej Proskurin wrote: > In this commit, we make use of the gpt walk functionality introduced in > the previous commits. If mem_access is active, hardware-based gva to ipa > translation might fail, as gva_to_ipa uses the guest's translation > tables, access to whi

Re: [Xen-devel] Next Xen ARM community call - 21st June 2017

2017-06-15 Thread Stefano Stabellini
On Thu, 15 Jun 2017, Julien Grall wrote: > Hi all, > > I would suggest to organize the next Xen ARM community on Wednesday 21st June > at 5PM BST. Any opinions? It works for me. FYI I sent a separate invite to discuss EL0 apps and stubdoms on ARM (alpine.DEB.2.10.1706151117090.12156@sstabellini-T

[Xen-devel] EL0 app, stubdoms on ARM conf call

2017-06-15 Thread Stefano Stabellini
Hi all, Would you be up for joining a conf call to discuss EL0 apps and stubdoms on ARM in preparation for Xen Developer Summit? If so, would Wednesday the 28th of June at 9AM PST work for you? I realize we also have the ARM community call next well, but this is a large topic which deserves an e

Re: [Xen-devel] [PATCH v3 11/18] xen/pvcalls: implement accept command

2017-06-15 Thread Stefano Stabellini
On Thu, 15 Jun 2017, Juergen Gross wrote: > On 14/06/17 21:27, Stefano Stabellini wrote: > > On Wed, 14 Jun 2017, Juergen Gross wrote: > >> On 14/06/17 02:47, Stefano Stabellini wrote: > >>> On Tue, 13 Jun 2017, Juergen Gross wrote: > On 02/06/17 21:31, Stefano Stabellini wrote: > > Implem

Re: [Xen-devel] [RFC PATCH] docs: add README.atomic

2017-06-15 Thread Stefano Stabellini
On Thu, 15 Jun 2017, Jan Beulich wrote: > >>> Stefano Stabellini 06/15/17 2:27 AM >>> > >On Wed, 14 Jun 2017, Jan Beulich wrote: > >> >>> Stefano Stabellini 06/14/17 8:45 PM >>> > >> >On Wed, 14 Jun 2017, Jan Beulich wrote: > >> >> > +What ACCESS_ONCE does *not* guarantee though is this access is

[Xen-devel] [distros-debian-snapshot test] 71558: tolerable trouble: blocked/broken/fail/pass

2017-06-15 Thread Platform Team regression test user
flight 71558 distros-debian-snapshot real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/71558/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-amd64-amd64-amd64-current-netinst-pygrub 9 debian-di-install fail blocked in 71515 test

Re: [Xen-devel] [RFC PATCH] docs: add README.atomic

2017-06-15 Thread Andre Przywara
Hi Jan, thanks for spending your time on this mind boggling exercise! On 14/06/17 10:12, Jan Beulich wrote: On 13.06.17 at 17:25, wrote: >> as mentioned in my previous mail, I consider this more of a discussion >> base that an actual patch. I am by no means an expert in this area, so >> par

[Xen-devel] Patch added to scsi: scsi: xen-scsifront: Remove code that zeroes driver-private command data

2017-06-15 Thread James Bottomley
Your commit: scsi: xen-scsifront: Remove code that zeroes driver-private command data Since the SCSI core zeroes driver-private command data, remove that code from the xen-scsifront driver. Signed-off-by: Bart Van Assche Reviewed-by: Hannes Reinecke Reviewed-by:

Re: [Xen-devel] [PATCH 1/4] xen: credit2: implement utilization cap

2017-06-15 Thread Anshul Makkar
On 13/06/2017 22:13, Dario Faggioli wrote: On Tue, 2017-06-13 at 17:07 +0100, Anshul Makkar wrote: On 12/06/2017 14:19, Dario Faggioli wrote: @@ -92,6 +92,82 @@ */ what I want to ask is that if the budget of the domain is replenished, but credit for the vcpus of that domain is not available

[Xen-devel] [linux-3.18 test] 110441: tolerable FAIL - PUSHED

2017-06-15 Thread osstest service owner
flight 110441 linux-3.18 real [real] http://logs.test-lab.xenproject.org/osstest/logs/110441/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-arm64-arm64-libvirt-xsm 1 build-check(1) blocked n/a test-arm64-arm64-xl 1 build-check

[Xen-devel] [ovmf baseline-only test] 71567: tolerable FAIL

2017-06-15 Thread Platform Team regression test user
This run is configured for baseline tests only. flight 71567 ovmf real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/71567/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): build-amd64-libvirt 5 libvirt-buildfai

Re: [Xen-devel] [RFC PATCH 0/4] Per-domain locking in xl

2017-06-15 Thread Jan Beulich
>>> Wei Liu 06/14/17 7:19 PM >>> >It has always been the case that different xl processes can manipulate the same >domain at the same time. This could be problematic. > >This series attempts to provide facility for xl to have a per-domain lock. This >lock should be used whenever xl manipulates an

Re: [Xen-devel] [PATCH v3 06/18] xen/pvcalls: handle commands from the frontend

2017-06-15 Thread Boris Ostrovsky
On 06/14/2017 05:03 PM, Stefano Stabellini wrote: > On Mon, 12 Jun 2017, Boris Ostrovsky wrote: >>> + >>> static void pvcalls_back_work(struct work_struct *work) >>> { >>> + struct pvcalls_fedata *priv = container_of(work, >>> + struct pvcalls_fedata, register_work); >>> + int notif

[Xen-devel] [xen-4.8-testing test] 110437: tolerable FAIL - PUSHED

2017-06-15 Thread osstest service owner
flight 110437 xen-4.8-testing real [real] http://logs.test-lab.xenproject.org/osstest/logs/110437/ Failures :-/ but no regressions. Tests which are failing intermittently (not blocking): test-armhf-armhf-xl-credit2 16 guest-start.2fail in 110387 pass in 110437 test-amd64-amd64-xl-qemut-deb

[Xen-devel] [linux-next test] 110434: regressions - FAIL

2017-06-15 Thread osstest service owner
flight 110434 linux-next real [real] http://logs.test-lab.xenproject.org/osstest/logs/110434/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-amd64-libvirt-pair 20 guest-start/debian fail REGR. vs. 110427 test-amd64-i386-libv

Re: [Xen-devel] [RFC PATCH v3 04/10] arm/mem_access: Add short-descriptor pte typedefs

2017-06-15 Thread Andrew Cooper
On 15/06/17 12:05, Sergej Proskurin wrote: > The current implementation does not provide appropriate types for > short-descriptor translation table entries. As such, this commit adds new > types, which simplify managing the respective translation table entries. > > Signed-off-by: Sergej Proskurin

  1   2   >