Re: [Xen-devel] [PATCH v3 01/11] x86/boot: enumerate documentation for the x86 hardware_subarch

2016-02-25 Thread Ingo Molnar
* Andy Lutomirski wrote: > On Feb 24, 2016 12:33 AM, "Ingo Molnar" wrote: > > > > For hard coded platform quirks I'd suggest we add x86_platform.quirks > > flags. For > > example the F00F hack for Xen could be done via: > > > > x86_platform.quirks.idt_remap = 0; > > > > Don't we uncon

Re: [Xen-devel] [PATCH v3 17/23] xsplice: Print dependency and payloads build_id in the keyhandler.

2016-02-25 Thread Jan Beulich
>>> On 24.02.16 at 22:54, wrote: > On Wed, Feb 17, 2016 at 04:10:12AM -0700, Jan Beulich wrote: >> >>> On 16.02.16 at 21:20, wrote: >> > On 12/02/16 18:05, Konrad Rzeszutek Wilk wrote: >> >> +static void xsplice_print_build_id(char *id, unsigned int len) >> >> +{ >> >> +unsigned int i; >> >>

Re: [Xen-devel] [PATCH 3/3] vVMX: use latched VMCS machine address

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 07:50, wrote: >> thanks for the analysis! >> >> > (XEN)nvmx_handle_vmclear >> > (XEN)nvmx_handle_vmptrld >> > (XEN)map_io_bitmap_all >> > (XEN)_map_io_bitmap >> > (XEN)virtual_vmcs_enter >> > (XEN)_map_io_bitmap >> > (XEN)virtual_vmcs_enter >> > (XEN)_map_msr_bitmap >> > (XEN)

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

2016-02-25 Thread osstest service owner
flight 83845 qemu-mainline real [real] http://logs.test-lab.xenproject.org/osstest/logs/83845/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-armhf-armhf-xl-rtds15 guest-start/debian.repeat fail blocked in 83703 test-amd64-i386-xl-qemuu-win

Re: [Xen-devel] [PATCH v5 5/7] VT-d: Refactor iommu_ops .map_page() and unmap_page()

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 07:56, wrote: >> On February 17, 2016 10:23pm, wrote: >> >>> On 05.02.16 at 11:18, wrote: >> > to pass down a flag indicating whether the lock is being held, and >> > check the way up the call trees. >> >> Same comments as on the previous patch; most of the changes outside of

Re: [Xen-devel] Pygrub on ARM64

2016-02-25 Thread Ian Campbell
On Thu, 2016-02-25 at 13:20 +0530, Sanjeev Pandita wrote: >  > Terminal 3: (manually running the pygrub command) > [root@dhcp-194 xen]# export LD_LIBRARY_PATH=/usr/lib > [root@dhcp-194 xen]# mkdir -p /var/run/xen/bootloader.2.d > [root@dhcp-194 xen]# touch /var/run/xen/bootloader.2.out > [root@dhcp

Re: [Xen-devel] [PATCH 3/3] vVMX: use latched VMCS machine address

2016-02-25 Thread Li, Liang Z
> >> > (XEN)nvmx_handle_vmclear > >> > (XEN)nvmx_handle_vmptrld > >> > (XEN)map_io_bitmap_all > >> > (XEN)_map_io_bitmap > >> > (XEN)virtual_vmcs_enter > >> > (XEN)_map_io_bitmap > >> > (XEN)virtual_vmcs_enter > >> > (XEN)_map_msr_bitmap > >> > (XEN)virtual_vmcs_enter > >> > (XEN)nvmx_set_vmcs_poin

Re: [Xen-devel] New Defects reported by Coverity Scan for XenProject

2016-02-25 Thread Ian Campbell
On Wed, 2016-02-24 at 21:02 -0800, scan-ad...@coverity.com wrote: > Hi, > > Please find the latest report on new defect(s) introduced to XenProject found > with Coverity Scan. > > 2 new defect(s) introduced to XenProject found with Coverity Scan. > 12 defect(s), reported by Coverity Scan earlie

Re: [Xen-devel] New Defects reported by Coverity Scan for XenProject

2016-02-25 Thread George Dunlap
On 25/02/16 10:00, Ian Campbell wrote: > > On Wed, 2016-02-24 at 21:02 -0800, scan-ad...@coverity.com wrote: >> Hi, >> >> Please find the latest report on new defect(s) introduced to XenProject >> found with Coverity Scan. >> >> 2 new defect(s) introduced to XenProject found with Coverity Scan. >

Re: [Xen-devel] [COVERITY ACCESS] Request for access to Coverity

2016-02-25 Thread Ian Campbell
On Fri, 2016-02-12 at 14:53 +, Stefano Stabellini wrote: > I agree to the conditions in the XenProject Coverity contribution > guidelines [0]. > > I'm a developer working for Citrix Systems UK, Ltd.  I've been active > in the Xen community since 2008; I currently maintain Xen on ARM, Xen > sup

Re: [Xen-devel] [PATCH] tools: libxl: Simplify logic in libxl__realloc

2016-02-25 Thread Ian Campbell
On Fri, 2016-02-19 at 15:34 +, Ian Jackson wrote: > Replace the loop exit and separate test for loop overrun with an > assert in the loop body. > > This simplifies the code.  It also (hopefully) avoids Coverity > thinking that gc->alloc_maxsize might change, resulting in the loop > failing to

Re: [Xen-devel] [PATCH v4 13/21] arm/gic-v2: Add ACPI boot support for GICv2

2016-02-25 Thread Shannon Zhao
On 2016/1/28 20:56, Stefano Stabellini wrote: > On Sat, 23 Jan 2016, Shannon Zhao wrote: >> From: Parth Dixit >> >> ACPI on Xen hypervisor uses MADT table for proper GIC initialization. >> First get the GIC version from GIC Distributor. Then parse GIC related >> subtables, collect CPU interface

Re: [Xen-devel] Patching error while setting up COLO

2016-02-25 Thread Changlong Xie
On 02/25/2016 01:17 PM, Yu-An(Victor) Chen wrote: Hi, I am trying to set up COLO by following this http://wiki.xenproject.org/wiki/COLO_-_Coarse_Grain_Lock_Stepping I was able to follow the step up to $git am ~/ColoPatchForQemu/*.patch When I try to run the above command, I got the following

Re: [Xen-devel] Patching error while setting up COLO

2016-02-25 Thread Ian Campbell
On Thu, 2016-02-25 at 16:49 +0800, Changlong Xie wrote: > Sorry for this. Since we have no privilege to update the Wiki for a long > time so most contents of this page are dated : ( Anyone can be granted access, it is only a manual process because of spammers. Please create an account and then fi

Re: [Xen-devel] [PATCH v5][RFC]xen: sched: convert RTDS from time to event driven model

2016-02-25 Thread Dario Faggioli
On Thu, 2016-02-25 at 01:15 -0500, Tianyang Chen wrote: > > On 2/24/2016 9:02 PM, Dario Faggioli wrote: > > Hey, > > > > Here I am, sorry for the delay. :-( > No problem, I think we are almost there. > We probably are, although a few more adjustments in the timer logic is required, IMO. I'll try

Re: [Xen-devel] Pygrub on ARM64

2016-02-25 Thread Stefano Stabellini
On Thu, 25 Feb 2016, Ian Campbell wrote: > On Thu, 2016-02-25 at 13:20 +0530, Sanjeev Pandita wrote: > >  > > Terminal 3: (manually running the pygrub command) > > [root@dhcp-194 xen]# export LD_LIBRARY_PATH=/usr/lib > > [root@dhcp-194 xen]# mkdir -p /var/run/xen/bootloader.2.d > > [root@dhcp-194 x

Re: [Xen-devel] [PATCH v4 13/21] arm/gic-v2: Add ACPI boot support for GICv2

2016-02-25 Thread Stefano Stabellini
On Thu, 25 Feb 2016, Shannon Zhao wrote: > On 2016/1/28 20:56, Stefano Stabellini wrote: > > On Sat, 23 Jan 2016, Shannon Zhao wrote: > >> From: Parth Dixit > >> > >> ACPI on Xen hypervisor uses MADT table for proper GIC initialization. > >> First get the GIC version from GIC Distributor. Then par

Re: [Xen-devel] Pygrub on ARM64

2016-02-25 Thread Ian Campbell
On Thu, 2016-02-25 at 10:35 +, Stefano Stabellini wrote: > On Thu, 25 Feb 2016, Ian Campbell wrote: > > On Thu, 2016-02-25 at 13:20 +0530, Sanjeev Pandita wrote: > > >   > > > Terminal 3: (manually running the pygrub command) > > > [root@dhcp-194 xen]# export LD_LIBRARY_PATH=/usr/lib > > > [roo

Re: [Xen-devel] Pygrub on ARM64

2016-02-25 Thread Ian Campbell
On Thu, 2016-02-25 at 10:47 +, Ian Campbell wrote: > > > > > CentOS's first partition is fat to boot on efi systems, but it only > > contains the grub efi binary. All the other partitions are xfs. Does > > pygrub support it? > > I don't know, but pygrub is normally pretty vocal in these situ

Re: [Xen-devel] [PATCH 0/9] xl: convert exit codes related to domain subcommands to EXIT_[SUCCESS|FAILURE]

2016-02-25 Thread Dario Faggioli
On Wed, 2016-02-24 at 18:23 +0530, Harmandeep Kaur wrote: > *main_foo() is treated somewhat as a regular main(), it is changed to > return EXIT_SUCCESS or EXIT_FAILURE. > > *Functions that are not main_foo(), are changed to do 'return 0' or > 'return 1', and then 0/1 is taken care in the main_foo(

[Xen-devel] [PATCHv3 1/3] x86/fpu: improve check for XSAVE* not writing FIP/FDP fields

2016-02-25 Thread David Vrabel
The hardware may not write the FIP/FDP fields with a XSAVE* instruction. e.g., with XSAVEOPT/XSAVES if the state hasn't changed or on AMD CPUs when a floating point exception is not pending. We need to identify this case so we can correctly apply the check for whether to save/restore FCS/FDS. By

[Xen-devel] [PATCHv3 3/3] x86/hvm: add HVM_PARAM_X87_FIP_WIDTH

2016-02-25 Thread David Vrabel
The HVM parameter HVM_PARAM_X87_FIP_WIDTH to allow tools and the guest to adjust the width of the FIP/FDP registers to be saved/restored by the hypervisor. This is in case the hypervisor hueristics do not do the right thing. Add this parameter to the set saved during domain save/migrate. Signed-

[Xen-devel] [PATCHv3 0/3] x86: workaround inability to fully restore FPU state

2016-02-25 Thread David Vrabel
This series extends the workaround for the inability for some x86 CPUs to fully restore the FPU exception state (64-bit FIP/FDP and FCS/FDS). Toolstack (or the guest) may override the default behaviour to always do a 32-bit save/restore. Running Microsoft's Driver Verifier continues to work in a

[Xen-devel] [PATCHv3 2/3] x86/fpu: Add a per-domain field to set the width of FIP/FDP

2016-02-25 Thread David Vrabel
The x86 architecture allows either: a) the 64-bit FIP/FDP registers to be restored (clearing FCS and FDS); or b) the 32-bit FIP/FDP and FCS/FDS registers to be restored (clearing the upper 32-bits). Add a per-domain field to indicate which of these options a guest needs. The options are: 8, 4 or

Re: [Xen-devel] [PATCH] xen/lockprof: Move .lockprofile.data into .rodata

2016-02-25 Thread Stefano Stabellini
On Wed, 24 Feb 2016, Andrew Cooper wrote: > The entire contents of .lockprofile.data are unchanging pointers to > lock_profile structure in .data. Annotate the type as such, and link the > section in .rodata. As these are just pointers, 32byte alignment is > unnecessary. > > Signed-off-by: Andre

Re: [Xen-devel] [PATCH 1/9] xl: Improve return and exit codes of memory related functions.

2016-02-25 Thread Dario Faggioli
On Wed, 2016-02-24 at 18:23 +0530, Harmandeep Kaur wrote: > Signed-off-by: Harmandeep Kaur > --- >  tools/libxl/xl_cmdimpl.c | 12 ++-- >  1 file changed, 6 insertions(+), 6 deletions(-) > > diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c > index 116363d..8f5a2f4 100644 >

Re: [Xen-devel] [PATCH] xen/lockprof: Move .lockprofile.data into .rodata

2016-02-25 Thread Stefano Stabellini
On Thu, 25 Feb 2016, Stefano Stabellini wrote: > On Wed, 24 Feb 2016, Andrew Cooper wrote: > > The entire contents of .lockprofile.data are unchanging pointers to > > lock_profile structure in .data. Annotate the type as such, and link the > > section in .rodata. As these are just pointers, 32byt

Re: [Xen-devel] Pygrub on ARM64

2016-02-25 Thread Ian Campbell
On Thu, 2016-02-25 at 10:53 +, Ian Campbell wrote: > On Thu, 2016-02-25 at 10:47 +, Ian Campbell wrote: > > > > > > > > CentOS's first partition is fat to boot on efi systems, but it only > > > contains the grub efi binary. All the other partitions are xfs. Does > > > pygrub support it? >

Re: [Xen-devel] [PATCH 9/9] xl: Improve return codes of main_domid(), main_domname() and main_sysrq() and related functions.

2016-02-25 Thread Dario Faggioli
On Wed, 2016-02-24 at 18:23 +0530, Harmandeep Kaur wrote: > Signed-off-by: Harmandeep Kaur > So, this basically is "domain id and name related functions", or "domain utility functions". I'd rename the patch with something like that. Also, I think find_domain() is fits nicely in here. > --- >  t

Re: [Xen-devel] Pygrub on ARM64

2016-02-25 Thread Ian Campbell
On Thu, 2016-02-25 at 11:12 +, Ian Campbell wrote: > On Thu, 2016-02-25 at 10:53 +, Ian Campbell wrote: > > On Thu, 2016-02-25 at 10:47 +, Ian Campbell wrote: > > > > > > > > > > > CentOS's first partition is fat to boot on efi systems, but it only > > > > contains the grub efi binary

Re: [Xen-devel] [PATCHv3 2/3] x86/fpu: Add a per-domain field to set the width of FIP/FDP

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 11:58, wrote: > @@ -261,7 +261,15 @@ void xsave(struct vcpu *v, uint64_t mask) > "=m" (*ptr), \ > "a" (lmask), "d" (hmask), "D" (ptr)) > > -if ( word_size <= 0 || !is_pv_32bit_vcpu(v) ) > +if ( fip_width == 8 ) > +

Re: [Xen-devel] [PATCH 8/9] xl: Improve return and exit codes main_button_press(), main_trigger(), main_remus() and related functions.

2016-02-25 Thread Dario Faggioli
On Wed, 2016-02-24 at 18:23 +0530, Harmandeep Kaur wrote: > Signed-off-by: Harmandeep Kaur > About the subject lines: try to make them more abstract. It does not scale to list all the changed functions! :-) So, in this case, something like (just out of the top of my head!) "debugging, special key

