Monotonic clock with KVM pv-clock

2014-01-20 Thread Nadav Har'El
Hi, I'm trying to figure out how a guest OS can get a monotonic clock using KVM's paravirtual clock. At first, I thought that the clock I get using KVM_SYSTEM_TIME is a monotonic clock, based on the host's monotonic clock. But I'm no longer sure this is actually done correctly: 1. What happens

[PULL 1/1] KVM: s390: Fix memory access error detection

2014-01-20 Thread Christian Borntraeger
Seems that commit 210b1607012cc9034841a393e0591b2c86d9e26c (KVM: s390: Removed SIE_INTERCEPT_UCONTROL) lost a hunk when we reworked our patch queue to rework the async_fp code. We now ignore faults on the sie instruction (guest accesses non-existing memory) instead of sending a fault into the

[PULL 0/1] KVM: s390: urgent fix for kvm/next

2014-01-20 Thread Christian Borntraeger
Paolo, here is a fix for a regression that is in current kvm/next, which is targetted for 3.14. Please apply Christian Borntraeger (1): KVM: s390: Fix memory access error detection arch/s390/kvm/kvm-s390.c |4 1 file changed, 4 insertions(+) -- 1.7.9.5 The following changes since

Re: [PULL 0/1] KVM: s390: urgent fix for kvm/next

2014-01-20 Thread Paolo Bonzini
Il 20/01/2014 12:54, Christian Borntraeger ha scritto: Paolo, here is a fix for a regression that is in current kvm/next, which is targetted for 3.14. Please apply Christian Borntraeger (1): KVM: s390: Fix memory access error detection arch/s390/kvm/kvm-s390.c |4 1 file

Re: [PULL 1/1] KVM: s390: Fix memory access error detection

2014-01-20 Thread Cornelia Huck
On Mon, 20 Jan 2014 12:54:03 +0100 Christian Borntraeger borntrae...@de.ibm.com wrote: Seems that commit 210b1607012cc9034841a393e0591b2c86d9e26c (KVM: s390: Removed SIE_INTERCEPT_UCONTROL) lost a hunk when we reworked our patch queue to rework the async_fp code. We now ignore faults on the

Re: [RFC PATCH 2/3] arm64: KVM: trap VM system registers until MMU and caches are ON

2014-01-20 Thread Anup Patel
On Fri, Jan 17, 2014 at 8:33 PM, Marc Zyngier marc.zyng...@arm.com wrote: In order to be able to detect the point where the guest enables its MMU and caches, trap all the VM related system registers. Once we see the guest enabling both the MMU and the caches, we can go back to a saner mode of

Assertion failure in qemu-char.c

2014-01-20 Thread Wesley Holevinski
Hi all, I'm running into an issue that's causing my guests to crash while using vm-channels. There is an assertion that's failing in qemu-char.c, that, when it happens causes my guest to go down. The error can be seen in the host-side logs. Rather than being too wordy on-list, here's a

[PATCH uq/master] kvm: always update the MPX model specific register

2014-01-20 Thread Paolo Bonzini
The original patch from Liu Jinsong restricted them to reset or full state updates, but that's unnecessary (and wrong) since the BNDCFGS MSR has no side effects. Cc: Liu Jinsong jinsong@intel.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- target-i386/kvm.c | 6 +++--- 1 file

Re: [RFC PATCH 2/3] arm64: KVM: trap VM system registers until MMU and caches are ON

2014-01-20 Thread Marc Zyngier
Hi Anup, On 20/01/14 12:00, Anup Patel wrote: On Fri, Jan 17, 2014 at 8:33 PM, Marc Zyngier marc.zyng...@arm.com wrote: In order to be able to detect the point where the guest enables its MMU and caches, trap all the VM related system registers. Once we see the guest enabling both the MMU

Re: Monotonic clock with KVM pv-clock

2014-01-20 Thread Marcelo Tosatti
On Mon, Jan 20, 2014 at 11:56:56AM +0200, Nadav Har'El wrote: Hi, I'm trying to figure out how a guest OS can get a monotonic clock using KVM's paravirtual clock. At first, I thought that the clock I get using KVM_SYSTEM_TIME is a monotonic clock, based on the host's monotonic clock. It

Re: Assertion failure in qemu-char.c

2014-01-20 Thread Paolo Bonzini
Il 20/01/2014 13:37, Wesley Holevinski ha scritto: Hi all, I'm running into an issue that's causing my guests to crash while using vm-channels. There is an assertion that's failing in qemu-char.c, that, when it happens causes my guest to go down. The error can be seen in the host-side

Re: KVM and variable-endianness guest CPUs

