[Xen-devel] [PATCH v7 17/20] xen: use elfnote defines instead of plain numbers

2018-12-07 Thread Juergen Gross
In order to avoid using plain integers for the ELF notes use the available Xen include instead. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V5: new patch (Daniel Kiper) --- util/grub-mkimagexx.c | 14 -- 1 file changed, 8 insertions(+), 6 deletions(-) diff --git

[Xen-devel] [PATCH v7 18/20] xen_pvh: support building a standalone image

2018-12-07 Thread Juergen Gross
Support mkimage for xen_pvh. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V2: some style adjustments (Daniel Kiper) use defines for elf-notes (Daniel Kiper) V5: move elf-note define usage into new patch (Daniel Kiper) I didn't replace the 4096 by a PAGE_SIZE macro as

[Xen-devel] [PATCH v7 16/20] grub-module-verifier: Ignore all_video for xenpvh

2018-12-07 Thread Juergen Gross
From: Hans van Kranenburg This solves the build failing with "Error: no symbol table and no .moddeps section" Also see: - 6371e9c10433578bb236a8284ddb9ce9e201eb59 - https://savannah.gnu.org/bugs/?49012 Signed-off-by: Hans van Kranenburg Reviewed-by: Daniel Kiper --- V2: new patch

Re: [Xen-devel] [PATCH v2 02/18] xen: introduce new 'XenBus' and 'XenDevice' object hierarchy

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:28PM +, Paul Durrant wrote: > This patch adds the basic boilerplate for a 'XenBus' object that will act > as a parent to 'XenDevice' PV backends. > A new 'XenBridge' object is also added to connect XenBus to the system bus. > > The XenBus object is instantiated

Re: [Xen-devel] [PATCH v2 02/18] xen: introduce new 'XenBus' and 'XenDevice' object hierarchy

2018-12-07 Thread Paul Durrant
> -Original Message- > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > Sent: 07 December 2018 12:15 > To: Paul Durrant > Cc: qemu-de...@nongnu.org; qemu-bl...@nongnu.org; xen- > de...@lists.xenproject.org; Stefano Stabellini ; > Michael S. Tsirkin ; Marcel Apfelbaum > ; Paolo

Re: [Xen-devel] [xen-unstable test] 131065: regressions - FAIL

2018-12-07 Thread Andrew Cooper
On 07/12/2018 11:34, Wei Liu wrote: > On Fri, Dec 07, 2018 at 09:50:30AM +, Andrew Cooper wrote: >> On 07/12/2018 09:21, osstest service owner wrote: >>> flight 131065 xen-unstable real [real] >>> http://logs.test-lab.xenproject.org/osstest/logs/131065/ >>> >>> Regressions :-( >>> >>> Tests

Re: [Xen-devel] [PATCH v8 1/7] xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH

2018-12-07 Thread Juergen Gross
On 07/12/2018 14:41, Paolo Bonzini wrote: > On 07/12/18 07:02, Juergen Gross wrote: >> On 06/12/2018 23:11, Paolo Bonzini wrote: >>> On 06/12/18 07:04, Maran Wilson wrote: +config PVH + bool "Support for running PVH guests" + ---help--- +This option enables the PVH entry

[Xen-devel] [distros-debian-jessie test] 75639: tolerable FAIL

2018-12-07 Thread Platform Team regression test user
flight 75639 distros-debian-jessie real [real] http://osstest.xensource.com/osstest/logs/75639/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-amd64-i386-i386-jessie-netboot-pvgrub 19 guest-start/debian.repeat fail blocked in 75627

Re: [Xen-devel] [PATCH 2/2] x86/pv: Code improvements to do_update_descriptor()

2018-12-07 Thread Wei Liu
On Thu, Dec 06, 2018 at 06:03:55PM +, Andrew Cooper wrote: > * Add "uint64_t raw" to seg_desc_t to remove the opencoded uint64_t casting >in this function. > * Rename the 'pa' parameter to 'gaddr', because it lives in GFN space rather >than physical address space. > * Use gfn_t and

Re: [Xen-devel] [PATCH v2 0/2] CPU hotplug fixes for ARM32

2018-12-07 Thread Oleksandr
On 07.12.18 12:02, Julien Grall wrote: Hi, Julien. On 07/12/2018 09:45, Oleksandr Tyshchenko wrote: From: Oleksandr Tyshchenko Hi, all. This is small patch series for ARM32 which needed to be able to bring secondary CPUs up not only during the initial boot, but at runtime also. For

Re: [Xen-devel] [PATCH v7 00/20] xen: add pvh guest support

2018-12-07 Thread Daniel Kiper
On Fri, Dec 07, 2018 at 01:11:28PM +0100, Juergen Gross wrote: > This patch series adds support for booting Linux as PVH guest. > > Similar to i386/xen and x86_64/xen platforms the new i386/xenpvh > platform grub is booted as a standalone image directly by Xen. > > For booting Linux kernel it is

[Xen-devel] [PATCH 3/3] docs/cmdline: Rewrite the cpuid_mask_* section

2018-12-07 Thread Andrew Cooper
A large amount of the information here is obsolete since Xen 4.7 To being with, however, this patch marks a change in style for section headings, due to how HTML anchors are generated. Having more than one parameter per heading makes an awkward anchor, especially when brace globbing is used.

[Xen-devel] [PATCH 0/3] docs/cmdline: Misc improvements to documentation