Re: [Xen-devel] [PATCHv3 1/3] x86/fpu: improve check for XSAVE* not writing FIP/FDP fields

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 11:58, wrote: > The hardware may not write the FIP/FDP fields with a XSAVE* > instruction. e.g., with XSAVEOPT/XSAVES if the state hasn't changed > or on AMD CPUs when a floating point exception is not pending. We > need to identify this case so we can correctly apply the chec

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

2016-02-25 Thread osstest service owner
flight 83846 linux-next real [real] http://logs.test-lab.xenproject.org/osstest/logs/83846/ Regressions :-( Tests which did not succeed and are blocking, including tests which could not be run: test-amd64-i386-libvirt-xsm 9 debian-installfail REGR. vs. 83655 test-amd64-amd64-xl

Re: [Xen-devel] [PATCH 4/9] xl: Improve return and exit codes of main_console(), main_vncviewer() and main_dump_core().

2016-02-25 Thread Dario Faggioli
On Wed, 2016-02-24 at 18:23 +0530, Harmandeep Kaur wrote: > Signed-off-by: Harmandeep Kaur > "console, vnc and core dump related function" I'm not sure I'd put main_dump_core() in this patch, rather than in patch 8, but I think it's just fine wither way. > diff --git a/tools/libxl/xl_cmdimpl.c b

