Re: [PATCH] target-i386: clear guest TSC on reset

2013-12-09 Thread Fernando Luis Vázquez Cao
On 12/06/2013 11:22 PM, Marcelo Tosatti wrote: On Fri, Dec 06, 2013 at 05:24:18PM +0900, Fernando Luis Vázquez Cao wrote: I also wanted to make sure that the initialization that we do in kvm_arch_vcpu_postcreate on power up and the subsequent TSC writeback work well together, but I didn't have

Re: [PULL 4/5] vfio-pci: Add debug config options to disable MSI/X KVM support

2013-12-09 Thread Paolo Bonzini
Il 06/12/2013 23:36, Alex Williamson ha scritto: #define VFIO_ALLOW_MMAP 1 #define VFIO_ALLOW_KVM_INTX 1 +#define VFIO_ALLOW_KVM_MSI 1 +#define VFIO_ALLOW_KVM_MSIX 1 Why not make these device properties instead? Honestly, I don't think they're that useful to the average or even

Re: [PATCH] KVM: VMX: shadow VM_(ENTRY|EXIT)_CONTROLS vmcs field

2013-12-09 Thread Jan Kiszka
On 2013-12-09 07:55, Gleb Natapov wrote: On Sun, Dec 08, 2013 at 02:00:11PM +0100, Jan Kiszka wrote: On 2013-11-27 17:58, Paolo Bonzini wrote: Il 25/11/2013 14:37, Gleb Natapov ha scritto: VM_(ENTRY|EXIT)_CONTROLS vmcs fields are read/written on each guest entry but most times it can be

Re: [RFC PATCH v3 1/2] add support for Hyper-V reference time counter

2013-12-09 Thread Paolo Bonzini
Il 08/12/2013 12:33, Vadim Rozenfeld ha scritto: Signed-off: Peter Lieven p...@dlh.net Signed-off: Gleb Natapov g...@redhat.com Signed-off: Vadim Rozenfeld vroze...@redhat.com v1 - v2 1. mark TSC page dirty as suggested by Eric Northup digitale...@google.com and Gleb 2. disable local

Re: [RFC PATCH v3 2/2] add support for Hyper-V partition reference time enlightenment

2013-12-09 Thread Paolo Bonzini
Il 08/12/2013 12:33, Vadim Rozenfeld ha scritto: + tsc_ref.tsc_sequence = + boot_cpu_has(X86_FEATURE_CONSTANT_TSC) ? 1 : 0; + tsc_ref.tsc_scale = + ((1LL 32) / vcpu-arch.virtual_tsc_khz) 32; + tsc_ref.tsc_offset

Problem after update windows VirtIO drivers

2013-12-09 Thread Carlos Rodrigues
Hello, After update the VirtIO drivers for Windows Server 2008 R2 64-bit, when i reboot virtual machine, the windows OS get stuck on loading bar. The VirtIO drivers is the latest stable that i made the download from http://alt.fedoraproject.org/pub/alt/virtio-win/stable/virtio-win-0.1-74.iso

[PATCH] KVM: PPC: Add devname:kvm aliases for modules

2013-12-09 Thread Alexander Graf
Systems that support automatic loading of kernel modules through device aliases should try and automatically load kvm when /dev/kvm gets opened. Add code to support that magic for all PPC kvm targets, even the ones that don't support modules yet. Signed-off-by: Alexander Graf ag...@suse.de ---

Re: [PATCH v3 1/9] ARM: KVM: Allow creating the VGIC after VCPUs

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: Rework the VGIC initialization slightly to allow initialization of the vgic cpu-specific state even if the irqchip (the VGIC) hasn't been created by user space yet. This is safe, because the vgic data structures are already allocated when the CPU is

Re: [PATCH] KVM: PPC: fix couple of memory leaks in MPIC/XICS devices

2013-12-09 Thread Alexander Graf
On 04.09.2013, at 14:16, Paul Mackerras pau...@samba.org wrote: On Sun, Sep 01, 2013 at 03:53:46PM +0300, Gleb Natapov wrote: XICS failed to free xics structure on error path. MPIC destroy handler forgot to delete kvm_device structure. Signed-off-by: Gleb Natapov g...@redhat.com

