Re: [Xen-devel] [PATCH v3.1 08/15] x86/vtd: fix mapping of RMRR regions

2016-11-07 Thread Jan Beulich
>>> On 04.11.16 at 18:25, wrote: > On Fri, Nov 04, 2016 at 11:08:21AM -0600, Jan Beulich wrote: >> >>> On 04.11.16 at 17:19, wrote: >> > On Fri, Nov 04, 2016 at 10:13:08AM -0600, Jan Beulich wrote: >> >> >>> On 04.11.16 at 16:33, wrote: >> >> > --- a/xen/include/asm-x86/p2m.h >> >> > +++ b/xen/i

[Xen-devel] [PATCH v7 1/6] VMX: Permanently assign PI hook vmx_pi_switch_to()

2016-11-07 Thread Feng Wu
PI hook vmx_pi_switch_to() is needed even when any previously assigned device is detached from the domain. Since 'SN' bit is also used to control the CPU side PI and we change the state of SN bit in these two functions, then evaluate this bit in vmx_deliver_posted_intr() when trying to deliver the

[Xen-devel] [PATCH v7 6/6] VMX: Fixup PI descriptor when cpu is offline

2016-11-07 Thread Feng Wu
When cpu is offline, we need to move all the vcpus in its blocking list to another online cpu, this patch handles it. Signed-off-by: Feng Wu Reviewed-by: Jan Beulich --- v7: - Pass unsigned int to vmx_pi_desc_fixup() v6: - Carefully suppress 'SN' to avoid missing notification event during movin

[Xen-devel] [PATCH v7 5/6] VT-d: Some cleanups

2016-11-07 Thread Feng Wu
Use type-safe structure assignment instead of memcpy() Use sizeof(*iremap_entry). Signed-off-by: Feng Wu --- v7: - Remove a useless cleanup v6: - More descripion about the patch xen/drivers/passthrough/vtd/intremap.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff -

[Xen-devel] [PATCH v7 2/6] VMX: Properly handle pi when all the assigned devices are removed

2016-11-07 Thread Feng Wu
This patch handles some corner cases when the last assigned device is removed from the domain. In this case we should carefully handle pi descriptor and the per-cpu blocking list, to make sure: - all the PI descriptor are in the right state when next time a devices is assigned to the domain again.

[Xen-devel] [PATCH v7 4/6] VT-d: No need to set irq affinity for posted format IRTE

2016-11-07 Thread Feng Wu
We don't set the affinity for posted format IRTE, since the destination of these interrupts is vCPU and the vCPU affinity is set during vCPU scheduling. Signed-off-by: Feng Wu --- v7: - Compare all the field in IRTE to justify whether we can suppress the update v6: - Make pi_can_suppress_irte_up

[Xen-devel] [PATCH v7 0/6] VMX: Properly handle pi descriptor and per-cpu blocking list

2016-11-07 Thread Feng Wu
The current VT-d PI related code may operate incorrectly in the following scenarios: 1. When the last assigned device is dettached from the domain, all the PI related hooks are removed then, however, the vCPU can be blocked, switched to another pCPU, etc, all without the aware of PI. After the next

[Xen-devel] [PATCH v7 3/6] VMX: Make sure PI is in proper state before install the hooks

2016-11-07 Thread Feng Wu
We may hit the last ASSERT() in vmx_vcpu_block in the current code, since vmx_vcpu_block() may get called before vmx_pi_switch_to() has been installed or executed. Here We use cmpxchg to update the NDST field, this can make sure we only update the NDST when vmx_pi_switch_to() has not been called. S

[Xen-devel] [PATCH v7 4/6] VT-d: No need to set irq affinity for posted format IRTE

2016-11-07 Thread Feng Wu
We don't set the affinity for posted format IRTE, since the destination of these interrupts is vCPU and the vCPU affinity is set during vCPU scheduling. Signed-off-by: Feng Wu --- v7: - Compare all the field in IRTE to justify whether we can suppress the update v6: - Make pi_can_suppress_irte_up

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Jan Beulich
>>> On 05.11.16 at 18:22, wrote: > On 11/02/2016 12:55 AM, Andrew Cooper wrote: >> On 01/11/2016 22:17, Andrei Vlad LUTAS wrote: > First of all, to answer your original question: the injection decision > is made when the introspection logic needs to inspect a page that is > not present

[Xen-devel] [PATCH] IOMMU: replace ASSERT()s checking for NULL