[Xen-devel] [PATCH v5 01/11] xen: make xen loader callable multiple times

2016-02-25 Thread Juergen Gross
The loader for xen paravirtualized environment isn't callable multiple times as it won't free any memory in case of failure. Call grub_relocator_unload() as other modules do it before allocating a new relocator or when unloading the module. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper

[Xen-devel] [PATCH v5 09/11] xen: add capability to load initrd outside of initial mapping

2016-02-25 Thread Juergen Gross
Modern pvops linux kernels support an initrd not covered by the initial mapping. This capability is flagged by an elf-note. In case the elf-note is set by the kernel don't place the initrd into the initial mapping. This will allow to load larger initrds and/or support domains with larger memory, a

[Xen-devel] [PATCH v5 06/11] xen: factor out p2m list allocation into separate function

2016-02-25 Thread Juergen Gross
Do the p2m list allocation of the to be loaded kernel in a separate function. This will allow doing the p2m list allocation at different times of the boot preparations depending on the features the kernel is supporting. While at this remove superfluous setting of first_p2m_pfn and nr_p2m_frames as

[Xen-devel] [PATCH v5 05/11] xen: synchronize xen header

2016-02-25 Thread Juergen Gross
Get actual version of include/xen/xen.h from the Xen repository in order to be able to use constants defined there. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- include/xen/arch-x86/xen-x86_32.h | 22 +++ include/xen/arch-x86/xen-x86_64.h | 8 +-- include/xen/xen.h

