[Xen-devel] [Patch V4 3/3] xen: add Xen pvUSB maintainer

2015-06-22 Thread Juergen Gross
Add myself as maintainer for the Xen pvUSB stuff. Signed-off-by: Juergen Gross Acked-by: Konrad Rzeszutek Wilk --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index d8afd29..8ef4e83 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -10965,6 +109

[Xen-devel] [Patch V4 0/3] xen, usb: support pvUSB frontend driver

2015-06-22 Thread Juergen Gross
This series adds XEN guest pvUSB support. With pvUSB it is possible to use physical USB devices from a XEN domain. The support consists of a frontend in form of a virtual hcd driver in the unprivileged domU passing I/O-requests to the backend in a driver domain (usually Dom0). The backend is not p

[Xen-devel] [Patch V4 2/3] usb: Introduce Xen pvUSB frontend (xen hcd)

2015-06-22 Thread Juergen Gross
Introduces the Xen pvUSB frontend. With pvUSB it is possible for a Xen domU to communicate with a USB device assigned to that domU. The communication is all done via the pvUSB backend in a driver domain (usually Dom0) which is owner of the physical device. The pvUSB frontend is a USB hcd for a vir

[Xen-devel] [Patch V4 1/3] usb: Add Xen pvUSB protocol description

2015-06-22 Thread Juergen Gross
Add the definition of pvUSB protocol used between the pvUSB frontend in a Xen domU and the pvUSB backend in a Xen driver domain (usually Dom0). This header was originally provided by Fujitsu for Xen based on Linux 2.6.18. Changes are: - adapt to Linux style guide Signed-off-by: Juergen Gross --

Re: [Xen-devel] [PATCH v8 2/7] Qemu-Xen-vTPM: Create a new file xen_pvdev.c

2015-06-22 Thread Xu, Quan
> -Original Message- > From: Stefano Stabellini [mailto:stefano.stabell...@eu.citrix.com] > Sent: Tuesday, June 23, 2015 12:37 AM > To: Xu, Quan > Cc: stefano.stabell...@eu.citrix.com; qemu-de...@nongnu.org; > stef...@linux.vnet.ibm.com; ebl...@redhat.com; wei.l...@citrix.com; > dgde...@t

Re: [Xen-devel] [PATCH] drivers: xen-blkfront: only talk_to_blkback() when in XenbusStateInitialising