2014-01-20 Thread Alexander Graf
On 18.01.2014, at 11:15, Peter Maydell peter.mayd...@linaro.org wrote: On 18 January 2014 07:32, Alexander Graf ag...@suse.de wrote: Am 18.01.2014 um 05:24 schrieb Christoffer Dall christoffer.d...@linaro.org: On Fri, Jan 17, 2014 at 06:52:57PM +, Peter Maydell wrote: Having thought a

Re: KVM and variable-endianness guest CPUs

2014-01-20 Thread Alexander Graf
On 17.01.2014, at 19:52, Peter Maydell peter.mayd...@linaro.org wrote: On 17 January 2014 17:53, Peter Maydell peter.mayd...@linaro.org wrote: Specifically, the KVM API says here's a uint8_t[] byte array and a length, and the current QEMU code treats that as this is a byte array written as

Re: KVM and variable-endianness guest CPUs

2014-01-20 Thread Peter Maydell
On 20 January 2014 14:20, Alexander Graf ag...@suse.de wrote: I think I see the problem now. You're thinking about LE hosts, not LE guests. I think the only really sensible options would be to a) Always use a statically define target endianness (big for ppc) b) Always use host endianness

Re: [PATCH v2 0/4] X86/KVM: enable Intel MPX for KVM

2014-01-20 Thread Paolo Bonzini
Il 12/12/2013 12:09, Liu, Jinsong ha scritto: Paolo Bonzini wrote: Il 12/12/2013 06:47, Liu, Jinsong ha scritto: Paolo Bonzini wrote: Il 11/12/2013 09:31, Liu, Jinsong ha scritto: Paolo, comments for version 2? I think I commented that it's fine, I'm just waiting for a rebase on top of the

RE: Assertion failure in qemu-char.c

2014-01-20 Thread Wesley Holevinski
You also aren't describing if doing anything specifically will cause the crash. Sorry, I've yet to narrow down the exact case that's causing it. Basically, it's constant use of the vm-channel; I have a binary that will write to the character device at an interval. If I leave it running with

Re: Monotonic clock with KVM pv-clock

2014-01-20 Thread Fernando Luis Vazquez Cao
(2014/01/20 22:33), Marcelo Tosatti wrote: On Mon, Jan 20, 2014 at 11:56:56AM +0200, Nadav Har'El wrote: If KVM_SYSTEM_TIME is not a correct way to get a monotonic paravirtual clock from KVM, is there a correct way? Inside a Linux guest? Can use sched_clock(). I would like to mention that

Re: [RFC PATCH 3/4] virtio_balloon: add pressure notification via a new virtqueue

2014-01-20 Thread Luiz Capitulino
On Mon, 20 Jan 2014 12:43:45 +1030 Rusty Russell ru...@rustcorp.com.au wrote: Luiz Capitulino lcapitul...@redhat.com writes: On Fri, 17 Jan 2014 09:10:47 +1030 Rusty Russell ru...@rustcorp.com.au wrote: Luiz Capitulino lcapitul...@redhat.com writes: From: Luiz capitulino

Re: [PATCH v2] kvm/ppc: IRQ disabling cleanup

2014-01-20 Thread Alexander Graf
On 10.01.2014, at 02:18, Scott Wood scottw...@freescale.com wrote: Simplify the handling of lazy EE by going directly from fully-enabled to hard-disabled. This replaces the lazy_irq_pending() check (including its misplaced kvm_guest_exit() call). As suggested by Tiejun Chen, move the

Re: [RFC PATCH 2/3] arm64: KVM: trap VM system registers until MMU and caches are ON

2014-01-20 Thread Anup Patel
Hi Marc, On Mon, Jan 20, 2014 at 7:11 PM, Marc Zyngier marc.zyng...@arm.com wrote: Hi Anup, On 20/01/14 12:00, Anup Patel wrote: On Fri, Jan 17, 2014 at 8:33 PM, Marc Zyngier marc.zyng...@arm.com wrote: In order to be able to detect the point where the guest enables its MMU and caches, trap

Re: [Qemu-devel] [PATCH 0/7 RESEND] target-i386: Simplify kvm_cpu_fill_host() and kvm_check_features_against_host()

2014-01-20 Thread Eduardo Habkost
On Mon, Jan 20, 2014 at 02:41:07PM -0200, Eduardo Habkost wrote: Resend of series submitted on 24 November 2013, that didn't get any reply. Only change is a trivial conflict on patch 7/7. Question: which tree is the most appropriate to get this in? qom-cpu? kvm? This series simplifies

Re: KVM and variable-endianness guest CPUs