Re: [PATCH v3 2/9] KVM: arm-vgic: Support KVM_CREATE_DEVICE for VGIC

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: Support creating the ARM VGIC device through the KVM_CREATE_DEVICE ioctl, which can then later be leveraged to use the KVM_{GET/SET}_DEVICE_ATTR, which is useful both for setting addresses in a more generic API than the ARM-specific one and is

Re: [PATCH 0/2 v3] kvm/powerpc: hypercall related cleanup

2013-12-09 Thread Alexander Graf
On 08.10.2013, at 06:02, Bharat Bhushan r65...@freescale.com wrote: From: Bharat Bhushan bharat.bhus...@freescale.com This patchset does some code cleanup around kvm-hypercall. Thanks, applied to kvm-ppc-queue. Alex -- To unsubscribe from this list: send the line unsubscribe kvm in the

Re: [PATCH v3 3/9] KVM: arm-vgic: Set base addr through device API

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: Support setting the distributor and cpu interface base addresses in the VM physical address space through the KVM_{SET,GET}_DEVICE_ATTR API in addition to the ARM specific API. This has the added benefit of being able to share more code in user

Re: [PATCH v3 4/9] irqchip: arm-gic: Define additional MMIO offsets and masks

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: Define CPU interface offsets for the GICC_ABPR, GICC_APR, and GICC_IIDR registers. Define distributor registers for the GICD_SPENDSGIR and the GICD_CPENDSGIR. KVM/ARM needs to know about these definitions to fully support save/restore of the

Re: [PATCH v3 5/9] KVM: arm-vgic: Make vgic mmio functions more generic

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: Rename the vgic_ranges array to vgic_dist_ranges to be more specific and to prepare for handling CPU interface register access as well (for save/restore of VGIC state). Pass offset from distributor or interface MMIO base to find_matching_range

Re: [PATCH 0/4] KVM: PPC: Unify FP/VMX/VSX state handling between KVM and main kernel

2013-12-09 Thread Alexander Graf
On 15.10.2013, at 11:43, Paul Mackerras pau...@samba.org wrote: This series makes use of the new thread_fp_state and thread_vr_state structures to unify the way that floating-point and vector state is handled. With both KVM and the main kernel using the same structures to store this state

Re: [PATCH v3 6/9] KVM: arm-vgic: Add vgic reg access from dev attr

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: Add infrastructure to handle distributor and cpu interface register accesses through the KVM_{GET/SET}_DEVICE_ATTR interface by adding the KVM_DEV_ARM_VGIC_GRP_DIST_REGS and KVM_DEV_ARM_VGIC_GRP_CPU_REGS groups and defining the semantics of the

Re: [PATCH v3 7/9] KVM: arm-vgic: Support unqueueing of LRs to the dist

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: To properly access the VGIC state from user space it is very unpractical to have to loop through all the LRs in all register access functions. Instead, support moving all pending state from LRs to the distributor, but leave active state LRs alone.

Re: Problem after update windows VirtIO drivers

2013-12-09 Thread Alon Levy
On 12/09/2013 04:45 PM, Carlos Rodrigues wrote: Hello, After update the VirtIO drivers for Windows Server 2008 R2 64-bit, when i reboot virtual machine, the windows OS get stuck on loading bar. The VirtIO drivers is the latest stable that i made the download from

Re: [PATCH v3 8/9] KVM: arm-vgic: Add GICD_SPENDSGIR and GICD_CPENDSGIR handlers

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: Handle MMIO accesses to the two registers which should support both the case where the VMs want to read/write either of these registers and the case where user space reads/writes these registers to do save/restore of the VGIC state. Note that the

Re: [PATCH v3 9/9] KVM: arm-vgic: Support CPU interface reg access

2013-12-09 Thread Marc Zyngier
On 2013-11-17 04:30, Christoffer Dall wrote: Implement support for the CPU interface register access driven by MMIO address offsets from the CPU interface base address. Useful for user space to support save/restore of the VGIC state. This commit adds support only for the same logic as the

Re: [PATCH 1/2 v2] arm/arm64: KVM: arch_timer: Initialize cntvoff at kvm_init