2015-06-22 Thread Jan Beulich
>>> On 22.06.15 at 15:56, wrote: > --- a/drivers/block/xen-blkfront.c > +++ b/drivers/block/xen-blkfront.c > @@ -1951,6 +1951,8 @@ static void blkback_changed(struct xenbus_device *dev, > > switch (backend_state) { > case XenbusStateInitWait: > + if (dev->state != XenbusS

Re: [Xen-devel] [PATCH v3 07/11] x86/intel_pstate: changes in cpufreq_del_cpu for CPU offline

2015-06-22 Thread Wang, Wei W
On 19/06/2015 17:44, Jan Beulich wrote: > >>> On 11.06.15 at 10:28, wrote: > > cpufreq_cpu_policy is used in intel_pstate_set_pstate(), so we change > > to NULL it after the call of cpufreq_driver->exit. Otherwise, a > > calltrace will show up on your screen due to the reference of a NULL > > poin

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

2015-06-22 Thread osstest service user
flight 58829 qemu-mainline real [real] http://logs.test-lab.xenproject.org/osstest/logs/58829/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-amd64-i386-libvirt 11 guest-start fail like 58819 test-amd64-i386-libvirt-xsm

[Xen-devel] Xen Project Document Day is tomorrow, June 24!

2015-06-22 Thread Russ Pavlicek
Our next Document Day is this Wednesday. This month, we'd like to catch up with the latest advances in the project. Some topics to address include: - Mirage OS: we need current information about Mirage, with links to key pages on the Mirage wiki - XAPI: The latest docs from the XenServer crew nee

Re: [Xen-devel] [PATCH v3 04/11] x86/intel_pstate: relocate the driver register function

2015-06-22 Thread Wang, Wei W
On 18/06/2015 22:30, Jan Beulich wrote: > >>> On 11.06.15 at 10:27, wrote: > > Register the CPU hotplug notifier when the driver is registered, and > > move the driver register function to the cpufreq.c. > > The first half of the sentence fails to say why. And I suppose if you > explained > that

[Xen-devel] Proposed plan for libxl USB interface (was Re: [PATCH V4 3/7] libxl: add pvusb API)

2015-06-22 Thread Chun Yan Liu
>>> On 6/22/2015 at 09:29 PM, in message <55880dcc.6070...@eu.citrix.com>, >>> George Dunlap wrote: > On 06/18/2015 01:08 PM, George Dunlap wrote: > > This usb interface stuff is really becoming a morass. The core > > functionality is fairly independent of the interface. I'm inclined to >

[Xen-devel] Proposed plan for libxl USB interface (was Re: [PATCH V4 3/7] libxl: add pvusb API)

2015-06-22 Thread Chun Yan Liu
>>> On 6/22/2015 at 09:29 PM, in message <55880dcc.6070...@eu.citrix.com>, >>> George Dunlap wrote: > On 06/18/2015 01:08 PM, George Dunlap wrote: > > This usb interface stuff is really becoming a morass. The core > > functionality is fairly independent of the interface. I'm inclined to >

[Xen-devel] Proposed plan for libxl USB interface (was Re: [PATCH V4 3/7] libxl: add pvusb API)

2015-06-22 Thread Chun Yan Liu
>>> On 6/22/2015 at 09:29 PM, in message <55880dcc.6070...@eu.citrix.com>, >>> George Dunlap wrote: > On 06/18/2015 01:08 PM, George Dunlap wrote: > > This usb interface stuff is really becoming a morass. The core > > functionality is fairly independent of the interface. I'm inclined to >

Re: [Xen-devel] [PATCH v3 10/11] x86/intel_pstate: support the use of intel_pstate in pmstat.c

2015-06-22 Thread Wang, Wei W
Hi Jan, On 11/06/2015 16:31, Wei Wang wrote: > Add support in the pmstat.c so that the xenpm tool can request to access the > intel_pstate driver. I want to propose some other changes here to commonize the intel_pstate implementation in this common code (pmstat.c). 1) introduce a new struct:

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

2015-06-22 Thread osstest service user
flight 58827 linux-next real [real] http://logs.test-lab.xenproject.org/osstest/logs/58827/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-amd64-rumpuserxen-amd64 15 rumpuserxen-demo-xenstorels/xenstorels.repeat fail REGR. vs. 58

[Xen-devel] Bug in devicetree_for_each_node() in xen/arch/arm/bootfdt.c ?

2015-06-22 Thread Chris (Christopher) Brand
I've been trying to figure out why Xen only reports 2GB on my ARM platform that actually has 3GB, and I think I've found a bug, but I'm not familiar enough with the Xen code to fix it. The relevant parts of my dts are: /dts-v1/; / { model = "Broadcom STB (7445d0)"; compatible = "brcm,

[Xen-devel] [xen-4.5-testing test] 58826: regressions - FAIL

2015-06-22 Thread osstest service user
flight 58826 xen-4.5-testing real [real] http://logs.test-lab.xenproject.org/osstest/logs/58826/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-i386-rumpuserxen-i386 15 rumpuserxen-demo-xenstorels/xenstorels.repeat fail REGR. vs.

[Xen-devel] [linux-arm-xen test] 58830: tolerable all pass - PUSHED

2015-06-22 Thread osstest service user
flight 58830 linux-arm-xen real [real] http://logs.test-lab.xenproject.org/osstest/logs/58830/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-armhf-armhf-xl-xsm 12 migrate-support-checkfail never pass test-armhf-armhf-xl 12 migra

[Xen-devel] [xen-4.4-testing test] 58825: regressions - FAIL

2015-06-22 Thread osstest service user
flight 58825 xen-4.4-testing real [real] http://logs.test-lab.xenproject.org/osstest/logs/58825/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-armhf-armhf-xl-multivcpu 15 guest-start/debian.repeat fail in 58818 REGR. vs. 58451 Tests

Re: [Xen-devel] [PATCH v4 RFC 1/6] x86/PCI: add config space write abstract intercept logic

2015-06-22 Thread Konrad Rzeszutek Wilk
> -static bool_t pci_cfg_ok(struct domain *currd, bool_t write, > - unsigned int start, unsigned int size) > +static bool_t pci_cfg_ok(struct domain *currd, unsigned int start, > + unsigned int size, uint32_t *write) > { > uint32_t machine_bdf;

Re: [Xen-devel] [PATCH 3/6] AMD-PVH: call hvm_emulate_one instead of handle_mmio

2015-06-22 Thread Boris Ostrovsky
On 06/22/2015 12:37 PM, elena.ufimts...@oracle.com wrote: From: Elena Ufimtseva Certain IOIO instructions and CR access instructions like lmsw/clts etc need to be emulated. handle_mmio is incorrectly called to accomplish this. Create svm_emulate() to call hvm_emulate_one which is more appropria

Re: [Xen-devel] [DESIGN] Feature Levelling improvements

2015-06-22 Thread Konrad Rzeszutek Wilk
Thank you for posting this! Some comments below. > Design > == > > `struct sysctl_physinfo.levelling_caps` > --- > > Xen shall gain a new physinfo field which reports the degree to which it can > influence `CPUID` executed by a PV guest. This is a bitmap

Re: [Xen-devel] race condition in xen-gntdev

2015-06-22 Thread Daniel De Graaf
On 06/22/2015 02:37 PM, Konrad Rzeszutek Wilk wrote: On Mon, Jun 22, 2015 at 08:13:35PM +0200, Marek Marczykowski-Górecki wrote: On Mon, Jun 22, 2015 at 01:46:27PM -0400, Konrad Rzeszutek Wilk wrote: On Wed, Jun 17, 2015 at 09:42:11PM +0200, Marek Marczykowski-Górecki wrote: On Thu, May 28, 20

Re: [Xen-devel] [PATCH 1/6] pvh: domu construct vmcb 64 bit mode start

2015-06-22 Thread Boris Ostrovsky
On 06/22/2015 12:37 PM, elena.ufimts...@oracle.com wrote: From: Elena Ufimtseva Signed-off-by: Mukesh Rathor --- All of these changes are common with Intel so we should be able to move them up to common layer. (For CS attributes the 32-bit patches that I posted earlier provide set_mode op)

[Xen-devel] [PATCH v2 01/12] VMX: VMFUNC and #VE definitions and detection.

2015-06-22 Thread Ed White
Currently, neither is enabled globally but may be enabled on a per-VCPU basis by the altp2m code. Remove the check for EPTE bit 63 == zero in ept_split_super_page(), as that bit is now hardware-defined. Signed-off-by: Ed White --- xen/arch/x86/hvm/vmx/vmcs.c| 42

[Xen-devel] [PATCH v2 02/12] VMX: implement suppress #VE.

2015-06-22 Thread Ed White
In preparation for selectively enabling #VE in a later patch, set suppress #VE on all EPTE's. Suppress #VE should always be the default condition for two reasons: it is generally not safe to deliver #VE into a guest unless that guest has been modified to receive it; and even then for most EPT viol

[Xen-devel] [PATCH v2 04/12] x86/altp2m: basic data structures and support routines.

2015-06-22 Thread Ed White
Add the basic data structures needed to support alternate p2m's and the functions to initialise them and tear them down. Although Intel hardware can handle 512 EPTP's per hardware thread concurrently, only 10 per domain are supported in this patch for performance reasons. The iterator in hap_enab

[Xen-devel] [PATCH v2 11/12] x86/altp2m: Add altp2mhvm HVM domain parameter.

2015-06-22 Thread Ed White
The altp2mhvm and nestedhvm parameters are mutually exclusive and cannot be set together. Signed-off-by: Ed White --- docs/man/xl.cfg.pod.5 | 12 tools/libxl/libxl_create.c | 1 + tools/libxl/libxl_dom.c | 2 ++ tools/libxl/libxl_types.idl | 1 + tools/

[Xen-devel] [PATCH v2 08/12] x86/altp2m: alternate p2m memory events.

2015-06-22 Thread Ed White
Add a flag to indicate that a memory event occurred in an alternate p2m and a field containing the p2m index. Allow the response to switch to a different p2m using the same flag and field. Modify p2m_access_check() to handle alternate p2m's. Signed-off-by: Ed White --- xen/arch/x86/mm/p2m.c

[Xen-devel] [PATCH v2 06/12] VMX: add VMFUNC leaf 0 (EPTP switching) to emulator.

2015-06-22 Thread Ed White
From: Ravi Sahita Signed-off-by: Ravi Sahita --- xen/arch/x86/hvm/emulate.c | 13 +++-- xen/arch/x86/hvm/vmx/vmx.c | 30 ++ xen/arch/x86/x86_emulate/x86_emulate.c | 8 xen/arch/x86/x86_emulate/x86_emulate.h | 4 xen/inc

[Xen-devel] [PATCH v2 07/12] x86/altp2m: add control of suppress_ve.

2015-06-22 Thread Ed White
The existing ept_set_entry() and ept_get_entry() routines are extended to optionally set/get suppress_ve and renamed. New ept_set_entry() and ept_get_entry() routines are provided as wrappers, where set preserves suppress_ve for an existing entry and sets it for a new entry. Additional function po

[Xen-devel] [PATCH v2 09/12] x86/altp2m: add remaining support routines.

2015-06-22 Thread Ed White
Add the remaining routines required to support enabling the alternate p2m functionality. Signed-off-by: Ed White --- xen/arch/x86/hvm/hvm.c | 60 +- xen/arch/x86/mm/hap/Makefile| 1 + xen/arch/x86/mm/hap/altp2m_hap.c| 103 + xen/arch/x86/mm/p2m-ept.c

[Xen-devel] [PATCH v2 10/12] x86/altp2m: define and implement alternate p2m HVMOP types.

2015-06-22 Thread Ed White
Signed-off-by: Ed White --- xen/arch/x86/hvm/hvm.c | 216 xen/include/public/hvm/hvm_op.h | 69 + 2 files changed, 285 insertions(+) diff --git a/xen/arch/x86/hvm/hvm.c b/xen/arch/x86/hvm/hvm.c index b758ee1..b3e74ce 100644 --- a/xen

[Xen-devel] [PATCH v2 12/12] x86/altp2m: XSM hooks for altp2m HVM ops

2015-06-22 Thread Ed White
From: Ravi Sahita Signed-off-by: Ravi Sahita --- tools/flask/policy/policy/modules/xen/xen.if | 4 ++-- xen/arch/x86/hvm/hvm.c | 35 xen/include/xsm/dummy.h | 12 ++ xen/include/xsm/xsm.h| 1

[Xen-devel] [PATCH v2 03/12] x86/HVM: Hardware alternate p2m support detection.

2015-06-22 Thread Ed White
As implemented here, only supported on platforms with VMX HAP. By default this functionality is force-disabled, it can be enabled by specifying altp2m=1 on the Xen command line. Signed-off-by: Ed White --- docs/misc/xen-command-line.markdown | 7 +++ xen/arch/x86/hvm/hvm.c | 1

[Xen-devel] [PATCH v2 00/12] Alternate p2m: support multiple copies of host p2m

2015-06-22 Thread Ed White
This set of patches adds support to hvm domains for EPTP switching by creating multiple copies of the host p2m (currently limited to 10 copies). The primary use of this capability is expected to be in scenarios where access to memory needs to be monitored and/or restricted below the level at which

[Xen-devel] [PATCH v2 05/12] VMX/altp2m: add code to support EPTP switching and #VE.

2015-06-22 Thread Ed White
Implement and hook up the code to enable VMX support of VMFUNC and #VE. VMFUNC leaf 0 (EPTP switching) emulation is added in a later patch. Signed-off-by: Ed White --- xen/arch/x86/hvm/vmx/vmx.c | 132 + 1 file changed, 132 insertions(+) diff --git a

[Xen-devel] [xen-4.2-testing test] 58824: FAIL

2015-06-22 Thread osstest service user
flight 58824 xen-4.2-testing real [real] http://logs.test-lab.xenproject.org/osstest/logs/58824/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64-libvirt 3 host-install(3) broken in 58584 REGR. vs. 584

Re: [Xen-devel] race condition in xen-gntdev (was: Re: gntdev/gntalloc and fork? - crash in gntdev)

2015-06-22 Thread Konrad Rzeszutek Wilk
On Mon, Jun 22, 2015 at 08:13:35PM +0200, Marek Marczykowski-Górecki wrote: > On Mon, Jun 22, 2015 at 01:46:27PM -0400, Konrad Rzeszutek Wilk wrote: > > On Wed, Jun 17, 2015 at 09:42:11PM +0200, Marek Marczykowski-Górecki wrote: > > > On Thu, May 28, 2015 at 01:45:08AM +0200, Marek Marczykowski-Gór

Re: [Xen-devel] PCI Passthrough ARM Design : Draft1

2015-06-22 Thread Konrad Rzeszutek Wilk
On Wed, Jun 17, 2015 at 03:35:02PM +0100, Stefano Stabellini wrote: > On Wed, 17 Jun 2015, Ian Campbell wrote: > > On Wed, 2015-06-17 at 07:14 -0700, Manish Jaggi wrote: > > > > > > On Wednesday 17 June 2015 06:43 AM, Ian Campbell wrote: > > > > On Wed, 2015-06-17 at 13:58 +0100, Stefano Stabellin

Re: [Xen-devel] PCI Passthrough ARM Design : Draft1

2015-06-22 Thread Konrad Rzeszutek Wilk
On Wed, Jun 17, 2015 at 03:26:10PM +0100, Ian Campbell wrote: > On Wed, 2015-06-17 at 15:18 +0100, Stefano Stabellini wrote: > > On Wed, 17 Jun 2015, Ian Campbell wrote: > > > On Wed, 2015-06-17 at 14:40 +0100, Stefano Stabellini wrote: > > > > On Wed, 17 Jun 2015, Ian Campbell wrote: > > > > > On

Re: [Xen-devel] race condition in xen-gntdev (was: Re: gntdev/gntalloc and fork? - crash in gntdev)

2015-06-22 Thread Marek Marczykowski-Górecki
On Mon, Jun 22, 2015 at 01:46:27PM -0400, Konrad Rzeszutek Wilk wrote: > On Wed, Jun 17, 2015 at 09:42:11PM +0200, Marek Marczykowski-Górecki wrote: > > On Thu, May 28, 2015 at 01:45:08AM +0200, Marek Marczykowski-Górecki wrote: > > > On Thu, Apr 30, 2015 at 04:47:44PM +0200, Marek Marczykowski-Gór

Re: [Xen-devel] [PATCH RFC v1 00/13] Introduce HMV without dm and new boot ABI

2015-06-22 Thread Konrad Rzeszutek Wilk
On Mon, Jun 22, 2015 at 06:55:12PM +0100, Stefano Stabellini wrote: > Hi Roger, > > given that this patch series is actually using the Xen "hvm" builder, I > take that all the PVH code paths in Xen or the guest kernel are not > actually used, correct? This is more like PV on HVM without QEMU, righ

Re: [Xen-devel] [PATCH RFC v1 00/13] Introduce HMV without dm and new boot ABI

2015-06-22 Thread Stefano Stabellini
Hi Roger, given that this patch series is actually using the Xen "hvm" builder, I take that all the PVH code paths in Xen or the guest kernel are not actually used, correct? This is more like PV on HVM without QEMU, right? Do you think think this can work for Dom0 too? Would that make all the PV

Re: [Xen-devel] race condition in xen-gntdev (was: Re: gntdev/gntalloc and fork? - crash in gntdev)

2015-06-22 Thread Konrad Rzeszutek Wilk
On Wed, Jun 17, 2015 at 09:42:11PM +0200, Marek Marczykowski-Górecki wrote: > On Thu, May 28, 2015 at 01:45:08AM +0200, Marek Marczykowski-Górecki wrote: > > On Thu, Apr 30, 2015 at 04:47:44PM +0200, Marek Marczykowski-Górecki wrote: > > > Hi, > > > > > > What is the proper way to handle shared pa

Re: [Xen-devel] [PATCH v8 3/7] Qemu-Xen-vTPM: Xen frontend driver infrastructure

2015-06-22 Thread Stefano Stabellini
On Sun, 17 May 2015, Quan Xu wrote: > This patch adds infrastructure for xen front drivers living in qemu, > so drivers don't need to implement common stuff on their own. It's > mostly xenbus management stuff: some functions to access XenStore, > setting up XenStore watches, callbacks on device di

Re: [Xen-devel] [RFC PATCH v3 05/18] xen/arm: ITS: Port ITS driver to xen

2015-06-22 Thread Julien Grall
Hi, On 22/06/15 13:01, vijay.kil...@gmail.com wrote: > From: Vijaya Kumar K > > Only required changes from Linux ITS driver is ported > and compiled Can you list the changes you took from Linux? The coding style is not the same so it's hard to know what is the difference. It would also have be

Re: [Xen-devel] [PATCH 5/6] AMD-PVH: Support TSC_MODE_NEVER_EMULATE for PVH

2015-06-22 Thread Konrad Rzeszutek Wilk
On Mon, Jun 22, 2015 at 12:37:37PM -0400, elena.ufimts...@oracle.com wrote: > From: Elena Ufimtseva > > On AMD, MSR_AMD64_TSC_RATIO must be set for rdtsc instruction in guest > to properly read the cpu tsc. To that end, set tsc_khz in struct domain. It looks like the TSC_MODE_DEFAULT, TSC_MODE_A

Re: [Xen-devel] [PATCH v3 10/10] x86/MSI-X: provide hypercall interface for mask-all control

2015-06-22 Thread Roger Pau Monné
El 19/06/15 a les 16.58, Jan Beulich ha escrit: On 19.06.15 at 16:07, wrote: >> I don't mind adding a PHYSDEVOP_pci_mmcfg_reserved call to FreeBSD, but >> for it to have any effect we need to stop unconditionally mapping >> everything as MMIO regions on PVH Dom0. > > Right, I didn't mean to

Re: [Xen-devel] [PATCH v8 4/7] Qemu-Xen-vTPM: Register Xen stubdom vTPM frontend driver

2015-06-22 Thread Stefano Stabellini
On Sun, 17 May 2015, Quan Xu wrote: > This drvier transfers any request/repond between TPM xenstubdoms > driver and Xen vTPM stubdom, and facilitates communications between > Xen vTPM stubdom domain and vTPM xenstubdoms driver. It is a glue for > the TPM xenstubdoms driver and Xen stubdom vTPM doma

[Xen-devel] [PATCH 1/6] pvh: domu construct vmcb 64 bit mode start

2015-06-22 Thread elena . ufimtseva
From: Elena Ufimtseva Signed-off-by: Mukesh Rathor --- xen/arch/x86/hvm/svm/vmcb.c | 16 +--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/xen/arch/x86/hvm/svm/vmcb.c b/xen/arch/x86/hvm/svm/vmcb.c index 6339d2a..70a6588 100644 --- a/xen/arch/x86/hvm/svm/vmcb.c +++

Re: [Xen-devel] [PATCH v8 2/7] Qemu-Xen-vTPM: Create a new file xen_pvdev.c

2015-06-22 Thread Stefano Stabellini
On Sun, 17 May 2015, Quan Xu wrote: > for some common part of xen frontend and backend, such as xendevs > queue and xenstore update functions. > > Signed-off-by: Quan Xu Hi Quan, could you please separate out the code movement from any other changes? This patch would become two patches: the fir

[Xen-devel] [PATCH 4/6] AMD-PVH: Do not get/set vlapic TPR

2015-06-22 Thread elena . ufimtseva
From: Elena Ufimtseva PVH doesn't use apic emulation hence vlapic->regs ptr is not set for it. Signed-off-by: Mukesh Rathor --- xen/arch/x86/hvm/svm/svm.c | 25 ++--- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/xen/arch/x86/hvm/svm/svm.c b/xen/arch/x86/h

[Xen-devel] [PATCH 2/6] AMD-PVH: cpuid intercept

2015-06-22 Thread elena . ufimtseva
From: Elena Ufimtseva Call pv_cpuid for pvh cpuid intercept. Note, we modify svm_vmexit_do_cpuid instead of the intercept switch because the guest eip needs to be adjusted for pvh also. Signed-off-by: Mukesh Rathor --- xen/arch/x86/hvm/svm/svm.c | 25 ++--- 1 file changed,

[Xen-devel] [PATCH 6/6] AMD-PVH: enable pvh if requirements met

2015-06-22 Thread elena . ufimtseva
From: Elena Ufimtseva Finally, enable pvh if the cpu supports NPT and svm decode. Signed-off-by: Mukesh Rathor --- xen/arch/x86/hvm/svm/svm.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/xen/arch/x86/hvm/svm/svm.c b/xen/arch/x86/hvm/svm/svm.c index 64d22fe..9945550 100644 --- a/xen/a

[Xen-devel] [PATCH 5/6] AMD-PVH: Support TSC_MODE_NEVER_EMULATE for PVH

2015-06-22 Thread elena . ufimtseva
From: Elena Ufimtseva On AMD, MSR_AMD64_TSC_RATIO must be set for rdtsc instruction in guest to properly read the cpu tsc. To that end, set tsc_khz in struct domain. Signed-off-by: Mukesh Rathor --- xen/arch/x86/time.c | 1 + 1 file changed, 1 insertion(+) diff --git a/xen/arch/x86/time.c b/x

[Xen-devel] [PATCH 0/6] AMD-PVH: DomU support

2015-06-22 Thread elena . ufimtseva
From: Elena Ufimtseva This is a re-spin of patches for AMD PVH DomU from Mukesh Rathor. As I am diving into more details of AMD PVH, I am reposting his series with minor changes that reviewers (Jan and Boris) posted in comments. The issue with handle_mmio is not yet addressed and I would like to

[Xen-devel] [PATCH 3/6] AMD-PVH: call hvm_emulate_one instead of handle_mmio

2015-06-22 Thread elena . ufimtseva
From: Elena Ufimtseva Certain IOIO instructions and CR access instructions like lmsw/clts etc need to be emulated. handle_mmio is incorrectly called to accomplish this. Create svm_emulate() to call hvm_emulate_one which is more appropriate, and works for pvh as well. handle_mmio call is forbidden

Re: [Xen-devel] [PATCH RFC 3/4] xen: implement SCHEDOP_soft_reset

2015-06-22 Thread Vitaly Kuznetsov
"Jan Beulich" writes: On 22.06.15 at 18:00, wrote: >> "Jan Beulich" writes: >> >> On 03.06.15 at 15:35, wrote: @@ -1129,8 +1129,9 @@ void unmap_vcpu_info(struct vcpu *v) mfn = v->vcpu_info_mfn; unmap_domain_page_global((void *)

[Xen-devel] [PATCHv1] x86: only check for one watchdog NMI

2015-06-22 Thread David Vrabel
Since the NMI handler can now recognize watchdog NMIs, make check_nmi_watchdog() only check for at least one watchdog NMI. This prevents false negatives caused by other processors (which may be being power managed by the BIOS) running at reduced clock frequencies. This will also slightly speed up

[Xen-devel] [PATCH RFC v1 12/13] xen: allow 64bit HVM guests to use XENMEM_memory_map

2015-06-22 Thread Roger Pau Monne
Enable this hypercall for 64bit HVM guests in order to fetch the e820 memory map in the absence of an emulated BIOS. The memory map is populated and notified to Xen in arch_setup_meminit_hvm. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc

[Xen-devel] [PATCH RFC v1 11/13] xen/libxl: allow creating HVM guests without a device model

2015-06-22 Thread Roger Pau Monne
Intorduce a new device model version (NONE) that can be used to specify that no device model should be used. Propagate this to Xen by creating a new XEN_DOMCTL_CDF_noemu flag that disables some of the emulation done inside of Xen. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabel

[Xen-devel] [PATCH RFC v1 13/13] xenconsole: try to attach to PV console if HVM fails

2015-06-22 Thread Roger Pau Monne
HVM guests have always used the emulated serial console by default, but if the emulated serial pty cannot be fetched from xenstore try to use the PV console instead. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan Beulich Cc: Andrew

[Xen-devel] [PATCH RFC v1 10/13] lib{xc/xl}: allow the creation of HVM domains with a kernel

2015-06-22 Thread Roger Pau Monne
Replace the firmware loaded into HVM guests with an OS kernel. Since the HVM builder now uses the PV xc_dom_* set of functions this kernel will be parsed and loaded inside the guest like on PV, but the container is a pure HVM guest. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stab

[Xen-devel] [PATCH RFC v1 04/13] libxc: allow arch_setup_meminit to populate HVM domain memory

2015-06-22 Thread Roger Pau Monne
Introduce a new arch_setup_meminit_hvm that's going to be used to populate HVM domain memory. Rename arch_setup_meminit to arch_setup_meminit_hvm_pv and introduce a stub arch_setup_meminit that will call the right meminit function depending on the contains type. Signed-off-by: Roger Pau Monné Cc:

[Xen-devel] [PATCH RFC v1 05/13] libxc: introduce a domain loader for HVM guest firmware

2015-06-22 Thread Roger Pau Monne
Introduce a very simple (and dummy) domain loader to be used to load the firmware (hvmloader) into HVM guests. Since hmvloader is just a 32bit elf executable the loader is fairly simple. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan

[Xen-devel] [PATCH RFC v1 08/13] libxc: remove dead x86 HVM code

2015-06-22 Thread Roger Pau Monne
Remove xc_hvm_build_x86.c since xc_hvm_build is not longer used in order to create HVM guests. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan Beulich Cc: Andrew Cooper Cc: Boris Ostrovsky Cc: Konrad Rzeszutek Wilk Cc: Elena Ufimt

[Xen-devel] [PATCH RFC v1 01/13] libxc: split x86 HVM setup_guest into smaller logical functions

2015-06-22 Thread Roger Pau Monne
This is just a preparatory change to clean up the code in setup_guest. Should not introduce any functional changes. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan Beulich Cc: Andrew Cooper Cc: Boris Ostrovsky Cc: Konrad Rzeszutek

[Xen-devel] [PATCH RFC v1 09/13] elfnotes: intorduce a new PHYS_ENTRY elfnote

2015-06-22 Thread Roger Pau Monne
This new elfnote contains the 32bit entry point into the kernel. Xen will use this entry point in order to launch the guest kernel in 32bit protected mode with paging disabled. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan Beulich

[Xen-devel] [PATCH RFC v1 00/13] Introduce HMV without dm and new boot ABI

2015-06-22 Thread Roger Pau Monne
Before reading any further, keep in mind this is a VERY inital RFC prototype series. Many things are not finished, and those that are done make heavy use of duck tape in order to keep things into place. Now that you are warned, this series is split in the following order: - Patches from 1 to 7

[Xen-devel] [PATCH RFC v1 07/13] libxl: switch HVM domain building to use xc_dom_* helpers

2015-06-22 Thread Roger Pau Monne
Now that we have all the code in place HVM domain building in libxl can be switched to use the xc_dom_* family of functions, just like they are used in order to build PV guests. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan Beulich

[Xen-devel] [PATCH RFC v1 03/13] libxc: introduce the notion of a container type

2015-06-22 Thread Roger Pau Monne
Introduce the notion of a container type into xc_dom_image. This will be needed by later changes that will also use xc_dom_image in order to build HVM guests. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan Beulich Cc: Andrew Cooper

[Xen-devel] [PATCH RFC v1 02/13] libxc: unify xc_dom_p2m_{host/guest}

2015-06-22 Thread Roger Pau Monne
Unify both functions into xc_dom_p2m. Should not introduce any functional change. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan Beulich Cc: Andrew Cooper Cc: Boris Ostrovsky Cc: Konrad Rzeszutek Wilk Cc: Elena Ufimtseva --- st

[Xen-devel] [PATCH RFC v1 06/13] libxc: introduce a xc_dom_arch for hvm-3.0-x86_32 guests

2015-06-22 Thread Roger Pau Monne
This xc_dom_arch will be used in order to build HVM domains. The code is based on the existing xc_hvm_populate_params function. Signed-off-by: Roger Pau Monné Cc: Ian Jackson Cc: Stefano Stabellini Cc: Ian Campbell Cc: Wei Liu Cc: Jan Beulich Cc: Andrew Cooper Cc: Boris Ostrovsky Cc: Konra

Re: [Xen-devel] [PATCH v25 04/15] x86/VPMU: Interface for setting PMU mode and flags

2015-06-22 Thread Boris Ostrovsky
On 06/22/2015 11:10 AM, Jan Beulich wrote: +switch ( op ) +{ +case XENPMU_mode_set: +{ +if ( (pmu_params.val & ~(XENPMU_MODE_SELF | XENPMU_MODE_HV)) || + (hweight64(pmu_params.val) > 1) ) +return -EINVAL; + +/* 32-bit dom0 can only sample

Re: [Xen-devel] [PATCH RFC 3/4] xen: implement SCHEDOP_soft_reset

2015-06-22 Thread Jan Beulich
>>> On 22.06.15 at 18:00, wrote: > "Jan Beulich" writes: > > On 03.06.15 at 15:35, wrote: >>> @@ -1129,8 +1129,9 @@ void unmap_vcpu_info(struct vcpu *v) >>> mfn = v->vcpu_info_mfn; >>> unmap_domain_page_global((void *) >>> ((unsigned long)v->vcpu_info

Re: [Xen-devel] [xen-unstable test] 58821: tolerable FAIL

2015-06-22 Thread Ian Campbell
On Mon, 2015-06-22 at 17:00 +0100, Andrew Cooper wrote: > On 22/06/15 16:36, Jan Beulich wrote: > On 22.06.15 at 17:17, wrote: > >> On Mon, 2015-06-22 at 14:09 +, osstest service user wrote: > >>> flight 58821 xen-unstable real [real] > >>> http://logs.test-lab.xenproject.org/osstest/logs

Re: [Xen-devel] [PATCH 1/1] xen-hvm: Add trace to ioreq

2015-06-22 Thread Stefano Stabellini
On Thu, 30 Apr 2015, Don Slutz wrote: > Signed-off-by: Don Slutz > (cherry picked from commit b72adbe7510d0a30053d32334665ee887bec9e43) Acked-by: Stefano Stabellini I'll add it to my queue > trace-events | 7 +++ > xen-hvm.c| 21 + > 2 files changed, 28 insertion

Re: [Xen-devel] [PATCH RFC 3/4] xen: implement SCHEDOP_soft_reset

2015-06-22 Thread Vitaly Kuznetsov
"Jan Beulich" writes: On 03.06.15 at 15:35, wrote: >> @@ -1129,8 +1129,9 @@ void unmap_vcpu_info(struct vcpu *v) >> mfn = v->vcpu_info_mfn; >> unmap_domain_page_global((void *) >> ((unsigned long)v->vcpu_info & PAGE_MASK)); >> - >> -v->vcpu_info =

Re: [Xen-devel] [xen-unstable test] 58821: tolerable FAIL

2015-06-22 Thread Andrew Cooper
On 22/06/15 16:36, Jan Beulich wrote: On 22.06.15 at 17:17, wrote: >> On Mon, 2015-06-22 at 14:09 +, osstest service user wrote: >>> flight 58821 xen-unstable real [real] >>> http://logs.test-lab.xenproject.org/osstest/logs/58821/ >>> >> [...] >>> test-amd64-amd64-libvirt 11 guest-s

Re: [Xen-devel] [xen-4.2-testing test] 58817: FAIL

2015-06-22 Thread Jan Beulich
>>> On 22.06.15 at 08:54, wrote: > flight 58817 xen-4.2-testing real [real] > http://logs.test-lab.xenproject.org/osstest/logs/58817/ > > Failures and problems with tests :-( > > Tests which did not succeed and are blocking, > including tests which could not be run: > build-amd64-libvirt

Re: [Xen-devel] [PATCH] libxl: Add AHCI support for upstream qemu

2015-06-22 Thread Stefano Stabellini
On Mon, 22 Jun 2015, Fabio Fantoni wrote: > Usage: > ahci=0|1 (default=0) > > If enabled adds ich9 disk controller in ahci mode and uses it with > upstream qemu to emulate disks instead of ide. > It doesn't support cdroms which still using ide (cdroms will use > "-device ide-cd" as new qemu parame

Re: [Xen-devel] [xen-unstable test] 58821: tolerable FAIL

2015-06-22 Thread Jan Beulich
>>> On 22.06.15 at 17:17, wrote: > On Mon, 2015-06-22 at 14:09 +, osstest service user wrote: >> flight 58821 xen-unstable real [real] >> http://logs.test-lab.xenproject.org/osstest/logs/58821/ >> > [...] >> test-amd64-amd64-libvirt 11 guest-start fail like > 58789 >

Re: [Xen-devel] [PATCH v25 12/15] x86/VPMU: Handle PMU interrupts for PV(H) guests

2015-06-22 Thread Jan Beulich
>>> On 19.06.15 at 20:44, wrote: > Add support for handling PMU interrupts for PV(H) guests. > > VPMU for the interrupted VCPU is unloaded until the guest issues > XENPMU_flush > hypercall. This allows the guest to access PMU MSR values that are stored in > VPMU context which is shared between h

[Xen-devel] [PATCH v7 1/2] OSSTEST: introduce a raisin build test

2015-06-22 Thread Stefano Stabellini
Signed-off-by: Stefano Stabellini --- Changes in v7: - update raisin git url after http://marc.info/?l=xen-devel&m=143472251602803 Changes in v6: - move divide to Osstest/BuildSupport.pm and rename it to divide_xen_build; use divide_xen_build in ts-raisin-build and ts-xen-build. Changes in v5:

Re: [Xen-devel] [xen-unstable test] 58821: tolerable FAIL

2015-06-22 Thread Ian Campbell
On Mon, 2015-06-22 at 14:09 +, osstest service user wrote: > flight 58821 xen-unstable real [real] > http://logs.test-lab.xenproject.org/osstest/logs/58821/ > [...] > test-amd64-amd64-libvirt 11 guest-start fail like > 58789 http://logs.test-lab.xenproject.org/osstest

[Xen-devel] [PATCH v7 2/2] OSSTest: push successful raisin builds

2015-06-22 Thread Stefano Stabellini
Determine the most recent raisin revision that needs to be tested, by comparing with the already tested xen-tested-master branch. Push to raisin.git:xen-tested-master when the build is successful. Signed-off-by: Stefano Stabellini --- ap-common|3 +++ ap-fetch-version |3

[Xen-devel] [PATCH v7 0/2] OSSTEST: introduce a raisin build test

2015-06-22 Thread Stefano Stabellini
Hi all, the first patch introduces a Raisin build job, meant to test Raisin itself. The second patch push-gates Raisin on successful builds. Signed-off-by: Stefano Stabellini Changes in v7: - update raisin git url after http://marc.info/?l=xen-devel&m=143472251602803 - add a patch to push-gate

[Xen-devel] [PATCH] libxl: Add AHCI support for upstream qemu

2015-06-22 Thread Fabio Fantoni
Usage: ahci=0|1 (default=0) If enabled adds ich9 disk controller in ahci mode and uses it with upstream qemu to emulate disks instead of ide. It doesn't support cdroms which still using ide (cdroms will use "-device ide-cd" as new qemu parameter) Ahci requires new qemu parameter but for now other

Re: [Xen-devel] [PATCH v25 07/15] x86/VPMU: Save VPMU state for PV guests during context switch

2015-06-22 Thread Jan Beulich
>>> On 19.06.15 at 20:44, wrote: > Save VPMU state during context switch for both HVM and PV(H) guests. > > A subsequent patch ("x86/VPMU: NMI-based VPMU support") will make it possible > for vpmu_switch_to() to call vmx_vmcs_try_enter()->vcpu_pause() which needs > is_running to be correctly set/

Re: [Xen-devel] [PATCH v25 04/15] x86/VPMU: Interface for setting PMU mode and flags

2015-06-22 Thread Jan Beulich
>>> On 19.06.15 at 20:44, wrote: > Add runtime interface for setting PMU mode and flags. Three main modes are > provided: > * XENPMU_MODE_OFF: PMU is not virtualized > * XENPMU_MODE_SELF: Guests can access PMU MSRs and receive PMU interrupts. > * XENPMU_MODE_HV: Same as XENPMU_MODE_SELF for non-p

Re: [Xen-devel] [RFC PATCH v3 04/18] xen/arm: gicv3: Refactor redistributor information

2015-06-22 Thread Julien Grall
Hi, On 22/06/15 13:01, vijay.kil...@gmail.com wrote: > From: Vijaya Kumar K > > Separate redistributor information into rdist and rdist_prop > structures. > > The rdist_prop holds the redistributor common information > and rdist holds the per cpu specific information. > > This percpu rdist def

[Xen-devel] [PATCH v4 RFC 1/6] x86/PCI: add config space write abstract intercept logic

2015-06-22 Thread Jan Beulich
This is to be used by MSI code, and later to also be hooked up to MMCFG accesses by Dom0. Signed-off-by: Jan Beulich --- a/xen/arch/x86/msi.c +++ b/xen/arch/x86/msi.c @@ -,6 +,12 @@ void pci_cleanup_msi(struct pci_dev *pde msi_free_irqs(pdev); } +int pci_msi_conf_write_intercept(

[Xen-devel] [PATCH v4 RFC 6/6] x86/MSI: properly track guest masking requests

2015-06-22 Thread Jan Beulich
... by monitoring writes to the mask register. This allows reverting the main effect of the XSA-129 patches in qemu. Signed-off-by: Jan Beulich --- a/xen/arch/x86/msi.c +++ b/xen/arch/x86/msi.c @@ -1308,6 +1308,39 @@ printk("%04x:%02x:%02x.%u: MSI-X %03x:%u return 1; } +entr

[Xen-devel] [PATCH v4 RFC 5/6] x86/MSI-X: reduce fiddling with control register during restore

2015-06-22 Thread Jan Beulich
Rather than disabling and enabling MSI-X once per vector, do it just once per device. Signed-off-by: Jan Beulich Reviewed-by: Andrew Cooper --- a/xen/arch/x86/msi.c +++ b/xen/arch/x86/msi.c @@ -1319,6 +1319,9 @@ int pci_restore_msi_state(struct pci_dev struct msi_desc *entry, *tmp; st

[Xen-devel] [PATCH v4 4/6] x86/MSI-X: access MSI-X table only after having enabled MSI-X

2015-06-22 Thread Jan Beulich
As done in Linux by f598282f51 ("PCI: Fix the NIU MSI-X problem in a better way") and its broken predecessor, make sure we don't access the MSI-X table without having enabled MSI-X first, using the mask-all flag instead to prevent interrupts from occurring. Signed-off-by: Jan Beulich Reviewed-by:

[Xen-devel] [PATCH v4 3/6] x86/MSI-X: be more careful during teardown

2015-06-22 Thread Jan Beulich
When a device gets detached from a guest, pciback will clear its command register, thus disabling both memory and I/O decoding. The disabled memory decoding, however, has an effect on the MSI-X table accesses the hypervisor does: These won't have the intended effect anymore. Even worse, for PCIe de

Re: [Xen-devel] [PATCH 1/2] xen{trace/analyze}: don't use 64bit versions of libc functions

2015-06-22 Thread Roger Pau Monné
El 22/06/15 a les 12.09, George Dunlap ha escrit: > On 06/22/2015 10:59 AM, Roger Pau Monné wrote: >> El 22/06/15 a les 11.08, George Dunlap ha escrit: >>> On 06/19/2015 09:58 AM, Roger Pau Monne wrote: This is not needed, neither encouraged. Configure already checks _FILE_OFFSET_BITS and

[Xen-devel] [PATCH v4 RFC 2/6] x86/MSI-X: track host and guest mask‑all requests separately

2015-06-22 Thread Jan Beulich
Host uses of the bits will be added subsequently, and must not be overridden by guests (including Dom0, namely when acting on behalf of a guest). Signed-off-by: Jan Beulich --- a/xen/arch/x86/msi.c +++ b/xen/arch/x86/msi.c @@ -846,6 +846,12 @@ static int msix_capability_init(struct p if (

[Xen-devel] [libvirt test] 58823: tolerable FAIL - PUSHED

2015-06-22 Thread osstest service user
flight 58823 libvirt real [real] http://logs.test-lab.xenproject.org/osstest/logs/58823/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-amd64-i386-libvirt 11 guest-start fail like 58767 test-amd64-amd64-libvirt 11 gu

  1   2   >