[Xen-devel] [PATCH v5 11/11] xen: add capability to load p2m list outside of kernel mapping

2016-02-25 Thread Juergen Gross
Modern pvops linux kernels support a p2m list not covered by the kernel mapping. This capability is flagged by an elf-note specifying the virtual address the kernel is expecting the p2m list to be mapped to. In case the elf-note is set by the kernel don't place the p2m list into the kernel mapping

[Xen-devel] [PATCH v5 00/11] grub-xen: support booting huge pv-domains

2016-02-25 Thread Juergen Gross
The Xen hypervisor supports starting a dom0 with large memory (up to the TB range) by not including the initrd and p2m list in the initial kernel mapping. Especially the p2m list can grow larger than the available virtual space in the initial mapping. The started kernel is indicating the support o

[Xen-devel] [PATCH v5 10/11] xen: modify page table construction

2016-02-25 Thread Juergen Gross
Modify the page table construction to allow multiple virtual regions to be mapped. This is done as preparation for removing the p2m list from the initial kernel mapping in order to support huge pv domains. This allows a cleaner approach for mapping the relocator page by using this capability. The

[Xen-devel] [PATCH v5 03/11] xen: reduce number of global variables in xen loader

2016-02-25 Thread Juergen Gross
The loader for xen paravirtualized environment is using lots of global variables. Reduce the number by making them either local or by putting them into a single state structure. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- grub-core/loader/i386/xen.c | 259 +++-

[Xen-devel] [PATCH v5 07/11] xen: factor out allocation of special pages into separate function

2016-02-25 Thread Juergen Gross
Do the allocation of special pages (start info, console and xenbus ring buffers) in a separate function. This will allow to do the allocation at different times of the boot preparations depending on the features the kernel is supporting. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper ---

[Xen-devel] [PATCH v5 08/11] xen: factor out allocation of page tables into separate function

2016-02-25 Thread Juergen Gross
Do the allocation of page tables in a separate function. This will allow to do the allocation at different times of the boot preparations depending on the features the kernel is supporting. Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper --- grub-core/loader/i386/xen.c | 91 +

[Xen-devel] [PATCH v5 04/11] xen: add elfnote.h to avoid using numbers instead of constants

2016-02-25 Thread Juergen Gross
Various features and parameters of a pv-kernel are specified via elf notes in the kernel image. Those notes are part of the interface between the Xen hypervisor and the kernel. Instead of using num,bers in the code when interpreting the elf notes make use of the header supplied by Xen for that pur

[Xen-devel] [PATCH v5 02/11] xen: avoid memleaks on error

2016-02-25 Thread Juergen Gross
When loading a Xen pv-kernel avoid memory leaks in case of errors. Signed-off-by: Juergen Gross --- V5: set grub_errno to GRUB_ERR_NONE to avoid false error reports as requested by Daniel Kiper --- grub-core/loader/i386/xen.c| 2 +- grub-core/loader/i386/xen_fileXX.c | 19 ++

Re: [Xen-devel] [PATCHv3 2/3] x86/fpu: Add a per-domain field to set the width of FIP/FDP

2016-02-25 Thread David Vrabel
On 25/02/16 11:24, Jan Beulich wrote: On 25.02.16 at 11:58, wrote: >> @@ -261,7 +261,15 @@ void xsave(struct vcpu *v, uint64_t mask) >> "=m" (*ptr), \ >> "a" (lmask), "d" (hmask), "D" (ptr)) >> >> -if ( word_size <= 0 || !is_pv_32bit_v

Re: [Xen-devel] [PATCH 1/2] hvc_xen: add earlycon support

2016-02-25 Thread Stefano Stabellini
On Wed, 24 Feb 2016, Konrad Rzeszutek Wilk wrote: > > I could do the same here by dropping the if (!xen_pv_domain()) check > > above, but then if somebody specifies earlyprintk=xenboot on a non-Xen > > environment, I expect Linux would crash. > > Nah, you made it "Work" with: > commit eb5ef07151ba

Re: [Xen-devel] [PATCHv3 2/3] x86/fpu: Add a per-domain field to set the width of FIP/FDP

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 12:38, wrote: > On 25/02/16 11:24, Jan Beulich wrote: > On 25.02.16 at 11:58, wrote: >>> @@ -261,7 +261,15 @@ void xsave(struct vcpu *v, uint64_t mask) >>> "=m" (*ptr), \ >>> "a" (lmask), "d" (hmask), "D" (ptr)) >>> >>>

[Xen-devel] [PATCH v2] vVMX: use latched VMCS machine address

