Re: [Xen-devel] Xen Project Security Process Whitepaper v1 is ready for community review

2018-06-26 Thread Steven Haigh
On Tuesday, 5 June 2018 8:34:28 PM AEST George Dunlap wrote: > On Mon, Jun 4, 2018 at 3:55 PM, Lars Kurth wrote: > > 2.2.3 B. Git baseline of patches > > This created quite a bit of discussion and we did learn a few things: > > * From the thread, having to cherry pick a small (around 5-6) patches

[Xen-devel] [freebsd-master test] 124751: all pass - PUSHED

2018-06-26 Thread osstest service owner
flight 124751 freebsd-master real [real] http://logs.test-lab.xenproject.org/osstest/logs/124751/ Perfect :-) All tests in this flight passed as required version targeted for testing: freebsd 0246611c60edfa274ca0504bc3bbe6a884bfb25e baseline version: freebsd 635457b6a00

[Xen-devel] [freebsd-master test] 124750: all pass - PUSHED

2018-06-26 Thread osstest service owner
flight 124750 freebsd-master real [real] http://logs.test-lab.xenproject.org/osstest/logs/124750/ Perfect :-) All tests in this flight passed as required version targeted for testing: freebsd 635457b6a00a5f5ed87674e7362064f66bf58a9e baseline version: freebsd 120832ac318

[Xen-devel] [PATCH 7/6] x86/msr: Introduce msr_{set, clear}_bits() helpers