2013-12-09 Thread Marc Zyngier
On 2013-11-17 03:12, Christoffer Dall wrote: Initialize the cntvoff at kvm_init_vm time, not before running the VCPUs at the first time because that will overwrite any potentially restored values from user space. Cc: Marc Zynger marc.zyng...@arm.com Cc: Andre Przywara

Re: [PATCH 2/2 v3 RESEND] ARM/KVM: save and restore generic timer registers

2013-12-09 Thread Marc Zyngier
On 2013-11-17 03:12, Christoffer Dall wrote: From: Andre Przywara andre.przyw...@linaro.org For migration to work we need to save (and later restore) the state of each cores virtual generic timer. Since this is per VCPU, we can use the [gs]et_one_reg ioctl and export the three needed

Re: [REPOST][PATCH 1/2] driver core: Add new device_driver flag to allow binding via sysfs only

2013-12-09 Thread Kim Phillips
On Thu, 5 Dec 2013 16:38:15 -0600 Scott Wood scottw...@freescale.com wrote: On Thu, 2013-12-05 at 17:45 +, Kim Phillips wrote: On Tue, 03 Dec 2013 16:34:33 +0100 Jan Kiszka jan.kis...@siemens.com wrote: On 2013-12-03 13:34, Kim Phillips wrote: VFIO supports pass-through of

Re: Performance counters in kvm?

2013-12-09 Thread Binh Q. Pham
Sorry for a late response as I was distracted by another task in the last few weeks. Today, I compiled and installed QEMU 1.7.0 from source, but no luck with this. Tested on a different machine with different kernel version: 3.2, I got the same results. Btw, I found bug 798936 which describes

Re: [REPOST][PATCH 1/2] driver core: Add new device_driver flag to allow binding via sysfs only

2013-12-09 Thread Jan Kiszka
On 2013-12-09 19:58, Kim Phillips wrote: On Thu, 5 Dec 2013 16:38:15 -0600 Scott Wood scottw...@freescale.com wrote: On Thu, 2013-12-05 at 17:45 +, Kim Phillips wrote: On Tue, 03 Dec 2013 16:34:33 +0100 Jan Kiszka jan.kis...@siemens.com wrote: On 2013-12-03 13:34, Kim Phillips wrote:

Re: Problem after update windows VirtIO drivers

2013-12-09 Thread Cole Robinson
On 12/09/2013 11:45 AM, Alon Levy wrote: On 12/09/2013 04:45 PM, Carlos Rodrigues wrote: Hello, After update the VirtIO drivers for Windows Server 2008 R2 64-bit, when i reboot virtual machine, the windows OS get stuck on loading bar. The VirtIO drivers is the latest stable that i made the

Re: [PATCH] powerpc/kvm/booke: Fix build break due to stack frame size warning

2013-12-09 Thread Scott Wood
On Mon, 2013-11-25 at 04:26 -0600, Bharat Bhushan wrote: -Original Message- From: Wood Scott-B07421 Sent: Saturday, November 23, 2013 3:22 AM To: Alexander Graf Cc: kvm-...@vger.kernel.org; kvm@vger.kernel.org; Wood Scott-B07421; Bhushan Bharat-R65777 Subject: [PATCH]

Re: [REPOST][PATCH 1/2] driver core: Add new device_driver flag to allow binding via sysfs only

2013-12-09 Thread Scott Wood
On Mon, 2013-12-09 at 20:12 +0100, Jan Kiszka wrote: On 2013-12-09 19:58, Kim Phillips wrote: On Thu, 5 Dec 2013 16:38:15 -0600 Scott Wood scottw...@freescale.com wrote: What would combining them solve, other than making it more likely that Greg complains about the wildcard because it

Re: [PATCH] powerpc/kvm/booke: Fix build break due to stack frame size warning

2013-12-09 Thread Alexander Graf
On 09.12.2013, at 22:18, Scott Wood scottw...@freescale.com wrote: On Mon, 2013-11-25 at 04:26 -0600, Bharat Bhushan wrote: -Original Message- From: Wood Scott-B07421 Sent: Saturday, November 23, 2013 3:22 AM To: Alexander Graf Cc: kvm-...@vger.kernel.org; kvm@vger.kernel.org;

Re: Problem after update windows VirtIO drivers