2016-02-25 Thread Jan Beulich
Instead of calling domain_page_map_to_mfn() over and over, latch the guest VMCS machine address unconditionally (i.e. independent of whether VMCS shadowing is supported by the hardware). Since this requires altering the parameters of __[gs]et_vmcs{,_real}() (and hence all their callers) anyway, ta

Re: [Xen-devel] [PATCH 1/2] hvc_xen: add earlycon support

2016-02-25 Thread Stefano Stabellini
On Wed, 24 Feb 2016, Andrew Cooper wrote: > On 24/02/16 17:18, Konrad Rzeszutek Wilk wrote: > >> I could do the same here by dropping the if (!xen_pv_domain()) check > >> above, but then if somebody specifies earlyprintk=xenboot on a non-Xen > >> environment, I expect Linux would crash. > > Nah, yo

[Xen-devel] [PATCH v2 0/3] hvc_xen: fix xenboot on x86 and export to ARM

2016-02-25 Thread Stefano Stabellini
Hi all, this series exports xenboot on ARM and ARM64 as earlycon, and gets xenboot fully working again for PV DomUs on x86 (currently the xenboot output only goes to the hypervisor via hypercall and not to the DomU console). Cheers, Stefano Stefano Stabellini (3): hvc_xen: add earlycon s

[Xen-devel] [PATCH v2 3/3] hvc_xen: make early_printk work with HVM guests

2016-02-25 Thread Stefano Stabellini
Refactor the existing code in xen_raw_console_write to get the generic early_printk console work with HVM guests. Take the opportunity to replace the outb loop with a single outsb call to reduce the number of vmexit. Signed-off-by: Stefano Stabellini --- drivers/tty/hvc/hvc_xen.c | 27 +++

[Xen-devel] [PATCH v2 1/3] hvc_xen: add earlycon support

2016-02-25 Thread Stefano Stabellini
Introduce EARLYCON support in hvc_xen, useful for early debugging on arm and arm64, where xen early_printk is not available. It is different from xenboot_write_console on x86 in two ways: - it does not return if !xen_pv_domain(), not only because ARM guests are xen_hvm_domain(), but also becaus

[Xen-devel] [PATCH v2 2/3] hvc_xen: fix xenboot for DomUs

2016-02-25 Thread Stefano Stabellini
The xenboot early console has been partially broken for DomU for a long time: the output would only go to the hypervisor via hypercall (HYPERVISOR_console_io), while it wouldn't actually go to the DomU console. The reason is that domU_write_console would return early as no xencons structs are confi

[Xen-devel] [PATCH] libxl: fix comment LIBXL__EGC_INIT -> LIBXL_EGC_INIT

2016-02-25 Thread Wei Liu
Signed-off-by: Wei Liu Cc: Ian Jackson --- tools/libxl/libxl_internal.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/libxl/libxl_internal.h b/tools/libxl/libxl_internal.h index 650a958..cda0741 100644 --- a/tools/libxl/libxl_internal.h +++ b/tools/libxl/libxl_interna

Re: [Xen-devel] [PATCH v5 5/7] VT-d: Refactor iommu_ops .map_page() and unmap_page()

2016-02-25 Thread Xu, Quan
+CC Dario who is also watching this patch set. On February 25, 2016 4:59pm, wrote: > >>> On 25.02.16 at 07:56, wrote: > >> On February 17, 2016 10:23pm, wrote: > >> >>> On 05.02.16 at 11:18, wrote: > >> > to pass down a flag indicating whether the lock is being held, and > >> > check the way u

Re: [Xen-devel] [PATCH v5 02/11] xen: avoid memleaks on error

2016-02-25 Thread Daniel Kiper
On Thu, Feb 25, 2016 at 12:33:28PM +0100, Juergen Gross wrote: > When loading a Xen pv-kernel avoid memory leaks in case of errors. > > Signed-off-by: Juergen Gross Reviewed-by: Daniel Kiper Daniel ___ Xen-devel mailing list Xen-devel@lists.xen.org h

Re: [Xen-devel] [PATCHv3 1/3] x86/fpu: improve check for XSAVE* not writing FIP/FDP fields

2016-02-25 Thread David Vrabel
On 25/02/16 11:32, Jan Beulich wrote: On 25.02.16 at 11:58, wrote: >> The hardware may not write the FIP/FDP fields with a XSAVE* >> instruction. e.g., with XSAVEOPT/XSAVES if the state hasn't changed >> or on AMD CPUs when a floating point exception is not pending. We >> need to identify t

Re: [Xen-devel] What time is it kvm-clock?

2016-02-25 Thread Joao Martins
On 02/24/2016 07:55 PM, Owen Hofmann wrote: not-really-well-defined hybrid? --Andy >>> >>> 1. What is not well defined? I fail to spot anything >>> specific in Owen's e-mail. >> >> If I start a guest and query kvm-clock, I get a nanosecond count. >> AFAIK it is, in fact, ill-defined

[Xen-devel] [PATCH] Fix MAINTAINERS: remove any use of {a,b}

2016-02-25 Thread Anthony PERARD
This is the complain from perl: Unescaped left brace in regex is deprecated, passed through in regex; marked by <-- HERE in m/^docs/misc/kconfig{ <-- HERE ,-language}\.txt/ at scripts/get_maintainer.pl line 731. Also, it does not work. Signed-off-by: Anthony PERARD --- MAINTAINERS | 9 ++-

Re: [Xen-devel] [PATCH v5 5/7] VT-d: Refactor iommu_ops .map_page() and unmap_page()

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 13:14, wrote: > On February 25, 2016 4:59pm, wrote: >> I'd >> really suggest investigating alternatives. One that comes to mind would be to >> move acquiring/releasing pcidevs_lock into a helper function, and setting a >> per-CPU flag indicating ownership. > > To me, this mig