2016-11-07 Thread Jan Beulich
Avoid NULL derefs on non-debug builds. Coverity ID: 1055650 Signed-off-by: Jan Beulich --- a/xen/drivers/passthrough/io.c +++ b/xen/drivers/passthrough/io.c @@ -165,7 +165,11 @@ static void pt_irq_time_out(void *data) spin_lock(&irq_map->dom->event_lock); dpci = domain_get_irq_dpci(

[Xen-devel] [PATCH] x86/traps: replace ASSERT() checking array bounds

2016-11-07 Thread Jan Beulich
Avoid out of bounds accesses on non-debug builds. Coverity ID: 1055744 Signed-off-by: Jan Beulich --- a/xen/arch/x86/traps.c +++ b/xen/arch/x86/traps.c @@ -3764,7 +3764,11 @@ void async_exception_cleanup(struct vcpu if ( (curr->async_exception_mask ^ curr->async_

[Xen-devel] [PATCH] x86/shutdown: add fall-through comment

2016-11-07 Thread Jan Beulich
Coverity ID: 1362037 Signed-off-by: Jan Beulich --- a/xen/arch/x86/shutdown.c +++ b/xen/arch/x86/shutdown.c @@ -541,6 +541,7 @@ void machine_restart(unsigned int delay_ { case BOOT_INVALID: ASSERT_UNREACHABLE(); +/* fall through */ case BOOT_KB

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Razvan Cojocaru
On 11/07/2016 10:45 AM, Jan Beulich wrote: On 05.11.16 at 18:22, wrote: >> On 11/02/2016 12:55 AM, Andrew Cooper wrote: >>> On 01/11/2016 22:17, Andrei Vlad LUTAS wrote: >> First of all, to answer your original question: the injection decision >> is made when the introspection logic n

Re: [Xen-devel] [PATCH 07/10] pvh/ioreq: Install handlers for ACPI-related PVH IO accesses

2016-11-07 Thread Paul Durrant
> -Original Message- > From: Boris Ostrovsky [mailto:boris.ostrov...@oracle.com] > Sent: 06 November 2016 21:43 > To: xen-devel@lists.xen.org > Cc: jbeul...@suse.com; Andrew Cooper ; > Wei Liu ; Ian Jackson ; Roger > Pau Monne ; Boris Ostrovsky > ; Paul Durrant > Subject: [PATCH 07/10] pvh

Re: [Xen-devel] [PATCH 08/10] pvh/acpi: Handle ACPI accesses for PVH guests

2016-11-07 Thread Paul Durrant
> -Original Message- > From: Boris Ostrovsky [mailto:boris.ostrov...@oracle.com] > Sent: 06 November 2016 21:43 > To: xen-devel@lists.xen.org > Cc: jbeul...@suse.com; Andrew Cooper ; > Wei Liu ; Ian Jackson ; Roger > Pau Monne ; Boris Ostrovsky > ; Paul Durrant > Subject: [PATCH 08/10] pvh

Re: [Xen-devel] [PATCH] IOMMU: replace ASSERT()s checking for NULL

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 10:24, wrote: > --- a/xen/drivers/passthrough/io.c > +++ b/xen/drivers/passthrough/io.c > @@ -165,7 +165,11 @@ static void pt_irq_time_out(void *data) > spin_lock(&irq_map->dom->event_lock); > > dpci = domain_get_irq_dpci(irq_map->dom); > -ASSERT(dpci); > +if

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 10:37, wrote: > The problem there is that vmx_idtv_reinject() is a corner case: it > writes VM_ENTRY_INTR_INFO directly, and this can happen _before_ the > guest exits with, let's say, an EPT vm_event. > > In that case, the guest has exited, there's already an interrupt > pendi

Re: [Xen-devel] [PATCH] x86/traps: replace ASSERT() checking array bounds

2016-11-07 Thread Andrew Cooper
On 07/11/16 09:25, Jan Beulich wrote: > Avoid out of bounds accesses on non-debug builds. > > Coverity ID: 1055744 > > Signed-off-by: Jan Beulich Reviewed-by: Andrew Cooper > > --- a/xen/arch/x86/traps.c > +++ b/xen/arch/x86/traps.c > @@ -3764,7 +3764,11 @@ void async_exception_cleanup(struct v

Re: [Xen-devel] [PATCH] IOMMU: replace ASSERT()s checking for NULL

2016-11-07 Thread Andrew Cooper
On 07/11/16 09:24, Jan Beulich wrote: > Avoid NULL derefs on non-debug builds. > > Coverity ID: 1055650 > > Signed-off-by: Jan Beulich Reviewed-by: Andrew Cooper > > --- a/xen/drivers/passthrough/io.c > +++ b/xen/drivers/passthrough/io.c > @@ -165,7 +165,11 @@ static void pt_irq_time_out(void *

Re: [Xen-devel] [PATCH] x86/traps: replace ASSERT() checking array bounds

2016-11-07 Thread Wei Liu
On Mon, Nov 07, 2016 at 10:22:56AM +, Andrew Cooper wrote: > On 07/11/16 09:25, Jan Beulich wrote: > > Avoid out of bounds accesses on non-debug builds. > > > > Coverity ID: 1055744 > > > > Signed-off-by: Jan Beulich > > Reviewed-by: Andrew Cooper > Release-acked-by: Wei Liu

Re: [Xen-devel] [PATCH] x86/shutdown: add fall-through comment

2016-11-07 Thread Wei Liu
On Mon, Nov 07, 2016 at 02:26:11AM -0700, Jan Beulich wrote: > Coverity ID: 1362037 > > Signed-off-by: Jan Beulich > > --- a/xen/arch/x86/shutdown.c > +++ b/xen/arch/x86/shutdown.c > @@ -541,6 +541,7 @@ void machine_restart(unsigned int delay_ > { > case BOOT_INVALID: >

Re: [Xen-devel] [PATCH] IOMMU: replace ASSERT()s checking for NULL

2016-11-07 Thread Wei Liu
On Mon, Nov 07, 2016 at 10:30:37AM +, Andrew Cooper wrote: > On 07/11/16 09:24, Jan Beulich wrote: > > Avoid NULL derefs on non-debug builds. > > > > Coverity ID: 1055650 > > > > Signed-off-by: Jan Beulich > > Reviewed-by: Andrew Cooper > Release-acked-by: Wei Liu ___

Re: [Xen-devel] [PATCH] IOMMU: replace ASSERT()s checking for NULL

2016-11-07 Thread Andrew Cooper
On 07/11/16 09:53, Jan Beulich wrote: On 07.11.16 at 10:24, wrote: >> --- a/xen/drivers/passthrough/io.c >> +++ b/xen/drivers/passthrough/io.c >> @@ -165,7 +165,11 @@ static void pt_irq_time_out(void *data) >> spin_lock(&irq_map->dom->event_lock); >> >> dpci = domain_get_irq_dpci(

Re: [Xen-devel] [PATCH] x86/shutdown: add fall-through comment

2016-11-07 Thread Andrew Cooper
On 07/11/16 09:26, Jan Beulich wrote: > Coverity ID: 1362037 > > Signed-off-by: Jan Beulich Reviewed-by: Andrew Cooper > > --- a/xen/arch/x86/shutdown.c > +++ b/xen/arch/x86/shutdown.c > @@ -541,6 +541,7 @@ void machine_restart(unsigned int delay_ > { > case BOOT_INVALID: >

Re: [Xen-devel] [PATCH] xsm: add missing permissions discovered in testing

2016-11-07 Thread Wei Liu
On Mon, Nov 07, 2016 at 07:22:40AM +, Wei Liu wrote: > On Fri, Nov 04, 2016 at 11:35:20AM -0400, Daniel De Graaf wrote: > > Add two missing allow rules: > > > > 1. Device model domain construction uses getvcpucontext, discovered by > > Andrew Cooper in an (apparently) unrelated bisection. > >

Re: [Xen-devel] [PATCH 01/12] xen: introduce xenbus_read_unsigned()

2016-11-07 Thread David Vrabel
On 31/10/16 16:48, Juergen Gross wrote: > There are multiple instances of code reading an optional unsigned > parameter from Xenstore via xenbus_scanf(). Instead of repeating the > same code over and over add a service function doing the job. Reviewed-by: David Vrabel David

Re: [Xen-devel] [PATCH v2 1/2] Revert "xen/arm: platform: Drop the quirks callback"

2016-11-07 Thread Julien Grall
Hi Stefano, On 04/11/16 21:04, Stefano Stabellini wrote: This reverts commit 14fa16961b03a23e9b883e5f0ed06b6837a489d8. Do not reintroduce platform_dom0_evtchn_ppi. Signed-off-by: Stefano Stabellini Acked-by: Julien Grall Regards, -- Julien Grall __

Re: [Xen-devel] [PATCH 00/12] xen: add common function for reading optional value

2016-11-07 Thread David Vrabel
On 31/10/16 16:48, Juergen Gross wrote: > There are multiple instances of code reading an optional unsigned > parameter from Xenstore via xenbus_scanf(). Instead of repeating the > same code over and over add a service function doing the job and > replace the call of xenbus_scanf() with the call of

Re: [Xen-devel] [PATCH v2 2/2] Partially revert 21550029f709072aacf3b90edd574e7d3021b400

2016-11-07 Thread Julien Grall
Hi Stefano, On 04/11/16 21:04, Stefano Stabellini wrote: Commit 21550029f709072aacf3b90edd574e7d3021b400 removed the PLATFORM_QUIRK_GIC_64K_STRIDE quirk and introduced a way to automatically detect that the two GICC pages have a 64K stride. However the heuristic requires that the device tree fo

Re: [Xen-devel] [PATCH v2 0/2] Fix Xen boot on XGene

2016-11-07 Thread Wei Liu
On Fri, Nov 04, 2016 at 02:04:21PM -0700, Stefano Stabellini wrote: > Hi all, > > the following commit: > > commit 21550029f709072aacf3b90edd574e7d3021b400 > Author: Julien Grall > Date: Thu Oct 8 19:23:53 2015 +0100 > > xen/arm: gic-v2: Automatically detect aliased GIC400 > > > removed

Re: [Xen-devel] [PATCH 00/10] PVH VCPU hotplug support

2016-11-07 Thread Andrew Cooper
On 06/11/16 21:42, Boris Ostrovsky wrote: > This series adds support for ACPI-based VCPU hotplug for unprivileged > PVH guests. > > New XEN_DOMCTL_set_avail_vcpus is introduced and is called during > guest creation and in response to 'xl vcpu-set' command. This domctl > updates GPE0's status and en

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Razvan Cojocaru
On 11/07/2016 11:57 AM, Jan Beulich wrote: On 07.11.16 at 10:37, wrote: >> The problem there is that vmx_idtv_reinject() is a corner case: it >> writes VM_ENTRY_INTR_INFO directly, and this can happen _before_ the >> guest exits with, let's say, an EPT vm_event. >> >> In that case, the guest

[Xen-devel] [PATCH for-4.8 1/2] libxc: properly account for the page offset when copying ACPI data

2016-11-07 Thread Roger Pau Monne
Or else ACPI data is always copied at the start of the page pointed by guest_addr_out, ignoring the page offset. Signed-off-by: Roger Pau Monné --- Cc: Ian Jackson Cc: Wei Liu Cc: Boris Ostrovsky Cc: Konrad Rzeszutek Wilk --- tools/libxc/xc_dom_core.c | 3 +++ 1 file changed, 3 insertions(+)

[Xen-devel] [PATCH for-4.8 2/2] libxc: set rsdp pointer for PVHv2 guests

2016-11-07 Thread Roger Pau Monne
Set the address of the RSDP in the HVM start info structure for PVHv2 DomUs that have ACPI tables. Signed-off-by: Roger Pau Monné --- Cc: Ian Jackson Cc: Wei Liu Cc: Boris Ostrovsky Cc: Konrad Rzeszutek Wilk --- tools/libxc/xc_dom_x86.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/

[Xen-devel] [PATCH for-4.8 0/2] Minor ACPI fixes for PVHv2 DomU

2016-11-07 Thread Roger Pau Monne
This series includes two patches to fix some minor issues with PVHv2 and ACPI. Thanks, Roger. ___ Xen-devel mailing list Xen-devel@lists.xen.org https://lists.xen.org/xen-devel

[Xen-devel] [distros-debian-sid test] 68007: tolerable FAIL

2016-11-07 Thread Platform Team regression test user
flight 68007 distros-debian-sid real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/68007/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-amd64-i386-amd64-sid-netboot-pygrub 9 debian-di-install fail like 67967 test-amd64-amd64-i3

[Xen-devel] [OSSTEST PATCH] xtf: Always boot with loglvl=all guest_loglvl=all

2016-11-07 Thread Ian Jackson
CC: Andrew Cooper Signed-off-by: Ian Jackson --- make-flight | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/make-flight b/make-flight index 7bb536f..a374884 100755 --- a/make-flight +++ b/make-flight @@ -463,7 +463,7 @@ do_xtf_tests () { job_create_test test-xtf-$xena

[Xen-devel] [linux-3.10 test] 101975: regressions - FAIL

2016-11-07 Thread osstest service owner
flight 101975 linux-3.10 real [real] http://logs.test-lab.xenproject.org/osstest/logs/101975/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-amd64-amd64-pvgrub 6 xen-bootfail REGR. vs. 100648 test-amd64-amd64-xl

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 12:49, wrote: > On 11/07/2016 11:57 AM, Jan Beulich wrote: > On 07.11.16 at 10:37, wrote: >>> The problem there is that vmx_idtv_reinject() is a corner case: it >>> writes VM_ENTRY_INTR_INFO directly, and this can happen _before_ the >>> guest exits with, let's say, an EPT

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Razvan Cojocaru
On 11/07/2016 02:23 PM, Jan Beulich wrote: >> At this point it looks like the best solution is to simply discard the >> > non-architectural event if there's a pending architectural one, and add >> > a new vm_event, as suggested by Tamas, that notifies the application >> > that a trap has failed, or

Re: [Xen-devel] Xen on Qualcomm

2016-11-07 Thread Suresh Kanzariya
Hi Julien/Sameer, Do you have any updates on this? Your help on my specific questions will help me to whether should I go ahead or not. Thank You for your time in advance. Regards, Suresh On Thu, 3 Nov 2016 at 16:09 Suresh Kanzariya wrote: > Hi Sameer, > > I have not build it yet, but before

[Xen-devel] [xen-unstable-smoke test] 101996: tolerable all pass - PUSHED

2016-11-07 Thread osstest service owner
flight 101996 xen-unstable-smoke real [real] http://logs.test-lab.xenproject.org/osstest/logs/101996/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-amd64-amd64-libvirt 12 migrate-support-checkfail never pass test-armhf-armhf-xl 1

Re: [Xen-devel] [PATCH RFC] hvm: Allow triple fault to imply crash rather than reboot

2016-11-07 Thread Xuquan (Quan Xu)
On Feb 4, 2013, 6:25 AM, wrote: > While the triple fault action on native hardware will result in a system > reset, any modern operating system can and will make use of less violent > reboot methods. As a result, the most likely cause of a triple fault is a > fatal software bug. > > This patch all

Re: [Xen-devel] [PATCH for-4.8 1/2] libxc: properly account for the page offset when copying ACPI data

2016-11-07 Thread Andrew Cooper
On 07/11/16 11:55, Roger Pau Monne wrote: > Or else ACPI data is always copied at the start of the page pointed by > guest_addr_out, ignoring the page offset. > > Signed-off-by: Roger Pau Monné > --- > Cc: Ian Jackson > Cc: Wei Liu > Cc: Boris Ostrovsky > Cc: Konrad Rzeszutek Wilk > --- > too

Re: [Xen-devel] [OSSTEST PATCH] xtf: Always boot with loglvl=all guest_loglvl=all

2016-11-07 Thread Andrew Cooper
On 07/11/16 12:04, Ian Jackson wrote: > CC: Andrew Cooper > Signed-off-by: Ian Jackson This is good, but as pointed out by Jan, also requires adding VERBOSE_DEBUG to Kconfig to get domain logging. ~Andrew > --- > make-flight | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --g

Re: [Xen-devel] [PATCH RFC] hvm: Allow triple fault to imply crash rather than reboot

2016-11-07 Thread Andrew Cooper
On 07/11/16 12:56, Xuquan (Quan Xu) wrote: > On Feb 4, 2013, 6:25 AM, wrote: >> While the triple fault action on native hardware will result in a system >> reset, any modern operating system can and will make use of less violent >> reboot methods. As a result, the most likely cause of a triple fau

Re: [Xen-devel] [PATCH RFC] hvm: Allow triple fault to imply crash rather than reboot

2016-11-07 Thread Xuquan (Quan Xu)
On November 07, 2016 9:13 PM, Andrew Cooper wrote: >On 07/11/16 12:56, Xuquan (Quan Xu) wrote: >> 4) any ideas to reproduce triple fault? > >What do you mean by reproduce? Causing a triple fault is very easy from the >guest kernel. Yes, by reproduce.. indeed, we just implemented one when I sent o

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 13:27, wrote: > On 11/07/2016 02:23 PM, Jan Beulich wrote: >>> At this point it looks like the best solution is to simply discard the >>> > non-architectural event if there's a pending architectural one, and add >>> > a new vm_event, as suggested by Tamas, that notifies the appl

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Razvan Cojocaru
On 11/07/2016 03:20 PM, Jan Beulich wrote: On 07.11.16 at 13:27, wrote: >> On 11/07/2016 02:23 PM, Jan Beulich wrote: At this point it looks like the best solution is to simply discard the > non-architectural event if there's a pending architectural one, and add > a new vm_event,

Re: [Xen-devel] [PATCH] IOMMU: replace ASSERT()s checking for NULL

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 11:43, wrote: > On 07/11/16 09:53, Jan Beulich wrote: > On 07.11.16 at 10:24, wrote: >>> --- a/xen/drivers/passthrough/io.c >>> +++ b/xen/drivers/passthrough/io.c >>> @@ -165,7 +165,11 @@ static void pt_irq_time_out(void *data) >>> spin_lock(&irq_map->dom->event_lock);

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 14:44, wrote: > On 11/07/2016 03:20 PM, Jan Beulich wrote: > On 07.11.16 at 13:27, wrote: >>> On 11/07/2016 02:23 PM, Jan Beulich wrote: > At this point it looks like the best solution is to simply discard the >> non-architectural event if there's a pending architec

Re: [Xen-devel] [PATCH 07/10] pvh/ioreq: Install handlers for ACPI-related PVH IO accesses

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 04:39 AM, Paul Durrant wrote: >> -Original Message- >> From: Boris Ostrovsky [mailto:boris.ostrov...@oracle.com] >> Sent: 06 November 2016 21:43 >> To: xen-devel@lists.xen.org >> Cc: jbeul...@suse.com; Andrew Cooper ; >> Wei Liu ; Ian Jackson ; Roger >> Pau Monne ; Boris Ostro

Re: [Xen-devel] [PATCH 07/10] pvh/ioreq: Install handlers for ACPI-related PVH IO accesses

2016-11-07 Thread Paul Durrant
> -Original Message- > From: Boris Ostrovsky [mailto:boris.ostrov...@oracle.com] > Sent: 07 November 2016 14:01 > To: Paul Durrant ; xen-devel@lists.xen.org > Cc: jbeul...@suse.com; Andrew Cooper ; > Wei Liu ; Ian Jackson ; Roger > Pau Monne > Subject: Re: [PATCH 07/10] pvh/ioreq: Install

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Razvan Cojocaru
On 11/07/2016 03:53 PM, Jan Beulich wrote: On 07.11.16 at 14:44, wrote: >> On 11/07/2016 03:20 PM, Jan Beulich wrote: >> On 07.11.16 at 13:27, wrote: On 11/07/2016 02:23 PM, Jan Beulich wrote: >> At this point it looks like the best solution is to simply discard the >>> non-

Re: [Xen-devel] [PATCH 00/10] PVH VCPU hotplug support

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 06:41 AM, Andrew Cooper wrote: > On 06/11/16 21:42, Boris Ostrovsky wrote: >> This series adds support for ACPI-based VCPU hotplug for unprivileged >> PVH guests. >> >> New XEN_DOMCTL_set_avail_vcpus is introduced and is called during >> guest creation and in response to 'xl vcpu-set'

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Razvan Cojocaru
On 11/07/2016 03:53 PM, Jan Beulich wrote: On 07.11.16 at 14:44, wrote: >> On 11/07/2016 03:20 PM, Jan Beulich wrote: >> On 07.11.16 at 13:27, wrote: On 11/07/2016 02:23 PM, Jan Beulich wrote: >> At this point it looks like the best solution is to simply discard the >>> non-

Re: [Xen-devel] [PATCH for-4.8 2/2] libxc: set rsdp pointer for PVHv2 guests

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 06:55 AM, Roger Pau Monne wrote: > Set the address of the RSDP in the HVM start info structure for PVHv2 DomUs > that have ACPI tables. > > Signed-off-by: Roger Pau Monné > --- > Cc: Ian Jackson > Cc: Wei Liu > Cc: Boris Ostrovsky > Cc: Konrad Rzeszutek Wilk > --- > tools/libxc/

Re: [Xen-devel] [PATCH] IOMMU: replace ASSERT()s checking for NULL

2016-11-07 Thread Konrad Rzeszutek Wilk
On Mon, Nov 07, 2016 at 10:30:37AM +, Andrew Cooper wrote: > On 07/11/16 09:24, Jan Beulich wrote: > > Avoid NULL derefs on non-debug builds. > > > > Coverity ID: 1055650 > > > > Signed-off-by: Jan Beulich > > Reviewed-by: Andrew Cooper This introduces a bug: > > > > > --- a/xen/drivers/pa

Re: [Xen-devel] [PATCH 00/10] PVH VCPU hotplug support

2016-11-07 Thread Andrew Cooper
On 07/11/16 14:19, Boris Ostrovsky wrote: > On 11/07/2016 06:41 AM, Andrew Cooper wrote: >> On 06/11/16 21:42, Boris Ostrovsky wrote: >>> This series adds support for ACPI-based VCPU hotplug for unprivileged >>> PVH guests. >>> >>> New XEN_DOMCTL_set_avail_vcpus is introduced and is called during >

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 15:34, wrote: > My proposal was simply something along the lines of: > > diff --git a/xen/arch/x86/hvm/hvm.c b/xen/arch/x86/hvm/hvm.c > index 704fd64..58f5ae4 100644 > --- a/xen/arch/x86/hvm/hvm.c > +++ b/xen/arch/x86/hvm/hvm.c > @@ -535,8 +535,22 @@ void hvm_do_resume(struct v

[Xen-devel] [PATCH] xen: Fix xenpv machine initialisation

2016-11-07 Thread Anthony PERARD
When using QEMU for Xen PV guest, QEMU abort with: xen-common.c:118:xen_init: Object 0x7f2b8325dcb0 is not an instance of type generic-pc-machine This is because the machine 'xenpv' also use accel=xen. This fix 021746c131cdfeab9d82ff918795a9f18d20d7ae Signed-off-by: Anthony PERARD --- CC: Wei

[Xen-devel] Xen 4.6.4 released

2016-11-07 Thread Jan Beulich
All, I am pleased to announce the release of Xen 4.6.4. This is available immediately from its git repository http://xenbits.xen.org/gitweb/?p=xen.git;a=shortlog;h=refs/heads/stable-4.6 (tag RELEASE-4.6.4) or from the XenProject download page http://www.xenproject.org/downloads/xen-archives/xen-4

[Xen-devel] Xen 4.7.1 released

2016-11-07 Thread Jan Beulich
All, I am pleased to announce the release of Xen 4.7.1. This is available immediately from its git repository http://xenbits.xen.org/gitweb/?p=xen.git;a=shortlog;h=refs/heads/stable-4.7 (tag RELEASE-4.7.1) or from the XenProject download page http://www.xenproject.org/downloads/xen-archives/xen-4

Re: [Xen-devel] Xen on Qualcomm

2016-11-07 Thread Julien Grall
On 07/11/16 12:39, Suresh Kanzariya wrote: Hi Julien/Sameer, Hello Suresh, On Thu, 3 Nov 2016 at 16:09 Suresh Kanzariya mailto:skanzar...@gmail.com>> wrote: I have not build it yet, but before I started building and porting on 410 platform, I just want to make feasibility whether it

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Razvan Cojocaru
On 11/07/2016 04:59 PM, Jan Beulich wrote: On 07.11.16 at 15:34, wrote: >> My proposal was simply something along the lines of: >> >> diff --git a/xen/arch/x86/hvm/hvm.c b/xen/arch/x86/hvm/hvm.c >> index 704fd64..58f5ae4 100644 >> --- a/xen/arch/x86/hvm/hvm.c >> +++ b/xen/arch/x86/hvm/hvm.c >

Re: [Xen-devel] [PATCH 00/10] PVH VCPU hotplug support

2016-11-07 Thread Boris Ostrovsky
Boris Ostrovsky (10): x86/domctl: Add XEN_DOMCTL_set_avail_vcpus >>> Why is this necessary? Given that a paravirtual hotplug mechanism >>> already exists, why isn't its equivalent mechanism suitable? >> PV guests register a xenstore watch and the toolstack updates cpu's >> "available

[Xen-devel] [PATCH] IOMMU: release lock on new exit path

2016-11-07 Thread Jan Beulich
This was overlooked in 7b2842a414 ("IOMMU: replace ASSERT()s checking for NULL"). Reported-by: Konrad Rzeszutek Wilk Signed-off-by: Jan Beulich --- a/xen/drivers/passthrough/io.c +++ b/xen/drivers/passthrough/io.c @@ -168,6 +168,7 @@ static void pt_irq_time_out(void *data) if ( unlikely(!d

Re: [Xen-devel] [PATCH 01/10] x86/domctl: Add XEN_DOMCTL_set_avail_vcpus

2016-11-07 Thread Konrad Rzeszutek Wilk
On Sun, Nov 06, 2016 at 04:42:34PM -0500, Boris Ostrovsky wrote: > This domctl is called when a VCPU is hot-(un)plugged to a guest (via > 'xl vcpu-set'). While this currently is only intended to be needed by > PVH guests we will call this domctl for all (x86) guests for consistency. In light of th

[Xen-devel] [PATCH v2 for-4.8 0/2] Minor ACPI fixes for PVHv2 DomU

2016-11-07 Thread Roger Pau Monne
This series includes two patches to fix some minor issues with PVHv2 and ACPI. Thanks, Roger. ___ Xen-devel mailing list Xen-devel@lists.xen.org https://lists.xen.org/xen-devel

[Xen-devel] [PATCH v2 for-4.8 2/2] libxc: set rsdp pointer for PVHv2 guests

2016-11-07 Thread Roger Pau Monne
Set the address of the RSDP in the HVM start info structure for PVHv2 DomUs that have ACPI tables. Signed-off-by: Roger Pau Monné --- Cc: Ian Jackson Cc: Wei Liu Cc: Boris Ostrovsky Cc: Konrad Rzeszutek Wilk --- Changes since v1: - Reword code comment. --- tools/libxc/xc_dom_x86.c | 3 +++

[Xen-devel] [PATCH v2 for-4.8 1/2] libxc: properly account for the page offset when copying ACPI data

2016-11-07 Thread Roger Pau Monne
Or else ACPI data is always copied at the start of the page pointed by guest_addr_out, ignoring the page offset. Signed-off-by: Roger Pau Monné --- Cc: Ian Jackson Cc: Wei Liu Cc: Boris Ostrovsky Cc: Konrad Rzeszutek Wilk --- Changes since v1: - Also fix the calculation of the required numbe

Re: [Xen-devel] [PATCH 03/10] pvh: Set online VCPU map to avail_vcpus

2016-11-07 Thread Konrad Rzeszutek Wilk
On Sun, Nov 06, 2016 at 04:42:36PM -0500, Boris Ostrovsky wrote: > ACPI builder marks VCPUS set in vcpu_online map as enabled in MADT. > With ACPI-based CPU hotplug we only want VCPUs that are started by > the guest to be marked as such. Remaining VCPUs will be set to Oh, so this is a bug then? We

Re: [Xen-devel] [PATCH 04/10] acpi: Power and Sleep ACPI buttons are not emulated

2016-11-07 Thread Konrad Rzeszutek Wilk
On Sun, Nov 06, 2016 at 04:42:37PM -0500, Boris Ostrovsky wrote: > .. for PVH guests. However, since emulating them for HVM guests > also doesn't seem useful we can have FADT disable those buttons > for both types of guests. Wait, we need S3 suspend for HVM guests (think Windows without PV drivers

Re: [Xen-devel] [PATCH 05/10] acpi: Make pmtimer optional in FADT

2016-11-07 Thread Konrad Rzeszutek Wilk
On Sun, Nov 06, 2016 at 04:42:38PM -0500, Boris Ostrovsky wrote: > PM timer is not supported by PVH guests. > > Signed-off-by: Boris Ostrovsky Reviewed-by: Konrad Rzeszutek Wilk > --- > tools/firmware/hvmloader/util.c | 3 ++- > tools/libacpi/build.c | 5 + > tools/libacpi/libacp

Re: [Xen-devel] [PATCH v2 for-4.8 2/2] libxc: set rsdp pointer for PVHv2 guests

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 10:32 AM, Roger Pau Monne wrote: > Set the address of the RSDP in the HVM start info structure for PVHv2 DomUs > that have ACPI tables. > > Signed-off-by: Roger Pau Monné > --- > Cc: Ian Jackson > Cc: Wei Liu > Cc: Boris Ostrovsky > Cc: Konrad Rzeszutek Wilk Reviewed-by: Boris O

Re: [Xen-devel] [PATCH 06/10] acpi: PVH guests need _E02 method

2016-11-07 Thread Konrad Rzeszutek Wilk
On Sun, Nov 06, 2016 at 04:42:39PM -0500, Boris Ostrovsky wrote: > This is the method that will get invoked on an SCI. > > Signed-off-by: Boris Ostrovsky .. thought I wonder - do you want to also make the writes to _GPE.DPT1 and _GPE.DPT2 be optional? Looking at the mk_dsdt.c those are defined

Re: [Xen-devel] [PATCH v2 for-4.8 1/2] libxc: properly account for the page offset when copying ACPI data

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 10:32 AM, Roger Pau Monne wrote: > Or else ACPI data is always copied at the start of the page pointed by > guest_addr_out, ignoring the page offset. > > Signed-off-by: Roger Pau Monné > --- > Cc: Ian Jackson > Cc: Wei Liu > Cc: Boris Ostrovsky > Cc: Konrad Rzeszutek Wilk Review

Re: [Xen-devel] [PATCH 03/10] pvh: Set online VCPU map to avail_vcpus

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 10:36 AM, Konrad Rzeszutek Wilk wrote: > On Sun, Nov 06, 2016 at 04:42:36PM -0500, Boris Ostrovsky wrote: >> ACPI builder marks VCPUS set in vcpu_online map as enabled in MADT. >> With ACPI-based CPU hotplug we only want VCPUs that are started by >> the guest to be marked as such. Rem

Re: [Xen-devel] [PATCH 04/10] acpi: Power and Sleep ACPI buttons are not emulated

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 10:38 AM, Konrad Rzeszutek Wilk wrote: > On Sun, Nov 06, 2016 at 04:42:37PM -0500, Boris Ostrovsky wrote: >> .. for PVH guests. However, since emulating them for HVM guests >> also doesn't seem useful we can have FADT disable those buttons >> for both types of guests. > Wait, we need

Re: [Xen-devel] [PATCH 08/10] pvh/acpi: Handle ACPI accesses for PVH guests

2016-11-07 Thread Konrad Rzeszutek Wilk
On Sun, Nov 06, 2016 at 04:42:41PM -0500, Boris Ostrovsky wrote: > Signed-off-by: Boris Ostrovsky > --- > CC: Paul Durrant > --- > xen/arch/x86/hvm/ioreq.c | 66 > > 1 file changed, 66 insertions(+) > > diff --git a/xen/arch/x86/hvm/ioreq.c b/xe

Re: [Xen-devel] [PATCH] IOMMU: release lock on new exit path

2016-11-07 Thread Konrad Rzeszutek Wilk
On Mon, Nov 07, 2016 at 08:29:15AM -0700, Jan Beulich wrote: > This was overlooked in 7b2842a414 ("IOMMU: replace ASSERT()s checking > for NULL"). > > Reported-by: Konrad Rzeszutek Wilk Reviewed-by: Konrad Rzeszutek Wilk Thanks! > Signed-off-by: Jan Beulich > > --- a/xen/drivers/passthrough/

Re: [Xen-devel] [PATCH v2 for-4.8 1/2] libxc: properly account for the page offset when copying ACPI data

2016-11-07 Thread Andrew Cooper
On 07/11/16 15:32, Roger Pau Monne wrote: > Or else ACPI data is always copied at the start of the page pointed by > guest_addr_out, ignoring the page offset. > > Signed-off-by: Roger Pau Monné > --- > Cc: Ian Jackson > Cc: Wei Liu > Cc: Boris Ostrovsky > Cc: Konrad Rzeszutek Wilk Reviewed-by

Re: [Xen-devel] [PATCH v2 for-4.8 2/2] libxc: set rsdp pointer for PVHv2 guests

2016-11-07 Thread Andrew Cooper
On 07/11/16 15:32, Roger Pau Monne wrote: > Set the address of the RSDP in the HVM start info structure for PVHv2 DomUs > that have ACPI tables. > > Signed-off-by: Roger Pau Monné > --- > Cc: Ian Jackson > Cc: Wei Liu > Cc: Boris Ostrovsky > Cc: Konrad Rzeszutek Wilk Reviewed-by: Andrew Coope

Re: [Xen-devel] [PATCH 09/10] events/x86: Define SCI virtual interrupt

2016-11-07 Thread Konrad Rzeszutek Wilk
On Sun, Nov 06, 2016 at 04:42:42PM -0500, Boris Ostrovsky wrote: > PVH guests do not have IOAPIC which typically generates an SCI. For > those guests SCI will be provided as a virtual interrupt. > > We also move VIRQ_MCA definition out of xen-mca.h to > keep all x86-specific VIRQ_ARCH_* in one pla

Re: [Xen-devel] [PATCH 06/10] acpi: PVH guests need _E02 method

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 10:45 AM, Konrad Rzeszutek Wilk wrote: > On Sun, Nov 06, 2016 at 04:42:39PM -0500, Boris Ostrovsky wrote: >> This is the method that will get invoked on an SCI. >> >> Signed-off-by: Boris Ostrovsky > > .. thought I wonder - do you want to also make the writes to > _GPE.DPT1 and _GPE.

Re: [Xen-devel] [PATCH 06/10] acpi: PVH guests need _E02 method

2016-11-07 Thread Konrad Rzeszutek Wilk
On Mon, Nov 07, 2016 at 11:08:26AM -0500, Boris Ostrovsky wrote: > On 11/07/2016 10:45 AM, Konrad Rzeszutek Wilk wrote: > > On Sun, Nov 06, 2016 at 04:42:39PM -0500, Boris Ostrovsky wrote: > >> This is the method that will get invoked on an SCI. > >> > >> Signed-off-by: Boris Ostrovsky > > > > ..

[Xen-devel] [xen-unstable test] 101982: tolerable FAIL

2016-11-07 Thread osstest service owner
flight 101982 xen-unstable real [real] http://logs.test-lab.xenproject.org/osstest/logs/101982/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-armhf-armhf-libvirt 13 saverestore-support-checkfail like 101961 test-armhf-armhf-libvirt-xs

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 16:24, wrote: > The one-shot vm_event does sound reasonable. I could set a flag > per-VCPU, basically similar to v->arch.hvm_vcpu.inject_trap.vector, and > fire a single event from hvm_inject_trap() if it's set (then unset it) - > the flag would be set via an xc_monitor_next_int

[Xen-devel] [xen-unstable-smoke test] 102003: tolerable all pass - PUSHED

2016-11-07 Thread osstest service owner
flight 102003 xen-unstable-smoke real [real] http://logs.test-lab.xenproject.org/osstest/logs/102003/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-amd64-amd64-libvirt 12 migrate-support-checkfail never pass test-armhf-armhf-xl 1

Re: [Xen-devel] [PATCH 08/10] pvh/acpi: Handle ACPI accesses for PVH guests

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 10:55 AM, Konrad Rzeszutek Wilk wrote: > On Sun, Nov 06, 2016 at 04:42:41PM -0500, Boris Ostrovsky wrote: >> Signed-off-by: Boris Ostrovsky >> --- >> CC: Paul Durrant >> --- >> xen/arch/x86/hvm/ioreq.c | 66 >> >> 1 file changed, 66

Re: [Xen-devel] [PATCH 00/12] xen: add common function for reading optional value

2016-11-07 Thread Jarkko Sakkinen
On Mon, Nov 07, 2016 at 11:08:09AM +, David Vrabel wrote: > On 31/10/16 16:48, Juergen Gross wrote: > > There are multiple instances of code reading an optional unsigned > > parameter from Xenstore via xenbus_scanf(). Instead of repeating the > > same code over and over add a service function d

Re: [Xen-devel] [PATCH 09/10] events/x86: Define SCI virtual interrupt

2016-11-07 Thread Boris Ostrovsky
On 11/07/2016 11:05 AM, Konrad Rzeszutek Wilk wrote: > On Sun, Nov 06, 2016 at 04:42:42PM -0500, Boris Ostrovsky wrote: >> PVH guests do not have IOAPIC which typically generates an SCI. For >> those guests SCI will be provided as a virtual interrupt. >> >> We also move VIRQ_MCA definition out of x

Re: [Xen-devel] [PATCH 08/10] pvh/acpi: Handle ACPI accesses for PVH guests

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 16:55, wrote: > On Sun, Nov 06, 2016 at 04:42:41PM -0500, Boris Ostrovsky wrote: >> Signed-off-by: Boris Ostrovsky >> --- >> CC: Paul Durrant >> --- >> xen/arch/x86/hvm/ioreq.c | 66 > >> 1 file changed, 66 insertions(+) >> >

Re: [Xen-devel] [PATCH v7 2/6] VMX: Properly handle pi when all the assigned devices are removed

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 09:07, wrote: > This patch handles some corner cases when the last assigned device > is removed from the domain. In this case we should carefully handle > pi descriptor and the per-cpu blocking list, to make sure: > - all the PI descriptor are in the right state when next time a

Re: [Xen-devel] [PATCH v7 4/6] VT-d: No need to set irq affinity for posted format IRTE

2016-11-07 Thread Jan Beulich
>>> On 07.11.16 at 09:10, wrote: > --- a/xen/drivers/passthrough/vtd/intremap.c > +++ b/xen/drivers/passthrough/vtd/intremap.c > @@ -597,31 +597,34 @@ static int msi_msg_to_remap_entry( > > memcpy(&new_ire, iremap_entry, sizeof(struct iremap_entry)); > > -/* Set interrupt remapping ta

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

2016-11-07 Thread osstest service owner
flight 101986 ovmf real [real] http://logs.test-lab.xenproject.org/osstest/logs/101986/ Perfect :-) All tests in this flight passed as required version targeted for testing: ovmf f675a1b42235b508e17220878453b4b1f04dd990 baseline version: ovmf 3b25ca839bf84ff53f11e

Re: [Xen-devel] xc_hvm_inject_trap() races

2016-11-07 Thread Razvan Cojocaru
On 11/07/2016 06:10 PM, Jan Beulich wrote: On 07.11.16 at 16:24, wrote: >> The one-shot vm_event does sound reasonable. I could set a flag >> per-VCPU, basically similar to v->arch.hvm_vcpu.inject_trap.vector, and >> fire a single event from hvm_inject_trap() if it's set (then unset it) - >>

Re: [Xen-devel] [PATCH 04/10] acpi: Power and Sleep ACPI buttons are not emulated

2016-11-07 Thread annie li
On 11/7/2016 10:38 AM, Konrad Rzeszutek Wilk wrote: On Sun, Nov 06, 2016 at 04:42:37PM -0500, Boris Ostrovsky wrote: .. for PVH guests. However, since emulating them for HVM guests also doesn't seem useful we can have FADT disable those buttons for both types of guests. Wait, we need S3 suspe

[Xen-devel] Xen like VirtualBox

2016-11-07 Thread Jason Long
Hello. Why Xen developer never think about a product like VirtualBox? It is true that Xen is a type 1 hypervisor but is it possible to make a product like VirtualBox based on Xen? Thank you. ___ Xen-devel mailing list Xen-devel@lists.xen.org https://li

  1   2   >