2013-12-09 Thread Vadim Rozenfeld
- Original Message - From: Alon Levy al...@redhat.com To: Carlos Rodrigues c...@eurotux.com, kvm@vger.kernel.org, Vadim Rozenfeld vroze...@redhat.com Sent: Tuesday, December 10, 2013 3:45:32 AM Subject: Re: Problem after update windows VirtIO drivers On 12/09/2013 04:45 PM, Carlos

Re: [PATCH 1/4] KVM: PPC: Book3S HV: Fix physical address calculations

2013-12-09 Thread Paul Mackerras
On Fri, Dec 06, 2013 at 09:52:31PM +1100, Alexey Kardashevskiy wrote: This patch breaks VFIO with Intel E1000E on my p5ioc2 machine (vpl2) - the guest tries allocating MSI ibm,change_msi and pauses for a while ( 10minutes), then continues but the ethernet adapter does not work anyway.

Re: [PATCH] KVM: PPC: Add devname:kvm aliases for modules

2013-12-09 Thread Michael Tokarev
09.12.2013 19:01, Alexander Graf wrote: [] +++ b/arch/powerpc/kvm/44x.c @@ -231,3 +231,6 @@ static void __exit kvmppc_44x_exit(void) module_init(kvmppc_44x_init); module_exit(kvmppc_44x_exit); +#include linux/miscdevice.h +MODULE_ALIAS_MISCDEV(KVM_MINOR); +MODULE_ALIAS(devname:kvm);

Re: [PATCH v3 07/15] KVM: MMU: introduce nulls desc

2013-12-09 Thread Xiao Guangrong
On 12/06/2013 08:22 AM, Marcelo Tosatti wrote: On Thu, Dec 05, 2013 at 11:30:27PM +0800, Xiao Guangrong wrote: In some cases, the lockless walker will do endless-walking on desc and without rewalk, consider this case: there are two descs: desc1 and desc2 who is pointed by desc1-next:

Re: [PATCH] KVM: nVMX: Add support for activity state HLT

2013-12-09 Thread Jan Kiszka
On 2013-12-06 13:49, Jan Kiszka wrote: On 2013-12-05 10:52, Paolo Bonzini wrote: Il 04/12/2013 08:58, Jan Kiszka ha scritto: We can easily emulate the HLT activity state for L1: If it decides that L2 shall be halted on entry, just invoke the normal emulation of halt after switching to L2. We

[PATCH] KVM: PPC: Add devname:kvm aliases for modules

2013-12-09 Thread Alexander Graf
Systems that support automatic loading of kernel modules through device aliases should try and automatically load kvm when /dev/kvm gets opened. Add code to support that magic for all PPC kvm targets, even the ones that don't support modules yet. Signed-off-by: Alexander Graf ag...@suse.de ---

Re: [PATCH] KVM: PPC: fix couple of memory leaks in MPIC/XICS devices

2013-12-09 Thread Alexander Graf
On 04.09.2013, at 14:16, Paul Mackerras pau...@samba.org wrote: On Sun, Sep 01, 2013 at 03:53:46PM +0300, Gleb Natapov wrote: XICS failed to free xics structure on error path. MPIC destroy handler forgot to delete kvm_device structure. Signed-off-by: Gleb Natapov g...@redhat.com

Re: [PATCH 0/4] KVM: PPC: Unify FP/VMX/VSX state handling between KVM and main kernel

2013-12-09 Thread Alexander Graf
On 15.10.2013, at 11:43, Paul Mackerras pau...@samba.org wrote: This series makes use of the new thread_fp_state and thread_vr_state structures to unify the way that floating-point and vector state is handled. With both KVM and the main kernel using the same structures to store this state

Re: [PATCH] powerpc/kvm/booke: Fix build break due to stack frame size warning

2013-12-09 Thread Scott Wood
On Mon, 2013-11-25 at 04:26 -0600, Bharat Bhushan wrote: -Original Message- From: Wood Scott-B07421 Sent: Saturday, November 23, 2013 3:22 AM To: Alexander Graf Cc: kvm-ppc@vger.kernel.org; k...@vger.kernel.org; Wood Scott-B07421; Bhushan Bharat-R65777 Subject: [PATCH]