Re: [Xen-devel] [PATCHv3 1/3] x86/fpu: improve check for XSAVE* not writing FIP/FDP fields

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 13:18, wrote: > On 25/02/16 11:32, Jan Beulich wrote: > On 25.02.16 at 11:58, wrote: >>> The hardware may not write the FIP/FDP fields with a XSAVE* >>> instruction. e.g., with XSAVEOPT/XSAVES if the state hasn't changed >>> or on AMD CPUs when a floating point exception i

Re: [Xen-devel] Xen Project Infrastructure Maintenance: Feb 25th and 1st of March

2016-02-25 Thread Lars Kurth
Just a quick note to let you know that the following services have been updated this morning - all foo @ lists at xenproject dot org mailing lists - forwarding of mails to foo @ xenproject for org accounts - downloads.xenproject.org Regards Lars ___ X

Re: [Xen-devel] [PATCH] Fix MAINTAINERS: remove any use of {a,b}

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 13:21, wrote: > This is the complain from perl: > Unescaped left brace in regex is deprecated, passed through in regex; marked > by <-- HERE in m/^docs/misc/kconfig{ <-- HERE ,-language}\.txt/ at > scripts/get_maintainer.pl line 731. > > Also, it does not work. But who said

Re: [Xen-devel] [PATCH] Fix MAINTAINERS: remove any use of {a,b}

2016-02-25 Thread Ian Campbell
On Thu, 2016-02-25 at 05:31 -0700, Jan Beulich wrote: > > > > On 25.02.16 at 13:21, wrote: > > This is the complain from perl: > > Unescaped left brace in regex is deprecated, passed through in regex; > > marked > > by <-- HERE in m/^docs/misc/kconfig{ <-- HERE ,-language}\.txt/ at > > scripts/g

[Xen-devel] (no subject)

2016-02-25 Thread Ayushi Arora
Hello, As asked of in the previous mail, I tried compiling Xen from source. I am not sure whether we can ask questions for the task given, but I have been stuck at it from yesterday. I followed all the steps, and wherever there was some problem, I looked up that in wiki of Xen, but after building a

Re: [Xen-devel] [PATCH v5 09/11] xen: add capability to load initrd outside of initial mapping

2016-02-25 Thread Daniel Kiper
On Thu, Feb 25, 2016 at 12:33:35PM +0100, Juergen Gross wrote: > Modern pvops linux kernels support an initrd not covered by the initial > mapping. This capability is flagged by an elf-note. > > In case the elf-note is set by the kernel don't place the initrd into > the initial mapping. This will a

Re: [Xen-devel] [PATCHv3 1/3] x86/fpu: improve check for XSAVE* not writing FIP/FDP fields

2016-02-25 Thread David Vrabel
On 25/02/16 12:27, Jan Beulich wrote: On 25.02.16 at 13:18, wrote: >> On 25/02/16 11:32, Jan Beulich wrote: >> On 25.02.16 at 11:58, wrote: The poison value is fixed and thus knowable by a guest (or guest userspace). This could allow the guest to cause Xen to incorrectly

Re: [Xen-devel] [PATCH] Fix MAINTAINERS: remove any use of {a,b}

2016-02-25 Thread David Vrabel
On 25/02/16 12:21, Anthony PERARD wrote: > This is the complain from perl: > Unescaped left brace in regex is deprecated, passed through in regex; marked > by <-- HERE in m/^docs/misc/kconfig{ <-- HERE ,-language}\.txt/ at > scripts/get_maintainer.pl line 731. F: is supposed to be globs, not reg

Re: [Xen-devel] [PATCH] Fix MAINTAINERS: remove any use of {a,b}

2016-02-25 Thread Anthony PERARD
On Thu, Feb 25, 2016 at 12:34:43PM +, Ian Campbell wrote: > On Thu, 2016-02-25 at 05:31 -0700, Jan Beulich wrote: > > > > > On 25.02.16 at 13:21, wrote: > > > This is the complain from perl: > > > Unescaped left brace in regex is deprecated, passed through in regex; > > > marked > > > by <--

Re: [Xen-devel] [PATCH v5 5/7] VT-d: Refactor iommu_ops .map_page() and unmap_page()

2016-02-25 Thread Dario Faggioli
On Thu, 2016-02-25 at 05:23 -0700, Jan Beulich wrote: > > > > On 25.02.16 at 13:14, wrote: > >  > > To me, this might be fine. > > Does Per-CPU flag refer to this_cpu(iommu_dont_flush_iotlb) or > > variant? > > Yes. But I'd prefer ... > > > > However, the same effect could be achieved > > > by m

Re: [Xen-devel] [PATCHv3 1/3] x86/fpu: improve check for XSAVE* not writing FIP/FDP fields

2016-02-25 Thread Andrew Cooper
On 25/02/16 12:49, David Vrabel wrote: > On 25/02/16 12:27, Jan Beulich wrote: > On 25.02.16 at 13:18, wrote: >>> On 25/02/16 11:32, Jan Beulich wrote: >>> On 25.02.16 at 11:58, wrote: > The poison value is fixed and thus knowable by a guest (or guest > userspace). This could all

Re: [Xen-devel] [PATCH v4 13/21] arm/gic-v2: Add ACPI boot support for GICv2

2016-02-25 Thread Shannon Zhao
On 2016/2/25 18:42, Stefano Stabellini wrote: > On Thu, 25 Feb 2016, Shannon Zhao wrote: >> On 2016/1/28 20:56, Stefano Stabellini wrote: >>> On Sat, 23 Jan 2016, Shannon Zhao wrote: From: Parth Dixit ACPI on Xen hypervisor uses MADT table for proper GIC initialization. First