2014-01-20 Thread Christoffer Dall
On Mon, Jan 20, 2014 at 03:22:11PM +0100, Alexander Graf wrote: On 17.01.2014, at 19:52, Peter Maydell peter.mayd...@linaro.org wrote: On 17 January 2014 17:53, Peter Maydell peter.mayd...@linaro.org wrote: Specifically, the KVM API says here's a uint8_t[] byte array and a length, and

Re: [Qemu-devel] [PATCH 0/7 RESEND] target-i386: Simplify kvm_cpu_fill_host() and kvm_check_features_against_host()

2014-01-20 Thread Michael S. Tsirkin
On Mon, Jan 20, 2014 at 04:36:56PM -0200, Eduardo Habkost wrote: On Mon, Jan 20, 2014 at 02:41:07PM -0200, Eduardo Habkost wrote: Resend of series submitted on 24 November 2013, that didn't get any reply. Only change is a trivial conflict on patch 7/7. Question: which tree is the most

Re: [Qemu-devel] [PATCH 0/7 RESEND] target-i386: Simplify kvm_cpu_fill_host() and kvm_check_features_against_host()

2014-01-20 Thread Andreas Färber
Am 20.01.2014 21:39, schrieb Michael S. Tsirkin: On Mon, Jan 20, 2014 at 04:36:56PM -0200, Eduardo Habkost wrote: On Mon, Jan 20, 2014 at 02:41:07PM -0200, Eduardo Habkost wrote: Resend of series submitted on 24 November 2013, that didn't get any reply. Only change is a trivial conflict on

Re: [Qemu-devel] [PATCH 0/7 RESEND] target-i386: Simplify kvm_cpu_fill_host() and kvm_check_features_against_host()

2014-01-20 Thread Michael S. Tsirkin
On Mon, Jan 20, 2014 at 10:07:47PM +0100, Andreas Färber wrote: Am 20.01.2014 21:39, schrieb Michael S. Tsirkin: On Mon, Jan 20, 2014 at 04:36:56PM -0200, Eduardo Habkost wrote: On Mon, Jan 20, 2014 at 02:41:07PM -0200, Eduardo Habkost wrote: Resend of series submitted on 24 November 2013,

Re: [PATCH 0/4] powernv: kvm: numa fault improvement

2014-01-20 Thread Alexander Graf
On 15.01.2014, at 07:36, Liu ping fan kernelf...@gmail.com wrote: On Thu, Jan 9, 2014 at 8:08 PM, Alexander Graf ag...@suse.de wrote: On 11.12.2013, at 09:47, Liu Ping Fan kernelf...@gmail.com wrote: This series is based on Aneesh's series [PATCH -V2 0/5] powerpc: mm: Numa faults

Re: [PATCH v2] kvm/ppc: IRQ disabling cleanup

2014-01-20 Thread Alexander Graf
On 10.01.2014, at 02:18, Scott Wood scottw...@freescale.com wrote: Simplify the handling of lazy EE by going directly from fully-enabled to hard-disabled. This replaces the lazy_irq_pending() check (including its misplaced kvm_guest_exit() call). As suggested by Tiejun Chen, move the

Re: [PATCH 0/4] powernv: kvm: numa fault improvement

2014-01-20 Thread Aneesh Kumar K.V
Liu ping fan kernelf...@gmail.com writes: On Thu, Jan 9, 2014 at 8:08 PM, Alexander Graf ag...@suse.de wrote: On 11.12.2013, at 09:47, Liu Ping Fan kernelf...@gmail.com wrote: This series is based on Aneesh's series [PATCH -V2 0/5] powerpc: mm: Numa faults support for ppc64 For this

Re: [PATCH 0/4] powernv: kvm: numa fault improvement

2014-01-20 Thread Liu ping fan
On Mon, Jan 20, 2014 at 11:45 PM, Aneesh Kumar K.V aneesh.ku...@linux.vnet.ibm.com wrote: Liu ping fan kernelf...@gmail.com writes: On Thu, Jan 9, 2014 at 8:08 PM, Alexander Graf ag...@suse.de wrote: On 11.12.2013, at 09:47, Liu Ping Fan kernelf...@gmail.com wrote: This series is based on

Re: [PATCH 0/4] powernv: kvm: numa fault improvement

2014-01-20 Thread Aneesh Kumar K.V
Liu ping fan kernelf...@gmail.com writes: On Mon, Jan 20, 2014 at 11:45 PM, Aneesh Kumar K.V aneesh.ku...@linux.vnet.ibm.com wrote: Liu ping fan kernelf...@gmail.com writes: On Thu, Jan 9, 2014 at 8:08 PM, Alexander Graf ag...@suse.de wrote: On 11.12.2013, at 09:47, Liu Ping Fan