2018-12-07 Thread Andrew Cooper
Andrew Cooper (3): docs/cmdline: Fix markdown syntax docs/cmdline: Move XSM to be in alphabetical order docs/cmdline: Rewrite the cpuid_mask_* section docs/misc/xen-command-line.markdown | 100 ++-- 1 file changed, 51 insertions(+), 49 deletions(-) --

[Xen-devel] [PATCH 1/3] docs/cmdline: Fix markdown syntax

2018-12-07 Thread Andrew Cooper
* vwfi needs a closing `. rmrr needs one as well, and the opening ' switched to ` * The com1/com2 example lines are already verbatim blocks and shouldn't escape their underscores. This ends up in the rendered output. Signed-off-by: Andrew Cooper --- CC: George Dunlap CC: Ian Jackson

[Xen-devel] [PATCH 2/3] docs/cmdline: Move XSM to be in alphabetical order

2018-12-07 Thread Andrew Cooper
Adjust the default line to note that the default is now selectable in Kconfig. Signed-off-by: Andrew Cooper --- CC: George Dunlap CC: Ian Jackson CC: Jan Beulich CC: Konrad Rzeszutek Wilk CC: Stefano Stabellini CC: Tim Deegan CC: Wei Liu CC: Julien Grall ---

Re: [Xen-devel] [PATCH 7/9] x86/amd: Support context switching legacy SSBD interface