Re: [Xen-devel] [PATCH] Fix MAINTAINERS: remove any use of {a,b}

2016-02-25 Thread Doug Goldstein
On 2/25/16 6:21 AM, Anthony PERARD wrote: > This is the complain from perl: > Unescaped left brace in regex is deprecated, passed through in regex; marked > by <-- HERE in m/^docs/misc/kconfig{ <-- HERE ,-language}\.txt/ at > scripts/get_maintainer.pl line 731. > > Also, it does not work. > > S

Re: [Xen-devel] [PATCHv3 1/3] x86/fpu: improve check for XSAVE* not writing FIP/FDP fields

2016-02-25 Thread Jan Beulich
>>> On 25.02.16 at 14:16, wrote: > No OS is plausibly going to hide non-IP information in FIP. > > If some theoretical OS does do something like that, there is always the > override available. But who says it needs to be an OS to do so? User mode code could as much (and would imo even be more li

[Xen-devel] [xen-unstable test] 83855: tolerable FAIL - PUSHED

2016-02-25 Thread osstest service owner
flight 83855 xen-unstable real [real] http://logs.test-lab.xenproject.org/osstest/logs/83855/ Failures :-/ but no regressions. Regressions which are regarded as allowable (not blocking): test-amd64-amd64-xl-qemuu-win7-amd64 16 guest-stopfail REGR. vs. 83609 test-armhf-armhf-xl-rtds

Re: [Xen-devel] [PATCH v5 10/11] xen: modify page table construction

2016-02-25 Thread Daniel Kiper
On Thu, Feb 25, 2016 at 12:33:36PM +0100, Juergen Gross wrote: > Modify the page table construction to allow multiple virtual regions > to be mapped. This is done as preparation for removing the p2m list > from the initial kernel mapping in order to support huge pv domains. > > This allows a cleane

[Xen-devel] [PATCH 8/8] tools/xenalyze: Actually handle case where number of ipi vectors exceeds static max

2016-02-25 Thread George Dunlap
find_vec() is supposed to find the vector in the list if it exists, choose an empty slot if it doesn't exist, and return null if all slots are full. However, coverity noticed that although the callers of find_vec() handle the last condition, find_vec() itself didn't. Check to see if we actually f

[Xen-devel] [PATCH 1/8] tools/xenalyze: Close symbol_file after reading it

2016-02-25 Thread George Dunlap
...to avoid leaking the FD and associated memory. CID 1306872 Signed-off-by: George Dunlap --- Not sure if this will actually make coverity happy, or if we need to actually set symbol_file to NULL. CC: Ian Jackson CC: Wei Liu --- tools/xentrace/xenalyze.c | 2 ++ 1 file changed, 2 insertions

[Xen-devel] [PATCH 7/8] tools/xenalyze: Fix multiple instances of *HYPERCALL_MAX

2016-02-25 Thread George Dunlap
We HYPERCALL_MAX defined as the maximum enumerated hypercall, and we have PV_HYPERCALL_MAX defined as some other number (presumably based on experience with actual hypercalls). Both are used to size arrays (hypercall_name[] and pv_data.hypercall_count[], respectively). Rename PV_HYPERCALL_MAX to

[Xen-devel] [PATCH 5/8] tools/xenalyze: Fix check for error return value

2016-02-25 Thread George Dunlap
fdopen returns NULL on failure, not a negative integer. CID 1306863 CID 1306858 Signed-off-by: George Dunlap --- Strangely, coverity counted this as two bugs: one for comparing a pointer with a negative integer, one for the comparison never possibly being true (thus making the if condition dead

[Xen-devel] [PATCH 3/8] tools/xenalyze: Handle fstat errors properly

2016-02-25 Thread George Dunlap
They're pretty unlikely to fail, but doesn't hurt to check. CID 1311502 CID 1311501 Signed-off-by: George Dunlap --- CC: Ian Jackson CC: Wei Liu --- tools/xentrace/mread.c| 9 - tools/xentrace/xenalyze.c | 5 - 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/to

[Xen-devel] [PATCH 6/8] tools/xenalyze: Fix off-by-one in MAX_CPUS range checks

2016-02-25 Thread George Dunlap
Skip action / throw error if cpu/vcpu >= MAX_CPUS rather than >. Also add an assertion to vcpu_find, to make future errors of this kind not out-of-bounds. CID 1306871 CID 1306870 CID 1306869 CID 1306867 Signed-off-by: George Dunlap --- CC: Ian Jackson CC: Wei Liu --- tools/xentrace/xenalyze

[Xen-devel] [PATCH 2/8] tools/xenalyze: Avoid redundant check

2016-02-25 Thread George Dunlap
Coverity notices that if !head is true, that !N can never be true. Don't bother checking N, since we know it has to be at least one. CID 1354243 Signed-off-by: George Dunlap --- CC: Ian Jackson CC: Wei Liu --- tools/xentrace/xenalyze.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/to

[Xen-devel] [PATCH 0/8] Fixes to Coverity issues reported on xenalyze

2016-02-25 Thread George Dunlap
This series fixes a number of issues to coverity with xenalyze. George Dunlap (8): tools/xenalyze: Close symbol_file after reading it tools/xenalyze: Avoid redundant check tools/xenalyze: Handle fstat errors properly tools/xenalyze: Mark unreachable code as unreachable tools/xenalyze: Fi

[Xen-devel] [PATCH 4/8] tools/xenalyze: Mark unreachable code as unreachable

2016-02-25 Thread George Dunlap
...so that coverity knows it's unreachable. Signed-off-by: George Dunlap --- CC: Ian Jackson CC: Wei Liu --- tools/xentrace/xenalyze.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/xentrace/xenalyze.c b/tools/xentrace/xenalyze.c index 9f8c065..123030a 100644 --- a/tools/xentrace/xe

[Xen-devel] Ping: [PATCH 2/5] x86emul: limit-check branch targets

2016-02-25 Thread Jan Beulich
>>> On 17.02.16 at 17:35, wrote: > All branches need to #GP when their target violates the segment limit > (in 16- and 32-bit modes) or is non-canonical (in 64-bit mode). For > near branches facilitate this via a zero-byte instruction fetch from > the target address (resulting in address translati

[Xen-devel] [PATCH v3 01/16] libxc: Rework extra module initialisation

2016-02-25 Thread Anthony PERARD
This patch use xc_dom_alloc_segment() to allocate the memory space for the ACPI modules and the SMBIOS modules. This is to replace the arbitrary placement of 1MB after the hvmloader image. In later patches, while trying to load a firmware such as OVMF, the later could easily be loaded past the add

[Xen-devel] [PATCH v3 00/16] Load BIOS via toolstack instead of been embedded in hvmloader.

2016-02-25 Thread Anthony PERARD
Hi all, Many changes in V3: no more cmdline, but use each modules' cmdline to provide a name for it. in libxc: - use xc_dom_alloc_segment() to load modules. see patch #1. - avoid duplication of code between PVHv2 and hvmloader for the initialisation of hvm_start_info. in xl/lib

[Xen-devel] [PATCH v3 04/16] firmware/makefile: install BIOS and ACPI blob ...

2016-02-25 Thread Anthony PERARD
... into the firmware directory, along with hvmloader. This introduce a rules for dsdt_anycpu_qemu_xen.aml, and change the rule for dsdt_anycpu_qemu_xen.c to temporarly generate both .c and .aml. The generation of dsdt_anycpu_qemu_xen.c will go away in a future patch. Signed-off-by: Anthony PERAR

[Xen-devel] [PATCH v3 07/16] hvmloader: Grab the hvm_start_info pointer

2016-02-25 Thread Anthony PERARD
Signed-off-by: Anthony PERARD --- Change in V3: - remove cmdline parser - load hvm_start_info pointer earlier, before calling main(). - Add struct hvm_start_info definition to hvmloader. --- tools/firmware/hvmloader/hvm_start_info.h | 32 +++ tools/firmware/hvmloader/

[Xen-devel] [PATCH v3 09/16] hvmloader: Check modules whereabouts

2016-02-25 Thread Anthony PERARD
As perform_tests() is going to clear memory past 4MB, we check that the memory can be use. Signed-off-by: Anthony PERARD --- New in V3 --- tools/firmware/hvmloader/hvmloader.c | 9 + 1 file changed, 9 insertions(+) diff --git a/tools/firmware/hvmloader/hvmloader.c b/tools/firmware/hvml

[Xen-devel] [PATCH v3 03/16] configure: #define SEABIOS_PATH and OVMF_PATH

2016-02-25 Thread Anthony PERARD
Those paths are to be used by libxl, in order to load the firmware in memory. If a system path is not define, then this default to the Xen firmware directory. Signed-off-by: Anthony PERARD --- Please, run ./autogen.sh on this patch. --- tools/configure.ac | 6 ++ 1 file changed, 6 insertion

[Xen-devel] [PATCH v3 02/16] libxc: Load BIOS and ACPI table into guest memory

2016-02-25 Thread Anthony PERARD
This adds two new firmware module, bios_module and full_acpi_module. They are loaded in the guest memory and final location is provided to hvmloader via the hvm_start_info struct. This patch create the hvm_start_info struct for HVM guest that have a device model, so this is now common code with HV

[Xen-devel] [PATCH v3 06/16] libxl: Load guest ACPI table from file

2016-02-25 Thread Anthony PERARD
A user can provide a different ACPI tables than the default one by using the existing "acpi_firmware" xl's config option or the field u.hvm.acpi_firmware. libxl will check if the provided table is a DSDT or not. Signed-off-by: Anthony PERARD --- Change in V3: - use existing acpi_firmware option

[Xen-devel] [PATCH v3 08/16] hvmloader: Locate the BIOS blob

2016-02-25 Thread Anthony PERARD
The BIOS can be found an entry called "bios" of the modlist of the hvm_start_info struct. The found BIOS blob is not loaded by this patch, but only passed as argument to bios_load() function. It is going to be used by the next few patches. Signed-off-by: Anthony PERARD --- Changes in V3: - fix

Re: [Xen-devel] [PATCH v4 13/21] arm/gic-v2: Add ACPI boot support for GICv2

2016-02-25 Thread Stefano Stabellini
On Thu, 25 Feb 2016, Shannon Zhao wrote: > On 2016/2/25 18:42, Stefano Stabellini wrote: > > On Thu, 25 Feb 2016, Shannon Zhao wrote: > >> On 2016/1/28 20:56, Stefano Stabellini wrote: > >>> On Sat, 23 Jan 2016, Shannon Zhao wrote: > From: Parth Dixit > > ACPI on Xen hypervisor uses

[Xen-devel] [PATCH v3 05/16] libxl: Load guest BIOS from file

2016-02-25 Thread Anthony PERARD
The path to the BIOS blob can be override by the xl's bios_override option, or provided by u.hvm.bios_firmware in the domain_build_info struct by other libxl user. Signed-off-by: Anthony PERARD --- Change in V3: - move seabios_path and ovmf_path to libxl_path.c (with renaming) - fix some coding

  1   2   3   >