Re: [Xen-devel] [PATCH v2] x86-64/Xen: eliminate W+X mappings

2017-12-18 Thread Ingo Molnar
* Jan Beulich wrote: > A few thousand such pages are usually left around due to the re-use of > L1 tables having been provided by the hypervisor (Dom0) or tool stack > (DomU). Set NX in the direct map variant, which needs to be done in L2 > due to the dual use of the re-used

Re: [Xen-devel] [PATCH v2 3/3] x86/xen: supply rsdp address in boot params for pvh guests

2017-12-07 Thread Ingo Molnar
* Juergen Gross wrote: > When booted via the special PVH entry save the RSDP address set in the > boot information block in struct boot_params. This will enable Xen to > locate the RSDP at an arbitrary address. > > Set the boot loader version to 2.14 (0x020e) replacing the

Re: [Xen-devel] [PATCH v2 2/3] x86/acpi: take rsdp address for boot params if available

2017-12-07 Thread Ingo Molnar
* Juergen Gross wrote: > In case the rsdp address in struct boot_params is specified don't try > to find the table by searching, but take the address directly as set > by the boot loader. > > Signed-off-by: Juergen Gross > --- > drivers/acpi/osl.c | 8

Re: [Xen-devel] [PATCH v2 1/3] x86/boot: add acpi rsdp address to setup_header

2017-12-07 Thread Ingo Molnar
* Juergen Gross wrote: > Xen PVH guests receive the address of the RSDP table from Xen. In order > to support booting a Xen PVH guest via grub2 using the standard x86 > boot entry we need a way fro grub2 to pass the RSDP address to the > kernel. > > For this purpose expand the

Re: [Xen-devel] [PATCH v2 2/3] x86/acpi: take rsdp address for boot params if available