2018-12-07 Thread Jan Beulich
>>> On 06.12.18 at 19:55, wrote: > On 06/12/2018 10:51, Jan Beulich wrote: >> >>> + unsigned int socket = c->phys_proc_id, core = c->cpu_core_id; >>> + struct ssbd_ls_cfg *cfg; >>> + uint64_t val; >>> + >>> + ASSERT(cpu_has_legacy_ssbd); >>> + >>> + /* >>> +* Update hardware lazily,

Re: [Xen-devel] Patch "x86/entry/64: Remove %ebx handling from error_entry/exit" has been added to the 4.9-stable tree

2018-12-07 Thread David Woodhouse
On Thu, 2018-12-06 at 20:27 +, David Woodhouse wrote: > On Thu, 2018-12-06 at 10:49 -0800, Andy Lutomirski wrote: > > > On Dec 6, 2018, at 9:36 AM, Andrew Cooper < > > > andrew.coop...@citrix.com> wrote: > > > Basically - what is happening is that xen_load_tls() is > > > invalidating the > > >

Re: [Xen-devel] [PATCH v8 1/7] xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH

2018-12-07 Thread Paolo Bonzini
On 07/12/18 07:02, Juergen Gross wrote: > On 06/12/2018 23:11, Paolo Bonzini wrote: >> On 06/12/18 07:04, Maran Wilson wrote: >>> +config PVH >>> + bool "Support for running PVH guests" >>> + ---help--- >>> + This option enables the PVH entry point for guest virtual machines >>> + as

[Xen-devel] [PATCH v3] xen/arm: link: Link proc_info_list in .rodata instead of .init.data

2018-12-07 Thread Oleksandr Tyshchenko
From: Oleksandr Tyshchenko To be able to use it for the hot-plugged CPUs as well. The reason why we link proc_info_list in ".rodata" section is that it context should never be modified. This patch also renames ".init.proc.info" section to ".proc.info" as "init" prefix is not actual anymore.

Re: [Xen-devel] [PATCH v8 1/7] xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH

2018-12-07 Thread Juergen Gross
On 07/12/2018 14:52, Paolo Bonzini wrote: > On 07/12/18 14:50, Juergen Gross wrote: >> The PVH boot entry is in the same bzImage binary as the normal one. >> Its just another entry, similar to the Xen PV boot entry. So the binary >> arch/x86/boot/bzimage can be booted either on bare metal via

Re: [Xen-devel] [PATCH v8 0/7] KVM: x86: Allow Qemu/KVM to use PVH entry point

2018-12-07 Thread Borislav Petkov
On Thu, Dec 06, 2018 at 11:14:34PM +0100, Paolo Bonzini wrote: > > There are some minor changes in non-xen x86 code so it would be good to > > get x86 maintainers' ack. > > It's not really code, only Kconfig (and I remarked on it just now), but > it doesn't hurt of course. Yeah, I don't see

Re: [Xen-devel] [PATCH v2 1/2] xen/arm: link: Link proc_info_list in .data instead of .init.data

2018-12-07 Thread Julien Grall
Hi Oleksandr, Please configure your client to quote with > rather than indentation. Below is an example how it can get messy in just 3 answers, I let you imagine with longer thread :). This is a general issue with gmail web-interface that quote using tabulation. It would be best if you use

[Xen-devel] [PATCH 0/2] x86emul: AVX512 fix+improvement

2018-12-07 Thread Jan Beulich
I admit I should probably have got around to run afl on the whole lot earlier. It has spotted the issue addressed in patch 1 as well as a few more in the pending v6 series. Most (including the one here) would have been caught by the exception recovery logic on the stubs, but one (in the gather

Re: [Xen-devel] [PATCH for-4.12 v2 16/17] xen/arm: Implement Set/Way operations

2018-12-07 Thread Julien Grall
Hi Stefano, On 06/12/2018 23:32, Stefano Stabellini wrote: On Tue, 4 Dec 2018, Julien Grall wrote: Set/Way operations are used to perform maintenance on a given cache. At the moment, Set/Way operations are not trapped and therefore a guest OS will directly act on the local cache. However, a

Re: [Xen-devel] [PATCH for-4.12 v2 17/17] xen/arm: Track page accessed between batch of Set/Way operations

2018-12-07 Thread Julien Grall
Hi Jan, On 05/12/2018 08:37, Jan Beulich wrote: On 04.12.18 at 21:26, wrote: At the moment, the implementation of Set/Way operations will go through all the entries of the guest P2M and flush them. However, this is very expensive and may render unusable a guest OS using them. For instance,

Re: [Xen-devel] [PATCH for-4.12 v2 15/17] xen/arm: p2m: Add support for preemption in p2m_cache_flush_range

2018-12-07 Thread Julien Grall
Hi Stefano, On 06/12/2018 23:32, Stefano Stabellini wrote: On Tue, 4 Dec 2018, Julien Grall wrote: p2m_cache_flush_range does not yet support preemption, this may be an issue as cleaning the cache can take a long time. While the current caller (XEN_DOMCTL_cacheflush) does not stricly require

Re: [Xen-devel] [PATCH v8 1/7] xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH

2018-12-07 Thread Paolo Bonzini
On 07/12/18 14:50, Juergen Gross wrote: > The PVH boot entry is in the same bzImage binary as the normal one. > Its just another entry, similar to the Xen PV boot entry. So the binary > arch/x86/boot/bzimage can be booted either on bare metal via grub2 or > other boot-loaders, as Xen PV-guest, as

Re: [Xen-devel] [PATCH v2 1/2] xen/arm: link: Link proc_info_list in .data instead of .init.data

2018-12-07 Thread Oleksandr
On 07.12.18 12:34, Julien Grall wrote: Hi Oleksandr, Hi Julien Please configure your client to quote with > rather than indentation. Below is an example how it can get messy in just 3 answers, I let you imagine with longer thread :). This is a general issue with gmail web-interface

Re: [Xen-devel] [PATCH v2 1/2] xen/arm: link: Link proc_info_list in .data instead of .init.data

2018-12-07 Thread Oleksandr Tyshchenko
On Fri, Dec 7, 2018 at 12:05 PM Julien Grall wrote: > Hi Oleksandr, > Hi Julien > > On 07/12/2018 09:45, Oleksandr Tyshchenko wrote: > > From: Oleksandr Tyshchenko > > > > To be able to use it for the hot-plugged CPUs as well. > > You need to explain in the commit message why you rename

[Xen-devel] [PATCH 2/2] x86emul: slightly alter AVX512 exception checking conditionals

2018-12-07 Thread Jan Beulich
While actually benign (operands are either register or memory ones anyway), I think it is better to use != instead of == for such checks. Signed-off-by: Jan Beulich --- a/xen/arch/x86/x86_emulate/x86_emulate.c +++ b/xen/arch/x86/x86_emulate/x86_emulate.c @@ -5918,11 +5918,11 @@ x86_emulate(

[Xen-devel] [PATCH 1/2] x86emul: fix vector-length check for AVX512F scalar fused-multiply-add insns

2018-12-07 Thread Jan Beulich
The check needs to happen whenever EVEX.b is clear, not just in the memory operand case. Signed-off-by: Jan Beulich --- a/xen/arch/x86/x86_emulate/x86_emulate.c +++ b/xen/arch/x86/x86_emulate/x86_emulate.c @@ -8526,11 +8526,9 @@ x86_emulate( case X86EMUL_OPC_EVEX_66(0x0f38, 0xbd): /*

Re: [Xen-devel] [xen-unstable test] 131065: regressions - FAIL

2018-12-07 Thread Wei Liu
On Fri, Dec 07, 2018 at 09:50:30AM +, Andrew Cooper wrote: > On 07/12/2018 09:21, osstest service owner wrote: > > flight 131065 xen-unstable real [real] > > http://logs.test-lab.xenproject.org/osstest/logs/131065/ > > > > Regressions :-( > > > > Tests which did not succeed and are blocking, >

Re: [Xen-devel] [PATCH v4 3/4] iommu: elide flushing for higher order map/unmap operations

2018-12-07 Thread Jan Beulich
>>> On 06.12.18 at 16:34, wrote: > This patch removes any implicit flushing that occurs in the implementation > of map and unmap operations and adds new iommu_map/unmap() wrapper > functions. To maintain sematics of the iommu_legacy_map/unmap() wrapper > functions, these are modified to call the

Re: [Xen-devel] [PATCH 1/2] x86: Switch "struct desc_struct" to being seg_desc_t

2018-12-07 Thread Jan Beulich
>>> On 06.12.18 at 19:03, wrote: > The struct suffix is redundant in the name, and a future change will want to > turn it into a union, rather than a structure. As this represents a segment > descriptor, give it an appropriate typedef. > > No functional change. > > Signed-off-by: Andrew Cooper

[Xen-devel] [PATCH v7 03/20] xen: carve out grant tab initialization into dedicated function

2018-12-07 Thread Juergen Gross
Initialize the grant tab in a dedicated function. This will enable using it for PVH guests, too. Call the new function from grub_machine_init() as this will later be common between Xen PV and Xen PVH mode. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V2: update commit message

[Xen-devel] [PATCH v7 04/20] xen: prepare common code for Xen PVH support

2018-12-07 Thread Juergen Gross
Some common code needs to be special cased for Xen PVH mode. This hits mostly Xen PV mode specific areas. Split include/grub/i386/pc/int_types.h off from include/grub/i386/pc/int.h to support including this file later from xen_pvh code without the grub_bios_interrupt definition. Move definition

[Xen-devel] [PATCH v7 02/20] loader/linux: support passing rsdp address via boot params

2018-12-07 Thread Juergen Gross
Xen PVH guests will have the RSDP at an arbitrary address. Support that by passing the RSDP address via the boot parameters to Linux. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V2: add oring 0x8000 to version field V3: move including machine/kernel.h to patch 8 (Daniel Kiper)

[Xen-devel] [PATCH v7 01/20] xen: add some xen headers

2018-12-07 Thread Juergen Gross
In order to support grub2 in Xen PVH environment some additional Xen headers are needed as grub2 will be started in PVH mode requiring to use several HVM hypercalls and structures. Add the needed headers from Xen 4.10 being the first Xen version with full (not only experimental) PVH guest

[Xen-devel] [PATCH v7 05/20] xen: add some dummy headers for PVH mode

2018-12-07 Thread Juergen Gross
With Xen PVH mode adding a new machine type the machine related headers need to be present for the build to succeed. Most of the headers just need to include the related common i386 headers. Add those to the tree. Note that xen_pvh/int.h needs to include pc/int_types.h instead of pc/int.h in

Re: [Xen-devel] [PATCH v6.1 09/20] xen: add basic hooks for PVH in current code

2018-12-07 Thread Juergen Gross
On 07/12/2018 12:50, Daniel Kiper wrote: > On Fri, Dec 07, 2018 at 08:35:26AM +0100, Juergen Gross wrote: >> Add the hooks to current code needed for Xen PVH. They will be filled >> with code later when the related functionality is being added. >> >> loader/i386/linux.c needs to include

[Xen-devel] [PATCH v7 11/20] xen: setup hypercall page for PVH

2018-12-07 Thread Juergen Gross
Add the needed code to setup the hypercall page for calling into the Xen hypervisor. Import the XEN_HVM_DEBUGCONS_IOPORT define from Xen unstable into include/xen/arch-x86/xen.h Signed-off-by: Juergen Gross Reviewed-by: Roger Pau Monné --- V3: grub_xen_early_halt->grub_xen_panic (Roger Pau

[Xen-devel] [PATCH v7 00/20] xen: add pvh guest support

2018-12-07 Thread Juergen Gross
This patch series adds support for booting Linux as PVH guest. Similar to i386/xen and x86_64/xen platforms the new i386/xenpvh platform grub is booted as a standalone image directly by Xen. For booting Linux kernel it is using the standard linux kernel loader. The only modification of the linux

[Xen-devel] [PATCH v7 19/20] xen_pvh: support grub-install for xen_pvh

2018-12-07 Thread Juergen Gross
Add xen_pvh support to grub-install. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- include/grub/util/install.h | 1 + util/grub-install-common.c | 1 + util/grub-install.c | 7 +++ 3 files changed, 9 insertions(+) diff --git a/include/grub/util/install.h

[Xen-devel] [PATCH v7 06/20] xen: rearrange xen/init.c to prepare it for Xen PVH mode

2018-12-07 Thread Juergen Gross
Rearrange grub-core/kern/xen/init.c to prepare adding PVH mode support to it. This includes putting some code under #ifdef GRUB_MACHINE_XEN as it will not be used when running as PVH. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- grub-core/kern/xen/init.c | 60

[Xen-devel] [PATCH v7 09/20] xen: add basic hooks for PVH in current code

2018-12-07 Thread Juergen Gross
Add the hooks to current code needed for Xen PVH. They will be filled with code later when the related functionality is being added. loader/i386/linux.c needs to include machine/kernel.h now as it needs to get GRUB_KERNEL_USE_RSDP_ADDR from there. This in turn requires to add an empty kernel.h

[Xen-devel] [PATCH v7 07/20] xen: modify grub_xen_ptr2mfn() for xen-pvh

2018-12-07 Thread Juergen Gross
grub_xen_ptr2mfn() returns the machine frame number for a given pointer value. For Xen-PVH guests this is just the PFN. Add the PVH specific variant. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V5: new patch (Daniel Kiper) --- grub-core/kern/xen/init.c | 2 ++ 1 file changed, 2

[Xen-devel] [PATCH v7 10/20] xen: add PVH boot entry code

2018-12-07 Thread Juergen Gross
Add the code for the Xen PVH mode boot entry. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V3: clear %fs and %gs, too (Daniel Kiper) use GRUB_MEMORY_MACHINE_PROT_STACK_SIZE for stack size (Daniel Kiper) V5: reorder clearing segment regs (Daniel Kiper) ---

[Xen-devel] [PATCH v7 20/20] xen_pvh: add support to configure

2018-12-07 Thread Juergen Gross
Support platform i386/xen_pvh in configure. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- configure.ac | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configure.ac b/configure.ac index 5e63c4af3..81a19afd5 100644 --- a/configure.ac +++ b/configure.ac @@ -151,6 +151,7 @@

[Xen-devel] [PATCH v7 14/20] xen: init memory regions for PVH

2018-12-07 Thread Juergen Gross
Add all usable memory regions to grub memory management and add the needed mmap iterate code, which will be used by grub core (e.g. grub-core/lib/relocator.c or grub-core/mmap/mmap.c). As we are running in 32-bit mode don't add memory above 4GB. Signed-off-by: Juergen Gross Reviewed-by: Daniel

[Xen-devel] [PATCH v7 15/20] xen_pvh: add build runes for grub-core

2018-12-07 Thread Juergen Gross
Add the modifications to the build system needed to build a xen_pvh grub. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V3: sorted some filenames (Daniel Kiper) V4: add bus/pci.c to xen_pvh --- gentpl.py | 4 ++-- grub-core/Makefile.am | 12

[Xen-devel] [PATCH v7 08/20] xen: add PVH specific defines to offset.h

2018-12-07 Thread Juergen Gross
include/grub/offsets.h needs some defines for Xen PVH mode. Add them. While at it line up the values in the surrounding lines to start at the same column. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V3: XENPVH->XEN_PVH (Daniel Kiper) --- include/grub/offsets.h | 21

[Xen-devel] [PATCH v7 13/20] xen: setup Xen specific data for PVH

2018-12-07 Thread Juergen Gross
Initialize the needed Xen specific data. This is: - the Xen start of day page containing the console and Xenstore ring page PFN and event channel - the grant table - the shared info page Write back the possibly modified memory map to the hypervisor in case the guest is reading it from there

[Xen-devel] [PATCH v7 12/20] xen: get memory map from hypervisor for PVH

2018-12-07 Thread Juergen Gross
Retrieve the memory map from the hypervisor and normalize it to contain no overlapping entries and to be sorted by address. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- V3: use grub_e820_mmap_entry instead of own struct (Daniel Kiper) --- grub-core/kern/i386/xen/pvh.c | 94

Re: [Xen-devel] [PATCH 2/2] x86/pv: Code improvements to do_update_descriptor()

2018-12-07 Thread Jan Beulich
>>> On 06.12.18 at 19:03, wrote: > --- a/xen/arch/x86/pv/descriptor-tables.c > +++ b/xen/arch/x86/pv/descriptor-tables.c > @@ -206,30 +206,26 @@ int compat_set_gdt(XEN_GUEST_HANDLE_PARAM(uint) > frame_list, > return ret; > } > > -long do_update_descriptor(uint64_t pa, uint64_t desc) >

Re: [Xen-devel] [PATCH 2/2] x86/pv: Code improvements to do_update_descriptor()

2018-12-07 Thread Andrew Cooper
On 07/12/2018 12:12, Jan Beulich wrote: >> @@ -244,19 +240,20 @@ long do_update_descriptor(uint64_t pa, uint64_t desc) >> break; >> } >> >> -paging_mark_dirty(currd, _mfn(mfn)); >> +paging_mark_dirty(currd, mfn); >> >> /* All is good so make the update. */ >> -