2018-06-26 Thread Andrew Cooper
One reoccuring code pattern is to read an MSR, modify one or more bits, and write the result back. Introduce helpers for this purpose. First, introduce rdmsr_split() and wrmsr_split() which are tiny static inline wrappers which deal with the MSR value in two 32bit halves. Next, construct msr_{se

Re: [Xen-devel] [PATCH 4/6] x86/msr: Clean up the MSR_FEATURE_CONTROL constants

2018-06-26 Thread Andrew Cooper
On 26/06/18 14:18, Andrew Cooper wrote: > xen/arch/x86/cpu/mwait-idle.c | 4 ++-- I forgot to say that this patch as shown may impact the ease of taking new code from Linux. While we don't want to proliferate the broken APIs of the current rdmsr() infrastructure, one option we could do is

Re: [Xen-devel] [PATCH v9] new config option vtsc_tolerance_khz to avoid TSC emulation

2018-06-26 Thread Olaf Hering
Am Thu, 7 Jun 2018 15:08:29 +0200 schrieb Olaf Hering : > Add an option to control when vTSC emulation will be activated for a > domU with tsc_mode=default. Without such option each TSC access from > domU will be emulated, which causes a significant perfomance drop for > workloads that make use o

Re: [Xen-devel] [PATCH 3/6] x86/msr: Clean up the MSR_{PLATFORM_INFO, MISC_FEATURES_ENABLES} constants

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 02:18:15PM +0100, Andrew Cooper wrote: > These MSRs, while being Intel specific, are used to offer virtualised > CPUID faulting support on AMD hardware, so remove the INTEL infix. > > The bit position constants are used by guest_rdmsr(), but the logic can > be expressed usi

[Xen-devel] [xen-unstable-smoke test] 124719: trouble: blocked/broken/pass/preparing/queued

2018-06-26 Thread osstest service owner
flight 124719 xen-unstable-smoke running [real] http://logs.test-lab.xenproject.org/osstest/logs/124719/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-armhf broken build-armhf

[Xen-devel] [xen-unstable test] 124715: trouble: blocked/broken/pass/preparing/queued

2018-06-26 Thread osstest service owner
flight 124715 xen-unstable running [real] http://logs.test-lab.xenproject.org/osstest/logs/124715/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-i386-xsm broken build-amd64-prev

[Xen-devel] [seabios test] 124731: trouble: blocked/broken/preparing/queued

2018-06-26 Thread osstest service owner
flight 124731 seabios running [real] http://logs.test-lab.xenproject.org/osstest/logs/124731/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64 broken build-i386-pvops

[Xen-devel] [linux-4.14 test] 124697: trouble: blocked/broken/pass/preparing/queued

2018-06-26 Thread osstest service owner
flight 124697 linux-4.14 running [real] http://logs.test-lab.xenproject.org/osstest/logs/124697/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64-xsm broken build-amd64-pvops

[Xen-devel] [libvirt test] 124690: regressions - trouble: blocked/broken/fail/pass/preparing/queued/running

2018-06-26 Thread osstest service owner
flight 124690 libvirt running [real] http://logs.test-lab.xenproject.org/osstest/logs/124690/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64-pvopsbroken build-amd64

[Xen-devel] [ovmf test] 124717: trouble: blocked/broken/preparing/queued

2018-06-26 Thread osstest service owner
flight 124717 ovmf running [real] http://logs.test-lab.xenproject.org/osstest/logs/124717/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64-xsm broken build-amd64

[Xen-devel] [linux-linus test] 124723: trouble: blocked/broken/pass/preparing/queued

2018-06-26 Thread osstest service owner
flight 124723 linux-linus running [real] http://logs.test-lab.xenproject.org/osstest/logs/124723/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64 broken build-i386-pvops

Re: [Xen-devel] [PATCH 2/6] x86/msr: Cleanup of misc constants

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 02:18:14PM +0100, Andrew Cooper wrote: > Begin the process of cleaning up msr-index.h. Order the MSRs at the > head of the file by index, use spaces for indentation, _AC() for bit > positions, and add a comment describing the expected style. Abbreviate > the ARCH_CAPS_* co

[Xen-devel] [qemu-mainline test] 124691: trouble: blocked/broken/pass/preparing/queued

2018-06-26 Thread osstest service owner
flight 124691 qemu-mainline running [real] http://logs.test-lab.xenproject.org/osstest/logs/124691/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64-pvopsbroken build-amd64

[Xen-devel] [linux-next test] 124687: trouble: blocked/broken/pass/queued/running

2018-06-26 Thread osstest service owner
flight 124687 linux-next running [real] http://logs.test-lab.xenproject.org/osstest/logs/124687/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-i386 broken build-amd64

Re: [Xen-devel] [PATCH 1/6] x86/msr: Clean up the MSR_EFER constants

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 02:18:13PM +0100, Andrew Cooper wrote: > The bit position constants are only used by the trampoline asm, but the > code is shorter and clearer when using the mask constants. This halves > the number of constants used. > > Consistently use _AC() for the bit constants, and s

[Xen-devel] [linux-3.18 test] 124729: trouble: blocked/broken/fail/pass/preparing/queued/running

2018-06-26 Thread osstest service owner
flight 124729 linux-3.18 running [real] http://logs.test-lab.xenproject.org/osstest/logs/124729/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64-pvopsbroken build-i386-pvops

[Xen-devel] [linux-4.9 test] 124712: trouble: blocked/broken/pass/preparing/queued

2018-06-26 Thread osstest service owner
flight 124712 linux-4.9 running [real] http://logs.test-lab.xenproject.org/osstest/logs/124712/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-i386 broken build-amd64-xsm

[Xen-devel] [freebsd-master test] 124732: trouble: pass/running

2018-06-26 Thread osstest service owner
flight 124732 freebsd-master running [real] http://logs.test-lab.xenproject.org/osstest/logs/124732/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64-freebsd-again 4 syslog-serverrunning bu

Re: [Xen-devel] 4.11.0 RC1 panic

2018-06-26 Thread Jan Beulich
>>> On 25.06.18 at 10:33, wrote: > On Thu, Jun 14, 2018 at 08:33:17AM -0600, Jan Beulich wrote: >> > So far I've not been able to make Xen panic with the new xen kernel. >> > Attached is a log of the serial console, in case you notice something. >> >> None of the printk()s replacing ASSERT()s hav

[Xen-devel] [PATCH V3] x86/altp2m: Fix crash with INVALID_ALTP2M EPTP index

2018-06-26 Thread Razvan Cojocaru
When SECONDARY_EXEC_ENABLE_VIRT_EXCEPTIONS is set, vmx_vcpu_update_eptp() __vmwrites() EPTP_INDEX in altp2m_vcpu_destroy(). This means that when disabling altp2m on a domain after xc_altp2m_set_vcpu_enable_notify() has been successfully called, EPTP_INDEX ends up being stored as INVALID_ALTP2M. Thi

Re: [Xen-devel] [PATCH for-4.12 0/3] process docs: Branching checklist updates

2018-06-26 Thread Wei Liu
On Mon, Jun 25, 2018 at 03:53:09PM +0100, Ian Jackson wrote: > From: Ian Jackson > > Today's run through the branching checklist generated these > doc improvement suggestions. I don't think an ack is needed by in any case: Acked-by: Wei Liu ___ Xen-

Re: [Xen-devel] [PATCH v8 01/11] x86/cpu: Introduce vmce_save_vcpu_ctxt_one() func

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 03:11:39PM +0100, Wei Liu wrote: > On Mon, Jun 25, 2018 at 05:50:37PM +0300, Alexandru Isaila wrote: > > This is used to save data from a single instance. > > > > Signed-off-by: Alexandru Isaila > > Reviewed-by: Wei Liu Oh, actually Paul asked you to define the return v

Re: [Xen-devel] [PATCH v8 01/11] x86/cpu: Introduce vmce_save_vcpu_ctxt_one() func

2018-06-26 Thread Wei Liu
On Mon, Jun 25, 2018 at 05:50:37PM +0300, Alexandru Isaila wrote: > This is used to save data from a single instance. > > Signed-off-by: Alexandru Isaila Reviewed-by: Wei Liu ___ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xen

Re: [Xen-devel] [PATCH v8 03/11] x86/hvm: Introduce hvm_save_cpu_ctxt_one func

2018-06-26 Thread Jan Beulich
>>> On 25.06.18 at 16:50, wrote: > --- a/xen/arch/x86/hvm/hvm.c > +++ b/xen/arch/x86/hvm/hvm.c > @@ -786,117 +786,127 @@ static int hvm_load_tsc_adjust(struct domain *d, > hvm_domain_context_t *h) > HVM_REGISTER_SAVE_RESTORE(TSC_ADJUST, hvm_save_tsc_adjust, >hvm_load_

Re: [Xen-devel] [PATCH V2] x86/altp2m: Fixed crash with INVALID_ALTP2M EPTP index

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 14:49, wrote: > So assuming that the HVMOPs are properly handled atomically with respect > to their corresponding VCPU (which I now believe to be the case), the > only possible issue that remains (that I can think of) is the case where > EPTP_INDEX has been saved in a previous r

[Xen-devel] [PATCH 4/6] x86/msr: Clean up the MSR_FEATURE_CONTROL constants

2018-06-26 Thread Andrew Cooper
The existing bit names are excessively long (45 chars!), and can be trimmed down substantially. Drop the IA32 prefix and abbreviate FEATURE_CONTROL to FEAT_CTL. Furthermore, all of these are feature enablement bits, so drop ENABLE/ON parts of the constants. While altering all the users, take the

[Xen-devel] [PATCH 6/6] x86/msr: Clean up the x2APIC MSR constants

2018-06-26 Thread Andrew Cooper
The name MSR_IA32_APICBASE_MSR doesn't logically relate to its purpose. Rename it to MSR_X2APIC_FIRST and introduce a corresponding MSR_X2APIC_LAST to avoid opencoding the length of the x2APIC MSR range. For the specific registers, drop the IA32 infix, break the APIC part away from the register na

[Xen-devel] [PATCH 3/6] x86/msr: Clean up the MSR_{PLATFORM_INFO, MISC_FEATURES_ENABLES} constants

2018-06-26 Thread Andrew Cooper
These MSRs, while being Intel specific, are used to offer virtualised CPUID faulting support on AMD hardware, so remove the INTEL infix. The bit position constants are used by guest_rdmsr(), but the logic can be expressed using MASK_INSR() which allows the removal of the bit position constants. S

[Xen-devel] [PATCH 5/6] x86/msr: Clean up the MSR_APIC_BASE constants

2018-06-26 Thread Andrew Cooper
We currently have MSR_IA32_APICBASE and MSR_IA32_APICBASE_MSR which are synonymous from a naming point of view, but refer to very different things. Cleave out the handling of MSR_APIC_BASE (0x1b), and rename MSR_IA32_APICBASE_BASE to APIC_BASE_ADDR_MASK to better describe its purpose. Signed-off-

[Xen-devel] [PATCH 1/6] x86/msr: Clean up the MSR_EFER constants

2018-06-26 Thread Andrew Cooper
The bit position constants are only used by the trampoline asm, but the code is shorter and clearer when using the mask constants. This halves the number of constants used. Consistently use _AC() for the bit constants, and start to use spaces for indentation. Furthermore, EFER contains the NX-En

[Xen-devel] [PATCH 0/6] x86/msr: Introductory MSR cleanup

2018-06-26 Thread Andrew Cooper
This series is a combination of fragments already posted, and cleanup work I did while travelling in/around XenSummit. There is no real functional change, but there is a lot of code volume reduction and consistency improvements. This is the start of a very large amount of MSR improvement work. A

[Xen-devel] [PATCH 2/6] x86/msr: Cleanup of misc constants

2018-06-26 Thread Andrew Cooper
Begin the process of cleaning up msr-index.h. Order the MSRs at the head of the file by index, use spaces for indentation, _AC() for bit positions, and add a comment describing the expected style. Abbreviate the ARCH_CAPS_* constants to reduce code volume. Leave a trailing comment to logically s

Re: [Xen-devel] [PATCH 0/2] xen/xsm: Cleanup in preparation for XSM SILO mode

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 14:42, wrote: > On 26/06/18 13:04, Jan Beulich wrote: > On 26.06.18 at 13:09, wrote: >>> Future changes will introduce a new SILO mode, which is intended to be >>> useful >>> for cloud and enterprise setups where all domUs are unprivileged and have no >>> buisness communic

Re: [Xen-devel] [PATCH V2] x86/altp2m: Fixed crash with INVALID_ALTP2M EPTP index

2018-06-26 Thread Razvan Cojocaru
On 06/26/2018 03:06 PM, Razvan Cojocaru wrote: > On 06/26/2018 02:56 PM, Jan Beulich wrote: > On 26.06.18 at 12:55, wrote: >>> On 06/26/2018 01:26 PM, Jan Beulich wrote: >>> On 25.06.18 at 16:10, wrote: > --- a/xen/arch/x86/mm/altp2m.c > +++ b/xen/arch/x86/mm/altp2m.c > @@ -58

Re: [Xen-devel] [PATCH 0/2] xen/xsm: Cleanup in preparation for XSM SILO mode

2018-06-26 Thread Andrew Cooper
On 26/06/18 13:04, Jan Beulich wrote: On 26.06.18 at 13:09, wrote: >> Future changes will introduce a new SILO mode, which is intended to be useful >> for cloud and enterprise setups where all domUs are unprivileged and have no >> buisness communicating directly. >> >> This was discussed at X

Re: [Xen-devel] [PATCH v8 07/11] x86/hvm: Introduce viridian_save_vcpu_ctxt_one() func

2018-06-26 Thread Alexandru Stefan ISAILA
On Ma, 2018-06-26 at 11:07 +, Paul Durrant wrote: > > > > -Original Message- > > From: Alexandru Isaila [mailto:aisa...@bitdefender.com] > > Sent: 25 June 2018 15:51 > > To: xen-de...@lists.xen.org > > Cc: Ian Jackson ; Wei Liu > com>; > > jbeul...@suse.com; Andrew Cooper ; Paul > > D

Re: [Xen-devel] [PATCH V2] x86/altp2m: Fixed crash with INVALID_ALTP2M EPTP index

2018-06-26 Thread Razvan Cojocaru
On 06/26/2018 02:56 PM, Jan Beulich wrote: On 26.06.18 at 12:55, wrote: >> On 06/26/2018 01:26 PM, Jan Beulich wrote: >> On 25.06.18 at 16:10, wrote: --- a/xen/arch/x86/mm/altp2m.c +++ b/xen/arch/x86/mm/altp2m.c @@ -58,8 +58,8 @@ altp2m_vcpu_destroy(struct vcpu *v)

Re: [Xen-devel] [PATCH 0/2] xen/xsm: Cleanup in preparation for XSM SILO mode

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 13:09, wrote: > Future changes will introduce a new SILO mode, which is intended to be useful > for cloud and enterprise setups where all domUs are unprivileged and have no > buisness communicating directly. > > This was discussed at XenSummit, but I'll leave further details to

Re: [Xen-devel] [PATCH V2] x86/altp2m: Fixed crash with INVALID_ALTP2M EPTP index

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 12:55, wrote: > On 06/26/2018 01:26 PM, Jan Beulich wrote: > On 25.06.18 at 16:10, wrote: >>> --- a/xen/arch/x86/mm/altp2m.c >>> +++ b/xen/arch/x86/mm/altp2m.c >>> @@ -58,8 +58,8 @@ altp2m_vcpu_destroy(struct vcpu *v) >>> >>> altp2m_vcpu_reset(v); >>> >>> -altp

Re: [Xen-devel] [PATCH] SVM: limit GIF=0 region

2018-06-26 Thread Andrew Cooper
On 26/06/18 12:53, Andrew Cooper wrote: > On 26/06/18 12:50, Jan Beulich wrote: > On 26.06.18 at 12:52, wrote: >>> On 26/06/18 10:52, Jan Beulich wrote: >>> On 26.06.18 at 10:45, wrote: > On 26/06/2018 08:32, Jan Beulich wrote: >> Use EFLAGS.IF for all ordinary purposes; there's i

[Xen-devel] [freebsd-master test] 124724: all pass - PUSHED

2018-06-26 Thread osstest service owner
flight 124724 freebsd-master real [real] http://logs.test-lab.xenproject.org/osstest/logs/124724/ Perfect :-) All tests in this flight passed as required version targeted for testing: freebsd 120832ac318f335dedfba859043b74375bba5e51 baseline version: freebsd a550f635ac0

Re: [Xen-devel] [PATCH] SVM: limit GIF=0 region

2018-06-26 Thread Andrew Cooper
On 26/06/18 12:50, Jan Beulich wrote: On 26.06.18 at 12:52, wrote: >> On 26/06/18 10:52, Jan Beulich wrote: >> On 26.06.18 at 10:45, wrote: On 26/06/2018 08:32, Jan Beulich wrote: > Use EFLAGS.IF for all ordinary purposes; there's in particular no need > to unduly defer NMI/

Re: [Xen-devel] [PATCH] SVM: limit GIF=0 region

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 12:52, wrote: > On 26/06/18 10:52, Jan Beulich wrote: > On 26.06.18 at 10:45, wrote: >>> On 26/06/2018 08:32, Jan Beulich wrote: Use EFLAGS.IF for all ordinary purposes; there's in particular no need to unduly defer NMI/#MC. Clear/set GIF solely around VMRUN itsel

Re: [Xen-devel] [PATCH] gnttab: silence table expansion message

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 13:14, wrote: > On 26/06/18 08:22, Jan Beulich wrote: >> This currently shows up for basically every domain, when originally it >> was logged only when going beyond the default table size. Restore that >> behavior. >> >> Signed-off-by: Jan Beulich >> >> --- a/xen/common/grant_t

[Xen-devel] [PATCH] x86/pv: Deprecate support for paging out the LDT

2018-06-26 Thread Andrew Cooper
This code is believed to be vestigial remnant of the PV Windows XP port. It is not used by Linux, NetBSD, Solaris or MiniOS. Furthermore the implementation is incomplete; it only functions for a present => not-present transition, rather than a present => read/write transition. The for_each_vcpu(

[Xen-devel] [seabios test] 124713: trouble: blocked/broken

2018-06-26 Thread osstest service owner
flight 124713 seabios real [real] http://logs.test-lab.xenproject.org/osstest/logs/124713/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-amd64-pvopsbroken build-i386-pvops

Re: [Xen-devel] [PATCH] x86: correctly set nonlazy_xstate_used when loading full state

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 02:11:32AM -0600, Jan Beulich wrote: > >>> On 26.06.18 at 09:57, wrote: > > On Tue, Jun 26, 2018 at 01:47:12AM -0600, Jan Beulich wrote: > >> In this case, just like xcr0_accum, nonlazy_xstate_used should always be > >> set to the intended new value, rather than possibly le

Re: [Xen-devel] [PATCH] gnttab: silence table expansion message

2018-06-26 Thread Paul Durrant
> -Original Message- > From: Xen-devel [mailto:xen-devel-boun...@lists.xenproject.org] On Behalf > Of Andrew Cooper > Sent: 26 June 2018 12:15 > To: Jan Beulich ; xen-devel de...@lists.xenproject.org> > Cc: Stefano Stabellini ; Wei Liu > ; George Dunlap ; Tim > (Xen.org) ; Ian Jackson ; Ju

Re: [Xen-devel] [PATCH for-4.11 v2] x86/EFI: further correct FPU state handling around runtime calls

2018-06-26 Thread Juergen Gross
On 25/06/18 14:17, Jan Beulich wrote: > We must not leave a vCPU with CR0.TS clear when it is not in fully eager > mode and has not touched non-lazy state. Instead of adding a 3rd > invocation of stts() to vcpu_restore_fpu_eager(), consolidate all of > them into a single one done at the end of the

Re: [Xen-devel] [PATCH] gnttab: silence table expansion message

2018-06-26 Thread Andrew Cooper
On 26/06/18 08:22, Jan Beulich wrote: > This currently shows up for basically every domain, when originally it > was logged only when going beyond the default table size. Restore that > behavior. > > Signed-off-by: Jan Beulich > > --- a/xen/common/grant_table.c > +++ b/xen/common/grant_table.c > @

[Xen-devel] [PATCH v3 1/6] Tools.mk.in: drop unused variables

2018-06-26 Thread Wei Liu
Signed-off-by: Wei Liu --- Cc: Ian Jackson --- config/Tools.mk.in | 2 -- 1 file changed, 2 deletions(-) diff --git a/config/Tools.mk.in b/config/Tools.mk.in index 2d6c440324..4cc9f29090 100644 --- a/config/Tools.mk.in +++ b/config/Tools.mk.in @@ -20,8 +20,6 @@ BCC := @BCC@ IAS

[Xen-devel] [PATCH v3 6/6] tools: --with-system-{ovmf, seabios, ipxe} should provide absolute paths

2018-06-26 Thread Wei Liu
The paths shouldn't be set to "yes". Reported-by: Anthony Perard Signed-off-by: Wei Liu --- v3: really check for absolute paths. Cc: Ian Jackson new in v2 --- tools/configure| 9 ++--- tools/configure.ac | 9 ++--- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/t

[Xen-devel] [PATCH v3 4/6] tools: load IPXE from standalone file

2018-06-26 Thread Wei Liu
Do not embed IPXE into Rombios anymore. Instead, it is loaded by the toolstack from a file as a separate module. Ability to let user specify an IPXE blob will come later. No user visible change. Signed-off-by: Wei Liu Acked-by: Jan Beulich --- v3: adjust libxl code a bit, addressed Jan's comme

[Xen-devel] [PATCH v3 2/6] ipxe: produce a single binary from its build

2018-06-26 Thread Wei Liu
And switch hvmloader/Makefile to use that binary. This will help later when we change hvmloader to pick a user provided binary. No functional change. Signed-off-by: Wei Liu Acked-by: Jan Beulich --- v2: use intermediary file Cc: Ian Jackson --- tools/firmware/etherboot/Makefile | 7 ++-

[Xen-devel] [PATCH v3 3/6] libxc: allow HVM guest to have modules

2018-06-26 Thread Wei Liu
Lift the loading code out of PVH specific branch. Take the chance to make the debug message more useful. Now the code needs to take into account virt_base. IPXE will be loaded as a module of Rombios. Signed-off-by: Wei Liu Reviewed-by: Roger Pau Monné --- Cc: Ian Jackson --- tools/libxc/xc_d

[Xen-devel] [PATCH v3 0/6] Load ipxe from a standalone file

2018-06-26 Thread Wei Liu
Addressed Jan and Roger's comments. Wei Liu (6): Tools.mk.in: drop unused variables ipxe: produce a single binary from its build libxc: allow HVM guest to have modules tools: load IPXE from standalone file tools: provide --with-system-ipxe tools: --with-system-{ovmf,seabios,ipxe} shoul

[Xen-devel] [PATCH v3 5/6] tools: provide --with-system-ipxe

2018-06-26 Thread Wei Liu
Signed-off-by: Wei Liu --- v3: ipxe should require rombios Cc: Ian Jackson --- config/Tools.mk.in| 1 + tools/config.h.in | 3 +++ tools/configure | 58 +++ tools/configure.ac| 23 +++ tools/libxl/li

[Xen-devel] [PATCH 2/2] xen/xsm: Rename CONIFIG_XSM_POLICY to CONFIG_XSM_FLASK_POLICY

2018-06-26 Thread Andrew Cooper
The embedded policy is specific flask, so update the infrastructure to reflect this. Signed-off-by: Andrew Cooper --- CC: Daniel De Graaf CC: George Dunlap CC: Jan Beulich CC: Konrad Rzeszutek Wilk CC: Stefano Stabellini CC: Tim Deegan CC: Wei Liu CC: Sergey Dyasli CC: Xin Li CC: Ming Lu

[Xen-devel] [PATCH 1/2] xen/xsm: Rename CONFIG_FLASK_* to CONFIG_XSM_FLASK_*

2018-06-26 Thread Andrew Cooper
Flask is one single XSM module, and another is about to be introduced. Properly namespace the symbols for clarity. No functional change. Signed-off-by: Andrew Cooper --- CC: Daniel De Graaf CC: George Dunlap CC: Jan Beulich CC: Konrad Rzeszutek Wilk CC: Stefano Stabellini CC: Tim Deegan CC

[Xen-devel] [PATCH 0/2] xen/xsm: Cleanup in preparation for XSM SILO mode

2018-06-26 Thread Andrew Cooper
Future changes will introduce a new SILO mode, which is intended to be useful for cloud and enterprise setups where all domUs are unprivileged and have no buisness communicating directly. This was discussed at XenSummit, but I'll leave further details to the series which introduces it. However, t

Re: [Xen-devel] [PATCH v8 07/11] x86/hvm: Introduce viridian_save_vcpu_ctxt_one() func

2018-06-26 Thread Paul Durrant
> -Original Message- > From: Alexandru Isaila [mailto:aisa...@bitdefender.com] > Sent: 25 June 2018 15:51 > To: xen-de...@lists.xen.org > Cc: Ian Jackson ; Wei Liu ; > jbeul...@suse.com; Andrew Cooper ; Paul > Durrant ; Alexandru Isaila > > Subject: [PATCH v8 07/11] x86/hvm: Introduce > vi

Re: [Xen-devel] [PATCH v8 00/11] x86/domctl: Save info for one vcpu instance

2018-06-26 Thread Paul Durrant
> -Original Message- > From: Alexandru Isaila [mailto:aisa...@bitdefender.com] > Sent: 25 June 2018 15:51 > To: xen-de...@lists.xen.org > Cc: Ian Jackson ; Wei Liu ; > jbeul...@suse.com; Andrew Cooper ; Paul > Durrant > Subject: [Xen-devel] [PATCH v8 00/11] x86/domctl: Save info for one vc

Re: [Xen-devel] [PATCH v8 03/11] x86/hvm: Introduce hvm_save_cpu_ctxt_one func

2018-06-26 Thread Paul Durrant
> -Original Message- > From: Alexandru Isaila [mailto:aisa...@bitdefender.com] > Sent: 25 June 2018 15:51 > To: xen-de...@lists.xen.org > Cc: Ian Jackson ; Wei Liu ; > jbeul...@suse.com; Andrew Cooper ; Paul > Durrant ; Alexandru Isaila > > Subject: [PATCH v8 03/11] x86/hvm: Introduce hvm_

Re: [Xen-devel] [PATCH V2] x86/altp2m: Fixed crash with INVALID_ALTP2M EPTP index

2018-06-26 Thread Razvan Cojocaru
On 06/26/2018 01:26 PM, Jan Beulich wrote: On 25.06.18 at 16:10, wrote: >> When SECONDARY_EXEC_ENABLE_VIRT_EXCEPTIONS is set, >> vmx_vcpu_update_eptp() __vmwrites() EPTP_INDEX in >> altp2m_vcpu_destroy(). This means that when disabling altp2m on a >> domain after xc_altp2m_set_vcpu_enable_not

Re: [Xen-devel] [PATCH] x86/idle: don't mix up ACPI and APIC IDs

2018-06-26 Thread Andrew Cooper
On 26/06/18 08:35, Jan Beulich wrote: > Correct a log message and, to clarify code as well, rename the > respective function parameter too. > > Signed-off-by: Jan Beulich > > --- a/xen/arch/x86/acpi/cpu_idle.c > +++ b/xen/arch/x86/acpi/cpu_idle.c > @@ -1172,7 +1172,7 @@ static void print_cx_pminfo

Re: [Xen-devel] [PATCH] SVM: limit GIF=0 region

2018-06-26 Thread Andrew Cooper
On 26/06/18 10:52, Jan Beulich wrote: On 26.06.18 at 10:45, wrote: >> On 26/06/2018 08:32, Jan Beulich wrote: >>> Use EFLAGS.IF for all ordinary purposes; there's in particular no need >>> to unduly defer NMI/#MC. Clear/set GIF solely around VMRUN itself. This >>> has the additional advantage

[Xen-devel] [linux-3.18 test] 124678: trouble: blocked/broken/fail/pass

2018-06-26 Thread osstest service owner
flight 124678 linux-3.18 real [real] http://logs.test-lab.xenproject.org/osstest/logs/124678/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-i386 broken build-i386-xsm

[Xen-devel] [distros-debian-snapshot test] 74910: trouble: blocked/broken

2018-06-26 Thread Platform Team regression test user
flight 74910 distros-debian-snapshot real [real] http://osstest.xs.citrite.net/~osstest/testlogs/logs/74910/ Failures and problems with tests :-( Tests which did not succeed and are blocking, including tests which could not be run: build-armhf-pvopsbroken build-i

Re: [Xen-devel] [PATCH for-4.11 v2 3/3] VMX: check host CR0 before entering guest

2018-06-26 Thread Andrew Cooper
On 26/06/18 07:38, Jan Beulich wrote: > While we don't expect CR0 to change behind our backs, cope with this > happening, but other than for CR4 also log a (debug) message. > > Signed-off-by: Jan Beulich > > --- a/xen/arch/x86/hvm/vmx/vmcs.c > +++ b/xen/arch/x86/hvm/vmx/vmcs.c > @@ -1676,7 +1676,7

Re: [Xen-devel] [PATCH V2] x86/altp2m: Fixed crash with INVALID_ALTP2M EPTP index

2018-06-26 Thread Jan Beulich
>>> On 25.06.18 at 16:10, wrote: > When SECONDARY_EXEC_ENABLE_VIRT_EXCEPTIONS is set, > vmx_vcpu_update_eptp() __vmwrites() EPTP_INDEX in > altp2m_vcpu_destroy(). This means that when disabling altp2m on a > domain after xc_altp2m_set_vcpu_enable_notify() has been > successfully called, EPTP_INDEX

Re: [Xen-devel] [PATCH for-4.11 v2 2/3] x86: guard against #NM

2018-06-26 Thread Andrew Cooper
On 26/06/18 10:57, Jan Beulich wrote: > >>> +_p(regs->rip), _p(regs->rip), _p(fixup)); >>> +/* >>> + * We mustn't come here, but for release builds have the recovery >> "We shouldn't be able to reach here..." > Well, okay - I did consider this weaker wording, but had

Re: [Xen-devel] [PATCH for-4.11 v2 2/3] x86: guard against #NM

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 11:41, wrote: > On 26/06/18 07:36, Jan Beulich wrote: >> --- a/xen/arch/x86/traps.c >> +++ b/xen/arch/x86/traps.c >> @@ -1749,7 +1749,21 @@ void do_device_not_available(struct cpu_ >> { >> struct vcpu *curr = current; >> >> -BUG_ON(!guest_mode(regs)); >> +if ( !g

Re: [Xen-devel] [PATCH] SVM: limit GIF=0 region

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 10:45, wrote: > On 26/06/2018 08:32, Jan Beulich wrote: >> Use EFLAGS.IF for all ordinary purposes; there's in particular no need >> to unduly defer NMI/#MC. Clear/set GIF solely around VMRUN itself. This >> has the additional advantage that svm_stgi_label now indeed marks the >

Re: [Xen-devel] [PATCH for-4.11 v2 2/3] x86: guard against #NM

2018-06-26 Thread Andrew Cooper
On 26/06/18 07:36, Jan Beulich wrote: > Just in case we still don't get CR0.TS handling right, prevent a host > crash by honoring exception fixups in do_device_not_available(). This > would in particular cover emulator stubs raising #NM. > > Signed-off-by: Jan Beulich > --- > v2: Add ASSERT_UNREAC

Re: [Xen-devel] [PATCH for-4.11 v2 1/3] x86/HVM: don't cause #NM to be raised in Xen

2018-06-26 Thread Andrew Cooper
On 26/06/18 07:36, Jan Beulich wrote: > The changes for XSA-267 did not touch management of CR0.TS for HVM > guests. In fully eager mode this bit should never be set when > respective vCPU-s are active, or else hvmemul_get_fpu() might leave it > wrongly set, leading to #NM in hypervisor context. >

Re: [Xen-devel] [PATCH] console: avoid printing no or null time stamps

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 10:43, wrote: > On 26/06/18 08:24, Jan Beulich wrote: >> During early boot timestamps aren't very useful, as they're all zero >> (in "boot" mode) or absent altogether (in "date" and "datems" modes). >> Log "boot" format timestamps when the date formats aren't available yet, >> a

Re: [Xen-devel] [PATCH for-4.11 v2 0/3] x86: XSA-267 follow-up

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 09:39, wrote: > On 26/06/18 08:24, Jan Beulich wrote: >> The first patch alone should be sufficient to address an issue with the >> XSA-267 changes, causing a BUG_ON() to be triggered. The other two >> patches would, afaict, each individually also have avoided the issue, >> henc

Re: [Xen-devel] [PATCH] SVM: limit GIF=0 region

2018-06-26 Thread Andrew Cooper
On 26/06/2018 08:32, Jan Beulich wrote: > Use EFLAGS.IF for all ordinary purposes; there's in particular no need > to unduly defer NMI/#MC. Clear/set GIF solely around VMRUN itself. This > has the additional advantage that svm_stgi_label now indeed marks the > only place where GIF is being set. > >

Re: [Xen-devel] [PATCH] console: avoid printing no or null time stamps

2018-06-26 Thread Julien Grall
Hi Jan, On 26/06/18 08:24, Jan Beulich wrote: During early boot timestamps aren't very useful, as they're all zero (in "boot" mode) or absent altogether (in "date" and "datems" modes). Log "boot" format timestamps when the date formats aren't available yet, and log raw timestamps when boot ones

Re: [Xen-devel] [PATCH v2 5/6] tools: provide --with-system-ipxe

2018-06-26 Thread Wei Liu
On Mon, Jun 25, 2018 at 06:09:53PM +0200, Roger Pau Monné wrote: > On Mon, Jun 25, 2018 at 12:35:32PM +0100, Wei Liu wrote: > > diff --git a/tools/configure.ac b/tools/configure.ac > > index 0826af8cbc..8e4b173d6f 100644 > > --- a/tools/configure.ac > > +++ b/tools/configure.ac > > @@ -84,6 +84,7 @

Re: [Xen-devel] [PATCH v2 6/6] tools: --with-system-{ovmf, seabios, ipxe} should provide absolute paths

2018-06-26 Thread Wei Liu
On Mon, Jun 25, 2018 at 06:21:06PM +0200, Roger Pau Monné wrote: > On Mon, Jun 25, 2018 at 12:35:33PM +0100, Wei Liu wrote: > > The paths shouldn't be set to "yes". > > If you want to check if an absolute path is provided I would rather > do: > > case $withval in > no) ovmf_path= ;; > /*)

Re: [Xen-devel] [PATCH v2 4/6] tools: load IPXE from standalone file

2018-06-26 Thread Wei Liu
On Mon, Jun 25, 2018 at 06:05:01PM +0200, Roger Pau Monné wrote: > On Mon, Jun 25, 2018 at 12:35:31PM +0100, Wei Liu wrote: > > diff --git a/tools/libxl/libxl_dom.c b/tools/libxl/libxl_dom.c > > index f0fd5fd3a3..1b9e45c492 100644 > > --- a/tools/libxl/libxl_dom.c > > +++ b/tools/libxl/libxl_dom.c

Re: [Xen-devel] [PATCH v2 3/6] libxc: allow HVM guest to have modules

2018-06-26 Thread Wei Liu
On Mon, Jun 25, 2018 at 05:58:52PM +0200, Roger Pau Monné wrote: > On Mon, Jun 25, 2018 at 12:35:30PM +0100, Wei Liu wrote: > > Lift the loading code out of PVH specific branch. Take the chance to > > make the debug message more useful. > > Would be nice to mention that you also account for virt_b

Re: [Xen-devel] [PATCH] x86: correctly set nonlazy_xstate_used when loading full state

2018-06-26 Thread Jan Beulich
>>> On 26.06.18 at 09:57, wrote: > On Tue, Jun 26, 2018 at 01:47:12AM -0600, Jan Beulich wrote: >> In this case, just like xcr0_accum, nonlazy_xstate_used should always be >> set to the intended new value, rather than possibly leaving the flag set >> from a prior state load. >> >> Signed-off-by:

Re: [Xen-devel] [PATCH] x86: correctly set nonlazy_xstate_used when loading full state

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 01:47:12AM -0600, Jan Beulich wrote: > In this case, just like xcr0_accum, nonlazy_xstate_used should always be > set to the intended new value, rather than possibly leaving the flag set > from a prior state load. > > Signed-off-by: Jan Beulich Why? Looking at the code it

Re: [Xen-devel] [PATCH] x86: fix dependency tracking for asm/indirect_thunk_asm.h

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 01:37:02AM -0600, Jan Beulich wrote: > Including the header solely at the assembler level means the compiler > can't record the header as a dependency in .*.o.d files. Arrange for the > header to be include-able at the C level instead. > > Signed-off-by: Jan Beulich Revie

[Xen-devel] [PATCH] x86: consolidate legacy FPU state loading

2018-06-26 Thread Jan Beulich
First of all introduce a helper function instead of replicating almost the same code for PV and HVM. The differences between the two pieces of code actually points out an issue (which is also addressed here): In the HVM case FCW would not have been set to FCW_RESET in certain cases (note for exampl

Re: [Xen-devel] PCI passthrough performance loss with Skylake-SP

2018-06-26 Thread Paul Durrant
> -Original Message- > From: Roger Pau Monne > Sent: 26 June 2018 07:57 > To: Andreas Kinzler > Cc: xen-de...@lists.xen.org; Paul Durrant > Subject: Re: [Xen-devel] PCI passthrough performance loss with Skylake-SP > > On Mon, Jun 25, 2018 at 05:32:58PM +0200, Andreas Kinzler wrote: > > I

[Xen-devel] [PATCH] x86: correctly set nonlazy_xstate_used when loading full state

2018-06-26 Thread Jan Beulich
In this case, just like xcr0_accum, nonlazy_xstate_used should always be set to the intended new value, rather than possibly leaving the flag set from a prior state load. Signed-off-by: Jan Beulich --- a/xen/arch/x86/domctl.c +++ b/xen/arch/x86/domctl.c @@ -1187,8 +1187,7 @@ long arch_do_domctl(

Re: [Xen-devel] [PATCH] x86/idle: don't mix up ACPI and APIC IDs

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 01:35:18AM -0600, Jan Beulich wrote: > Correct a log message and, to clarify code as well, rename the > respective function parameter too. > > Signed-off-by: Jan Beulich Reviewed-by: Wei Liu ___ Xen-devel mailing list Xen-deve

[Xen-devel] [freebsd-master test] 124708: all pass - PUSHED

2018-06-26 Thread osstest service owner
flight 124708 freebsd-master real [real] http://logs.test-lab.xenproject.org/osstest/logs/124708/ Perfect :-) All tests in this flight passed as required version targeted for testing: freebsd a550f635ac0ec8163d698717f0e31b9a7f998ef3 baseline version: freebsd c8b8ae9609e

Re: [Xen-devel] [PATCH for-4.11 v2 0/3] x86: XSA-267 follow-up

2018-06-26 Thread Juergen Gross
On 26/06/18 08:24, Jan Beulich wrote: > The first patch alone should be sufficient to address an issue with the > XSA-267 changes, causing a BUG_ON() to be triggered. The other two > patches would, afaict, each individually also have avoided the issue, > hence I'm also including them here. While th

[Xen-devel] [PATCH] x86: fix dependency tracking for asm/indirect_thunk_asm.h

2018-06-26 Thread Jan Beulich
Including the header solely at the assembler level means the compiler can't record the header as a dependency in .*.o.d files. Arrange for the header to be include-able at the C level instead. Signed-off-by: Jan Beulich --- a/xen/include/asm-x86/asm_defns.h +++ b/xen/include/asm-x86/asm_defns.h

Re: [Xen-devel] [freebsd-master test] 124705: regressions - trouble: blocked/fail

2018-06-26 Thread Roger Pau Monné
On Mon, Jun 25, 2018 at 09:34:16PM +, osstest service owner wrote: > flight 124705 freebsd-master real [real] > http://logs.test-lab.xenproject.org/osstest/logs/124705/ > > Regressions :-( > > Tests which did not succeed and are blocking, > including tests which could not be run: > build-amd

[Xen-devel] [PATCH] x86/idle: don't mix up ACPI and APIC IDs

2018-06-26 Thread Jan Beulich
Correct a log message and, to clarify code as well, rename the respective function parameter too. Signed-off-by: Jan Beulich --- a/xen/arch/x86/acpi/cpu_idle.c +++ b/xen/arch/x86/acpi/cpu_idle.c @@ -1172,7 +1172,7 @@ static void print_cx_pminfo(uint32_t cpu #define print_cx_pminfo(c, p) #endif

[Xen-devel] [PATCH] SVM: limit GIF=0 region

2018-06-26 Thread Jan Beulich
Use EFLAGS.IF for all ordinary purposes; there's in particular no need to unduly defer NMI/#MC. Clear/set GIF solely around VMRUN itself. This has the additional advantage that svm_stgi_label now indeed marks the only place where GIF is being set. A note regarding the main STI placement: Orignally

Re: [Xen-devel] [PATCH] gnttab: silence table expansion message

2018-06-26 Thread Wei Liu
On Tue, Jun 26, 2018 at 01:22:01AM -0600, Jan Beulich wrote: > This currently shows up for basically every domain, when originally it > was logged only when going beyond the default table size. Restore that > behavior. > > Signed-off-by: Jan Beulich Acked-by: Wei Liu __

  1   2   >