2017-12-08 Thread Ingo Molnar
* Juergen Gross <jgr...@suse.com> wrote: > On 08/12/17 08:05, Ingo Molnar wrote: > > > > * Juergen Gross <jgr...@suse.com> wrote: > > ... > > > acpi_physical_address acpi_arch_get_root_pointer(void) > > { > > return boot_par

Re: [Xen-devel] [PATCH v2 1/3] x86/boot: add acpi rsdp address to setup_header

2017-12-08 Thread Ingo Molnar
* Juergen Gross wrote: > >> +Offset/size: 0x268/8 > >> +Protocol: 2.14+ > >> + > >> + This field can be set by the boot loader to tell the kernel the > >> + physical address of the ACPI RSDP table. > >> + > >> + A value of 0 indicates the kernel should fall back to the

Re: [Xen-devel] [PATCH v2 1/3] x86/boot: add acpi rsdp address to setup_header

2017-12-08 Thread Ingo Molnar
* Jan Beulich wrote: > >>> On 08.12.17 at 08:16, wrote: > > Also, a more fundamental question: why doesn't Xen use EFI to hand over > > hardware configuration details? > > Iirc the main purpose of the change here is to allow booting PVH > (guest or Dom0)

Re: [Xen-devel] [PATCH v3 4/4] x86/xen: supply rsdp address in boot params for pvh guests

2017-12-11 Thread Ingo Molnar
* Juergen Gross wrote: > On 11/12/17 11:09, Jan Beulich wrote: > On 08.12.17 at 16:11, wrote: > >> Set the boot loader version to 2.14 (0x020e) replacing the wrong 0x0212 > >> which should have been 0x020c. > > > > This part of the description has become

Re: [Xen-devel] [PATCH 2/2] x86-64/Xen: eliminate W+X mappings

2017-12-12 Thread Ingo Molnar
* Jan Beulich wrote: > >>> On 12.12.17 at 11:38, wrote: > > * Jan Beulich wrote: > >> --- 4.15-rc3/arch/x86/xen/mmu_pv.c > >> +++ 4.15-rc3-x86_64-Xen-avoid-W+X/arch/x86/xen/mmu_pv.c > >> @@ -1902,6 +1902,16 @@ void __init

Re: [Xen-devel] [PATCH 1/2] x86: consider effective protection attributes in W+X check

2017-12-12 Thread Ingo Molnar
* Jan Beulich wrote: > Using just the leaf page table entry flags would cause a false warning > in case _PAGE_RW is clear or _PAGE_NX is set in a higher level entry. Good find - I assume this bug can cause both false positives and false negatives as well, right? Thanks,

Re: [Xen-devel] [PATCH 2/2] x86-64/Xen: eliminate W+X mappings

2017-12-12 Thread Ingo Molnar
* Jan Beulich wrote: > A few thousand such pages are usually left around due to the re-use of > L1 tables having been provided by the hypervisor (Dom0) or tool stack > (DomU). Set NX in the direct map variant, which needs to be done in L2 > due to the dual use of the re-used

Re: [Xen-devel] [PATCH -resend 01/27] linkage: new macros for assembler symbols

2018-05-14 Thread Ingo Molnar
* Jiri Slaby wrote: > Documentation/asm-annotations.rst | 218 > arch/x86/include/asm/linkage.h| 10 +- > include/linux/linkage.h | 257 > -- > 3 files changed, 475 insertions(+), 10

Re: [Xen-devel] [PATCH v2] x86: xen: remove the use of VLAIS

2018-01-08 Thread Ingo Molnar
* Juergen Gross wrote: > On 08/01/18 17:10, Peter Zijlstra wrote: > > On Sat, Jan 06, 2018 at 01:39:48PM -0800, Nick Desaulniers wrote: > >> Variable Length Arrays In Structs (VLAIS) is not supported by Clang, and > >> frowned upon by others. > >> > >>

Re: [Xen-devel] [PATCH] x86/xen: Calculate __max_logical_packages on PV domains

2018-02-13 Thread Ingo Molnar
s. > >> > >> Calculate __max_logical_packages for PV domains. > >> > >> Fixes: b4c0a7326f5d ("x86/smpboot: Fix __max_logical_packages estimate") > >> Signed-off-by: Prarit Bhargava <pra...@redhat.com> > >> Tested-and-reported-by:

Re: [Xen-devel] [v2 1/1] xen, mm: Allow deferred page initialization for xen pv domains

2018-02-26 Thread Ingo Molnar
it_32.c | 1 + > arch/x86/mm/init_64.c | 1 + > arch/x86/xen/mmu_pv.c | 38 ++---- > mm/page_alloc.c | 4 > 6 files changed, 31 insertions(+), 16 deletions(-) Acked-by: Ingo Molnar <mi...@kernel.org> Thanks, Ingo __

Re: [Xen-devel] [PATCH v2] xen/pv: Call get_cpu_address_sizes to set x86_virt/phys_bits

2018-08-07 Thread Ingo Molnar
* Boris Ostrovsky wrote: > x86 maintainers, this needs your ack please. LGTM: Acked-by: Ingo Molnar Thanks, Ingo ___ Xen-devel mailing list Xen-devel@lists.xenproject.org https://lists.xenproject.org/mailman/listinfo/xen-devel

Re: [Xen-devel] [PATCH] x86/xen: zero MSR_IA32_SPEC_CTRL before suspend

2018-04-11 Thread Ingo Molnar
* Jan Beulich wrote: > Additionally, x86 maintainers: is there a particular reason this (or > any functionally equivalent patch) isn't upstream yet? As indicated > before, I had not been able to find any discussion, and hence I > see no reason why this is a patch we

Re: [Xen-devel] [PATCH] x86/xen: zero MSR_IA32_SPEC_CTRL before suspend

2018-04-12 Thread Ingo Molnar
* Jan Beulich wrote: > >>> On 11.04.18 at 13:53, wrote: > > * Jan Beulich wrote: > > > >> Additionally, x86 maintainers: is there a particular reason this (or > >> any functionally equivalent patch) isn't upstream yet? As indicated > >>

Re: [Xen-devel] [PATCH] x86/xen: zero MSR_IA32_SPEC_CTRL before suspend

2018-04-12 Thread Ingo Molnar
* Jan Beulich wrote: > >>> On 12.04.18 at 09:32, wrote: > > > * Jan Beulich wrote: > > > >> >>> On 11.04.18 at 13:53, wrote: > >> > * Jan Beulich wrote: > >> > > >> >> Additionally, x86

Re: [Xen-devel] [PATCH] x86/xen: Remove use of VLAs

2018-04-16 Thread Ingo Molnar
gt; desc_ptr *dtr) > { > unsigned long va = dtr->address; > unsigned int size = dtr->size + 1; > - unsigned pages = DIV_ROUND_UP(size, PAGE_SIZE); > - unsigned long frames[pages]; > + unsigned long frames[DIV_ROUND_UP(SZ_64K, PAGE_SIZE)]; >

Re: [Xen-devel] [PATCH v5 0/3] x86: make rsdp address accessible via boot params

2018-10-10 Thread Ingo Molnar
* Juergen Gross wrote: > In the non-EFI boot path the ACPI RSDP table is currently found via > either EBDA or by searching through low memory for the RSDP magic. > This requires the RSDP to be located in the first 1MB of physical > memory. Xen PVH guests, however, get the RSDP address via the

Re: [Xen-devel] [PATCH v5 0/3] x86: make rsdp address accessible via boot params

2018-10-10 Thread Ingo Molnar
* Juergen Gross wrote: > You can just dive into the discussion we had back in February: That was half a year and a thousand commits ago! ;-) > https://lore.kernel.org/lkml/20180213163244.j2zuxyhs4kbfh...@gmail.com/ > > The scheme I have used in V5 of the series is the one you agreed to use >