[Xen-devel] [PATCH] x86/hvm: remove duplicate vlapic_find_highest_isr() calls

2018-12-07 Thread Paul Durrant
When viridian APIC assist is active, the code in vlapic_has_pending_irq() may end up re-calling vlapic_find_highest_isr() after emulating an EOI whereas simply moving the call after the EOI emulation removes the need for this duplication. Signed-off-by: Paul Durrant --- Cc: Jan Beulich Cc:

Re: [Xen-devel] [PATCH v2 03/18] xen: introduce 'xen-block', 'xen-disk' and 'xen-cdrom'

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:29PM +, Paul Durrant wrote: > +static char *disk_to_vbd_name(unsigned int disk) > +{ > +char *name, *prefix = (disk >= 26) ? > +disk_to_vbd_name((disk / 26) - 1) : g_strdup(""); > + > +name = g_strdup_printf("%s%c", prefix, 'a' + disk); I don't

Re: [Xen-devel] [Qemu-devel] [PATCH v2 03/18] xen: introduce 'xen-block', 'xen-disk' and 'xen-cdrom'

2018-12-07 Thread Daniel P . Berrangé
On Fri, Dec 07, 2018 at 03:26:01PM +, Anthony PERARD wrote: > On Fri, Dec 07, 2018 at 02:39:40PM +, Paul Durrant wrote: > > > -Original Message- > > > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > > > Sent: 07 December 2018 14:35 > > > To: Paul Durrant > > > Cc:

[Xen-devel] [linux-4.14 test] 131075: regressions - FAIL

2018-12-07 Thread osstest service owner
flight 131075 linux-4.14 real [real] http://logs.test-lab.xenproject.org/osstest/logs/131075/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-amd64-pygrub 7 xen-boot fail REGR. vs. 130155 build-armhf

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

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

[Xen-devel] [qemu-mainline bisection] complete test-amd64-amd64-xl-qemuu-dmrestrict-amd64-dmrestrict

2018-12-07 Thread osstest service owner
branch xen-unstable xenbranch xen-unstable job test-amd64-amd64-xl-qemuu-dmrestrict-amd64-dmrestrict testid debian-hvm-install Tree: linux git://xenbits.xen.org/linux-pvops.git Tree: linuxfirmware git://xenbits.xen.org/osstest/linux-firmware.git Tree: qemu

[Xen-devel] [PATCH] x86/hvm/viridian: stop open coding updates to APIC registers

2018-12-07 Thread Paul Durrant
The code in viridian_synic_wrmsr() duplicates logic in vlapic_reg_write() to update the ICR, ICR2 and TASKPRI registers. Instead of doing this, make vlapic_reg_write() non-static and call it. Signed-off-by: Paul Durrant --- Cc: Jan Beulich Cc: Andrew Cooper Cc: Wei Liu Cc: "Roger Pau Monné"

Re: [Xen-devel] [PATCH 1/1] xen/blkback: rework connect_ring() to avoid inconsistent xenstore 'ring-page-order' set by malicious blkfront

2018-12-07 Thread Dongli Zhang
On 12/07/2018 11:15 PM, Paul Durrant wrote: >> -Original Message- >> From: Dongli Zhang [mailto:dongli.zh...@oracle.com] >> Sent: 07 December 2018 15:10 >> To: Paul Durrant ; linux-ker...@vger.kernel.org; >> xen-devel@lists.xenproject.org; linux-bl...@vger.kernel.org >> Cc:

Re: [Xen-devel] [PATCH v2 13/18] xen: purge 'blk' and 'ioreq' from function names in dataplane/xen-block.c

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:39PM +, Paul Durrant wrote: > This is a purely cosmetic patch that purges remaining use of 'blk' and > 'ioreq' in local function names, and then makes sure all functions are > prefixed with 'xen_block_'. > > No functional change. > > Signed-off-by: Paul Durrant

Re: [Xen-devel] [PATCH v2 09/18] xen: remove unnecessary code from dataplane/xen-block.c

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:35PM +, Paul Durrant wrote: > v2: > - Leave existing boilerplate alone, other than removing the now-incorrect >description > --- > hw/block/dataplane/xen-block.c | 409 > ++--- > 1 file changed, 16 insertions(+), 393

Re: [Xen-devel] [PATCH for-4.12 v2 05/17] xen/arm: p2m: Handle translation fault in get_page_from_gva

2018-12-07 Thread Stefano Stabellini
On Fri, 7 Dec 2018, Julien Grall wrote: > Hi Stefano, > > On 06/12/2018 22:04, Stefano Stabellini wrote: > > On Wed, 5 Dec 2018, Julien Grall wrote: > > > On 04/12/2018 23:59, Stefano Stabellini wrote: > > > > On Tue, 4 Dec 2018, Julien Grall wrote: > > > > > A follow-up patch will re-purpose the

Re: [Xen-devel] [PATCH v8 1/7] xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH

2018-12-07 Thread Paolo Bonzini
On 07/12/18 14:58, Juergen Gross wrote: > On 07/12/2018 14:52, Paolo Bonzini wrote: >> On 07/12/18 14:50, Juergen Gross wrote: >>> The PVH boot entry is in the same bzImage binary as the normal one. >>> Its just another entry, similar to the Xen PV boot entry. So the binary >>>

Re: [Xen-devel] [PATCH v8 0/7] KVM: x86: Allow Qemu/KVM to use PVH entry point

2018-12-07 Thread Boris Ostrovsky
On 12/7/18 5:25 AM, Borislav Petkov wrote: > On Thu, Dec 06, 2018 at 11:14:34PM +0100, Paolo Bonzini wrote: >>> There are some minor changes in non-xen x86 code so it would be good to >>> get x86 maintainers' ack. >> It's not really code, only Kconfig (and I remarked on it just now), but >> it

Re: [Xen-devel] [PATCH v2 03/18] xen: introduce 'xen-block', 'xen-disk' and 'xen-cdrom'

2018-12-07 Thread Paul Durrant
> -Original Message- > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > Sent: 07 December 2018 14:35 > To: Paul Durrant > Cc: qemu-de...@nongnu.org; qemu-bl...@nongnu.org; xen- > de...@lists.xenproject.org; Kevin Wolf ; Max Reitz > ; Stefano Stabellini > Subject: Re: [PATCH v2

Re: [Xen-devel] [PATCH v2 04/18] xen: create xenstore areas for XenDevice-s

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:30PM +, Paul Durrant wrote: > This patch adds a new source module, xen-bus-helper.c, which builds on > basic libxenstore primitives to provide functions to create (setting > permissions appropriately) and destroy xenstore areas, and functions to > 'printf' and

Re: [Xen-devel] [PATCH v2 03/18] xen: introduce 'xen-block', 'xen-disk' and 'xen-cdrom'

2018-12-07 Thread Anthony PERARD
On Fri, Dec 07, 2018 at 02:39:40PM +, Paul Durrant wrote: > > -Original Message- > > From: Anthony PERARD [mailto:anthony.per...@citrix.com] > > Sent: 07 December 2018 14:35 > > To: Paul Durrant > > Cc: qemu-de...@nongnu.org; qemu-bl...@nongnu.org; xen- > > de...@lists.xenproject.org;

Re: [Xen-devel] [PATCH v5] devicetree, xen: add xen, shared-memory binding

2018-12-07 Thread Rob Herring
On Mon, Dec 03, 2018 at 02:26:09PM -0800, Stefano Stabellini wrote: > From: Stefano Stabellini > > Introduce a device tree binding for Xen reserved-memory regions. They > are used to share memory across VMs from the VM config files. (See > static_shm config option.) > > Signed-off-by: Stefano

Re: [Xen-devel] [PATCH v3] xen/arm: link: Link proc_info_list in .rodata instead of .init.data

2018-12-07 Thread Julien Grall
On 07/12/2018 13:41, Oleksandr Tyshchenko wrote: From: Oleksandr Tyshchenko To be able to use it for the hot-plugged CPUs as well. The reason why we link proc_info_list in ".rodata" section is that it context should never be modified. This patch also renames ".init.proc.info" section to

Re: [Xen-devel] [PATCH v3 1/9] mm: Introduce new vm_insert_range API

2018-12-07 Thread Mauro Carvalho Chehab
Em Fri, 7 Dec 2018 00:09:45 +0530 Souptick Joarder escreveu: > Previouly drivers have their own way of mapping range of > kernel pages/memory into user vma and this was done by > invoking vm_insert_page() within a loop. > > As this pattern is common across different drivers, it can > be

Re: [Xen-devel] [PATCH 3/3] docs/cmdline: Rewrite the cpuid_mask_* section

2018-12-07 Thread Julien Grall
Hi Andrew, On 07/12/2018 13:45, Andrew Cooper wrote: A large amount of the information here is obsolete since Xen 4.7 To being with, however, this patch marks a change in style for section headings, due to how HTML anchors are generated. Having more than one parameter per heading makes an

Re: [Xen-devel] [PATCH 1/1] xen/blkback: rework connect_ring() to avoid inconsistent xenstore 'ring-page-order' set by malicious blkfront

2018-12-07 Thread Paul Durrant
> -Original Message- > From: Dongli Zhang [mailto:dongli.zh...@oracle.com] > Sent: 07 December 2018 15:10 > To: Paul Durrant ; linux-ker...@vger.kernel.org; > xen-devel@lists.xenproject.org; linux-bl...@vger.kernel.org > Cc: ax...@kernel.dk; Roger Pau Monne ; > konrad.w...@oracle.com >

Re: [Xen-devel] [PATCH] x86/hvm: remove duplicate vlapic_find_highest_isr() calls

2018-12-07 Thread Andrew Cooper
On 07/12/2018 13:13, Paul Durrant wrote: > When viridian APIC assist is active, the code in vlapic_has_pending_irq() > may end up re-calling vlapic_find_highest_isr() after emulating an EOI > whereas simply moving the call after the EOI emulation removes the need > for this duplication. > >

Re: [Xen-devel] [PATCH v2 14/18] xen: add implementations of xen-block connect and disconnect functions...

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:40PM +, Paul Durrant wrote: > ...and wire in the dataplane. > > This patch adds the remaining code to make the xen-block XenDevice > functional. The parameters that a block frontend expects to find are > populated in the backend xenstore area, and the 'ring-ref'

Re: [Xen-devel] [PATCH] x86/hvm/viridian: stop open coding updates to APIC registers

2018-12-07 Thread Andrew Cooper
On 07/12/2018 17:50, Paul Durrant wrote: > The code in viridian_synic_wrmsr() duplicates logic in vlapic_reg_write() > to update the ICR, ICR2 and TASKPRI registers. Instead of doing this, > make vlapic_reg_write() non-static and call it. > > Signed-off-by: Paul Durrant > --- > Cc: Jan Beulich >

Re: [Xen-devel] Ongoing/future speculative mitigation work

2018-12-07 Thread Wei Liu
On Thu, Oct 18, 2018 at 06:46:22PM +0100, Andrew Cooper wrote: > Hello, > > This is an accumulation and summary of various tasks which have been > discussed since the revelation of the speculative security issues in > January, and also an invitation to discuss alternative ideas.  They are > x86

Re: [Xen-devel] [PATCH v8 1/7] xen/pvh: Split CONFIG_XEN_PVH into CONFIG_PVH and CONFIG_XEN_PVH

2018-12-07 Thread Maran Wilson
On 12/7/2018 7:14 AM, Paolo Bonzini wrote: On 07/12/18 14:58, Juergen Gross wrote: On 07/12/2018 14:52, Paolo Bonzini wrote: On 07/12/18 14:50, Juergen Gross wrote: The PVH boot entry is in the same bzImage binary as the normal one. Its just another entry, similar to the Xen PV boot entry. So

Re: [Xen-devel] [PATCH] libxl: Documentation about the domain configuration on disk

2018-12-07 Thread Ian Jackson
Wei Liu writes ("Re: [PATCH] libxl: Documentation about the domain configuration on disk"): > On Thu, Dec 06, 2018 at 02:57:33PM +, Anthony PERARD wrote: > > Anyway, that comment block isn't very helpful because it basically says > > that we can't depriv QEMU, I mean do hotplug with a

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

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

Re: [Xen-devel] [PATCH v3 1/9] mm: Introduce new vm_insert_range API

2018-12-07 Thread Souptick Joarder
On Fri, Dec 7, 2018 at 10:41 PM Matthew Wilcox wrote: > > On Fri, Dec 07, 2018 at 03:34:56PM +, Robin Murphy wrote: > > > +int vm_insert_range(struct vm_area_struct *vma, unsigned long addr, > > > + struct page **pages, unsigned long page_count) > > > +{ > > > + unsigned

Re: [Xen-devel] [PATCH v9 7/7] xen/arm: export shared memory regions as reserved-memory on device tree

2018-12-07 Thread Stefano Stabellini
On Wed, 5 Dec 2018, Stefano Stabellini wrote: > Shared memory regions need to be advertised to the guest. Fortunately, a > device tree binding for special memory regions already exist: > reserved-memory. > > Add a reserved-memory node for each shared memory region, for both > owners and

Re: [Xen-devel] [PATCH v3 1/9] mm: Introduce new vm_insert_range API

2018-12-07 Thread Robin Murphy
On 2018-12-07 7:28 pm, Souptick Joarder wrote: On Fri, Dec 7, 2018 at 10:41 PM Matthew Wilcox wrote: On Fri, Dec 07, 2018 at 03:34:56PM +, Robin Murphy wrote: +int vm_insert_range(struct vm_area_struct *vma, unsigned long addr, + struct page **pages, unsigned long

Re: [Xen-devel] [PATCH v2 15/18] xen: add a mechanism to automatically create XenDevice-s...

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:41PM +, Paul Durrant wrote: > ...that maintains compatibility with existing Xen toolstacks. > > Xen toolstacks instantiate PV backends by simply writing information into > xenstore and expecting a backend implementation to be watching for this. > > This patch

Re: [Xen-devel] [PATCH v2 16/18] xen: automatically create XenBlockDevice-s

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:42PM +, Paul Durrant wrote: > This patch adds a creator function for XenBlockDevice-s so that they can > be created automatically when the Xen toolstack instantiates a new > PV backend. When the XenBlockDevice is created this way it is also > necessary to create a

[Xen-devel] [PATCH] x86/VT-x: Don't activate VMCS Shadowing outside of nested vmx mode

2018-12-07 Thread Andrew Cooper
By default on capable hardware, SECONDARY_EXEC_ENABLE_VMCS_SHADOWING is activated unilaterally. The VMCS Link pointer is initialised to ~0, but the VMREAD/VMWRITE bitmap pointers are not. This causes the 16bit IVT and Bios Data Area get interpreted as the read/write permission bitmap for guests

Re: [Xen-devel] [PATCH v2 18/18] xen: remove the legacy 'xen_disk' backend

2018-12-07 Thread Anthony PERARD
On Thu, Dec 06, 2018 at 03:08:44PM +, Paul Durrant wrote: > This backend has now been replaced by the 'xen-qdisk' XenDevice. > > Signed-off-by: Paul Durrant Acked-by: Anthony PERARD -- Anthony PERARD ___ Xen-devel mailing list

Re: [Xen-devel] Patch "x86/entry/64: Remove %ebx handling from error_entry/exit" has been added to the 4.9-stable tree

2018-12-07 Thread David Woodhouse
On Fri, 2018-12-07 at 12:18 +, David Woodhouse wrote: > > > #else > > + struct multicall_space mc = __xen_mc_entry(0); > > + MULTI_set_segment_base(mc.mc, SEGBASE_GS_USER_SEL, 0); > > + > > loadsegment(fs, 0); > > #endif > > That seems to boot and run,

[Xen-devel] [linux-4.19 test] 131074: regressions - FAIL

2018-12-07 Thread osstest service owner
flight 131074 linux-4.19 real [real] http://logs.test-lab.xenproject.org/osstest/logs/131074/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-amd64-xl-qemuu-debianhvm-amd64-xsm 7 xen-boot fail REGR. vs. 129313

Re: [Xen-devel] [PATCH v8 0/7] KVM: x86: Allow Qemu/KVM to use PVH entry point

2018-12-07 Thread Borislav Petkov
On Fri, Dec 07, 2018 at 11:07:54AM -0500, Boris Ostrovsky wrote: > Can this be considered as an ACK from you? I'll look at v9 next week and add tags, assuming v9 is going to be the final one, of course. -- Regards/Gruss, Boris. SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham

Re: [Xen-devel] [PATCH v9 1/7] xen: xsm: flask: introduce XENMAPSPACE_gmfn_share for memory sharing

2018-12-07 Thread Daniel De Graaf
On 12/5/18 5:15 PM, Stefano Stabellini wrote: From: Zhongze Liu The existing XENMAPSPACE_gmfn_foreign subop of XENMEM_add_to_physmap forbids a Dom0 to map memory pages from one DomU to another, which restricts some useful yet not dangerous use cases -- such as sharing pages among DomU's so

Re: [Xen-devel] [PATCH for-4.12 v2 17/17] xen/arm: Track page accessed between batch of Set/Way operations

2018-12-07 Thread Stefano Stabellini
On Tue, 4 Dec 2018, Julien Grall wrote: > At the moment, the implementation of Set/Way operations will go through > all the entries of the guest P2M and flush them. However, this is very > expensive and may render unusable a guest OS using them. > > For instance, Linux 32-bit will use Set/Way

[Xen-devel] [linux-4.9 test] 131077: regressions - FAIL

2018-12-07 Thread osstest service owner
flight 131077 linux-4.9 real [real] http://logs.test-lab.xenproject.org/osstest/logs/131077/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-armhf-armhf-xl-cubietruck 16 guest-start/debian.repeat fail REGR. vs. 130840

[Xen-devel] [PATCH] x86/xen: Clear user %gs before updating segment descriptors

2018-12-07 Thread David Woodhouse
During a context switch, if clearing a descriptor which is currently referenced by the old process's user %gs, if Xen preempts the vCPU before %gs is set for the new process, a fault may occur. This fault actually seems to be fairly harmless; xen_failsafe_callback will just return to the

[Xen-devel] [seabios test] 131081: tolerable FAIL - PUSHED

2018-12-07 Thread osstest service owner
flight 131081 seabios real [real] http://logs.test-lab.xenproject.org/osstest/logs/131081/ Failures :-/ but no regressions. Tests which did not succeed, but are not blocking: test-amd64-i386-xl-qemuu-win7-amd64 17 guest-stop fail like 130373 test-amd64-amd64-xl-qemuu-ws16-amd64 17

[Xen-devel] [PATCH] x86/xen: Clear user %gs before updating segment descriptors

2018-12-07 Thread David Woodhouse
During a context switch, if clearing a descriptor which is currently referenced by the old process's user %gs, if Xen preempts the vCPU before %gs is set for the new process, a fault may occur. This fault actually seems to be fairly harmless; xen_failsafe_callback will just return to the

[Xen-devel] [ovmf test] 131090: regressions - FAIL

2018-12-07 Thread osstest service owner
flight 131090 ovmf real [real] http://logs.test-lab.xenproject.org/osstest/logs/131090/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: build-i386-xsm6 xen-buildfail REGR. vs. 129475 build-i386

  1   2   >