Re: [PATCH RFC V8 0/17] Paravirtualized ticket spinlocks

2012-05-08 Thread Nikunj A Dadhania
On Mon, 7 May 2012 22:42:30 +0200 (CEST), Thomas Gleixner t...@linutronix.de wrote: On Mon, 7 May 2012, Ingo Molnar wrote: * Avi Kivity a...@redhat.com wrote: PS: Nikunj had experimented that pv-flush tlb + paravirt-spinlock is a win on PLE where only one of them alone could

Re: [PATCH 1/4] KVM: Add APIs for unlocked TLB flush

2012-05-08 Thread Avi Kivity
On 05/08/2012 04:55 AM, Marcelo Tosatti wrote: Yes, so, we can change kvm_mark_tlb_dirty to: +static inline void kvm_mark_tlb_dirty(struct kvm *kvm) +{ + /* + * Make any changes to the page tables visible to remote flushers. + */ + smb_mb(); +

Re: [PATCH 1/4] KVM: Add APIs for unlocked TLB flush

2012-05-08 Thread Avi Kivity
On 05/08/2012 04:55 AM, Marcelo Tosatti wrote: Yes, so, we can change kvm_mark_tlb_dirty to: +static inline void kvm_mark_tlb_dirty(struct kvm *kvm) +{ + /* + * Make any changes to the page tables visible to remote flushers. + */ + smb_mb(); +

RE: [PATCH] PCI: save/restore max Latency Value for device LTR

2012-05-08 Thread Hao, Xudong
-Original Message- From: Bjorn Helgaas [mailto:bhelg...@google.com]  } This doesn't make any sense to me. pos is the offset of the PCI Express Capability (identifier 10h). LTR is a separate extended capability (identifier 18h), so you at least have to look up its offset.

Re: [PATCH RFC V8 0/17] Paravirtualized ticket spinlocks

2012-05-08 Thread Avi Kivity
On 05/08/2012 02:15 AM, Jeremy Fitzhardinge wrote: On 05/07/2012 06:49 AM, Avi Kivity wrote: On 05/07/2012 04:46 PM, Srivatsa Vaddagiri wrote: * Raghavendra K T raghavendra...@linux.vnet.ibm.com [2012-05-07 19:08:51]: I 'll get hold of a PLE mc and come up with the numbers soon. but I

RE: [PATCH] kvm: Enable device LTR/OBFF capibility before doing guest device assignment

2012-05-08 Thread Hao, Xudong
-Original Message- From: Alex Williamson [mailto:alex.william...@redhat.com] Sent: Tuesday, May 08, 2012 12:16 AM To: Hao, Xudong Cc: Avi Kivity; Xudong Hao; mtosa...@redhat.com; kvm@vger.kernel.org; linux-ker...@vger.kernel.org; Zhang, Xiantao Subject: RE: [PATCH] kvm: Enable

[PATCH] kvm tool: Add own barrier() definition

2012-05-08 Thread Cyrill Gorcunov
Otherwise I'm getting the following compile problem on my Fedora machine. The helper is rather taken from linux kernel. | [cyrill@moon kvm]$ make tags | x86/include/kvm/barrier.h:11:25: fatal error: asm/barrier.h: No such file or directory compilation terminated. Signed-off-by: Cyrill

[PATCH] KVM: PPC: Book3S HV: Fix refcounting of hugepages

2012-05-08 Thread Paul Mackerras
From: David Gibson da...@gibson.dropbear.id.au The H_REGISTER_VPA hcall implementation in HV Power KVM needs to pin some guest memory pages into host memory so that they can be safely accessed from usermode. It does this used get_user_pages_fast(). When the VPA is unregistered, or the VCPUs are

Re: [PATCH v10 1/5] KVM: PPC: Factor out guest epapr initialization

2012-05-08 Thread Alexander Graf
On 15.03.2012, at 21:52, Stuart Yoder wrote: From: Liu Yu-B13201 yu@freescale.com epapr paravirtualization support is now a Kconfig selectable option Signed-off-by: Liu Yu yu@freescale.com [stuart.yo...@freescale.com: misc minor fixes, description update] Signed-off-by: Stuart

Re: [PATCH v10 2/5] KVM: PPC: use definitions in epapr header for hcalls

2012-05-08 Thread Alexander Graf
On 15.03.2012, at 21:52, Stuart Yoder wrote: From: Stuart Yoder stuart.yo...@freescale.com Signed-off-by: Stuart Yoder stuart.yo...@freescale.com --- arch/powerpc/include/asm/kvm_para.h | 19 +-- arch/powerpc/kernel/kvm.c |2 +- arch/powerpc/kvm/powerpc.c

Re: [PATCH v10 3/5] KVM: PPC: Add support for ePAPR idle hcall in host kernel

2012-05-08 Thread Alexander Graf
On 15.03.2012, at 21:52, Stuart Yoder wrote: From: Liu Yu-B13201 yu@freescale.com And add a new flag definition in kvm_ppc_pvinfo to indicate whether the host supports the EV_IDLE hcall. Signed-off-by: Liu Yu yu@freescale.com [stuart.yo...@freescale.com: cleanup,fixes for

Re: [PATCH v10 4/5] KVM: PPC: ev_idle hcall support for e500 guests

2012-05-08 Thread Alexander Graf
On 15.03.2012, at 21:52, Stuart Yoder wrote: From: Liu Yu-B13201 yu@freescale.com Signed-off-by: Liu Yu yu@freescale.com [stuart: update patch description] Signed-off-by: Stuart Yoder stuart.yo...@freescale.com --- v10: -add spaces as per comments -use PPC_LL/PPC_STL for

Re: [PATCH 0/4] Unlocked TLB flush

2012-05-08 Thread Avi Kivity
On 05/08/2012 04:27 AM, Marcelo Tosatti wrote: On Mon, May 07, 2012 at 10:25:34PM -0300, Marcelo Tosatti wrote: On Thu, May 03, 2012 at 02:22:58PM +0300, Avi Kivity wrote: This patchset implements unlocked TLB flushing for KVM. An operation that generates stale TLB entries can mark the

[PATCH unit-tests] Add async page fault test

2012-05-08 Thread Gleb Natapov
Signed-off-by: Gleb Natapov g...@redhat.com diff --git a/config-x86-common.mak b/config-x86-common.mak index c8fbda7..6976f78 100644 --- a/config-x86-common.mak +++ b/config-x86-common.mak @@ -34,7 +34,7 @@ tests-common = $(TEST_DIR)/vmexit.flat $(TEST_DIR)/tsc.flat \

Re: [Qemu-devel] KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Anthony Liguori
On 05/07/2012 06:47 AM, Juan Quintela wrote: Hi Please send in any agenda items you are interested in covering. I've got a conflict at 9am as it turns out so I won't be able to attend. Regards, Anthony Liguori Thanks, Juan. -- To unsubscribe from this list: send the line unsubscribe

Re: [Qemu-devel] KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Alexander Graf
On 08.05.2012, at 14:14, Anthony Liguori wrote: On 05/07/2012 06:47 AM, Juan Quintela wrote: Hi Please send in any agenda items you are interested in covering. I've got a conflict at 9am as it turns out so I won't be able to attend. We can always move it an hour earlier, no? :) Alex

Re: [PATCH] kvm tool: Add own barrier() definition

2012-05-08 Thread Pekka Enberg
On Tue, 8 May 2012, Cyrill Gorcunov wrote: Otherwise I'm getting the following compile problem on my Fedora machine. The helper is rather taken from linux kernel. | [cyrill@moon kvm]$ make tags | x86/include/kvm/barrier.h:11:25: fatal error: asm/barrier.h: No such file or directory

Re: [PATCH 1/4] KVM: Add APIs for unlocked TLB flush

2012-05-08 Thread Avi Kivity
On 05/08/2012 05:25 AM, Marcelo Tosatti wrote: We need call kvm_cond_flush_remote_tlbs in rmap_write-protect unconditionally? Yes, that's the point. We change spin_lock(mmu_lock) conditionally flush the tlb spin_unlock(mmu_lock) to spin_lock(mmu_lock)

Re: [PATCH] KVM: PPC: Book3S HV: Fix refcounting of hugepages

2012-05-08 Thread Alexander Graf
On 08.05.2012, at 12:24, Paul Mackerras wrote: From: David Gibson da...@gibson.dropbear.id.au The H_REGISTER_VPA hcall implementation in HV Power KVM needs to pin some guest memory pages into host memory so that they can be safely accessed from usermode. It does this used

Re: [Qemu-devel] KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Luiz Capitulino
On Tue, 08 May 2012 07:14:11 -0500 Anthony Liguori anth...@codemonkey.ws wrote: On 05/07/2012 06:47 AM, Juan Quintela wrote: Hi Please send in any agenda items you are interested in covering. I've got a conflict at 9am as it turns out so I won't be able to attend. Does this mean the

Re: KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Juan Quintela
Juan Quintela quint...@redhat.com wrote: Hi Please send in any agenda items you are interested in covering. Anthony can't make the call, but we have one agenda: - Status of the 1.1 release We can always blame Anthony, as he didn't attend. - QEMU documentation We don't need him to know

Re: [PULL 00/16] ppc patch queue 2012-05-06

2012-05-08 Thread Avi Kivity
On 05/06/2012 05:20 PM, Alexander Graf wrote: Hi Avi, This is my current patch queue for ppc. Please pull. Thanks, pulled. Next time, please add a short summary of the changes for me to put in the merge commit. -- error compiling committee.c: too many arguments to function -- To

Re: [Qemu-devel] KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Andreas Färber
Am 07.05.2012 14:54, schrieb Anthony Liguori: On 05/07/2012 06:47 AM, Juan Quintela wrote: Please send in any agenda items you are interested in covering. - Status of the 1.1 release Since it looked like the call is not going to take place lacking feedback from Anthony, I will provocatively

Re: [Qemu-devel] KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Anthony Liguori
On 05/08/2012 09:10 AM, Andreas Färber wrote: Am 07.05.2012 14:54, schrieb Anthony Liguori: On 05/07/2012 06:47 AM, Juan Quintela wrote: Please send in any agenda items you are interested in covering. - Status of the 1.1 release Since it looked like the call is not going to take place

KVM minutes May 8th

2012-05-08 Thread Juan Quintela
Hi - Status of the 1.1 release It looks like everything is to the plan, and only bugfixes should be allowed now. - QEMU documentation * Improve properties. Now there is no help when you use -device. * Amit did something about it? Resurect that work? * People don't write documentation. * How

Re: [Qemu-devel] KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Andreas Färber
Am 08.05.2012 16:24, schrieb Anthony Liguori: On 05/08/2012 09:10 AM, Andreas Färber wrote: Am 07.05.2012 14:54, schrieb Anthony Liguori: rc0 is available, but patches submitted for 1.1 shortly before rc0 neither got review nor were applied. Neither did pulls or patches applied by Anthony get

Re: [PATCH] KVM: PPC: Book3S HV: Fix refcounting of hugepages

2012-05-08 Thread Avi Kivity
On 05/08/2012 04:10 PM, Alexander Graf wrote: On 08.05.2012, at 12:24, Paul Mackerras wrote: From: David Gibson da...@gibson.dropbear.id.au The H_REGISTER_VPA hcall implementation in HV Power KVM needs to pin some guest memory pages into host memory so that they can be safely accessed

Re: [PATCH 1/4] KVM: Add APIs for unlocked TLB flush

2012-05-08 Thread Marcelo Tosatti
On Tue, May 08, 2012 at 12:09:38PM +0300, Avi Kivity wrote: On 05/08/2012 04:55 AM, Marcelo Tosatti wrote: Yes, so, we can change kvm_mark_tlb_dirty to: +static inline void kvm_mark_tlb_dirty(struct kvm *kvm) +{ + /* +* Make any changes to the page tables

Re: [Qemu-devel] KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Andreas Färber
Am 08.05.2012 16:53, schrieb Andreas Färber: Am 08.05.2012 16:24, schrieb Anthony Liguori: On 05/08/2012 09:10 AM, Andreas Färber wrote: With rc0 not being provided as tarball, it would be nice to document the official, reproducible way of packaging a QEMU tarball on the Wiki. I have

[PATCH] kvm-unittests: Fix apic unittest for latest qemu-kvm

2012-05-08 Thread Joerg Roedel
Since commit b334ec56 in qemu-kvm the use of irqlines 15 is not supported anymore. This causes the apic unittest to fail since this commit. Since the commit-msg explicitly states that potential users of this needs to be fixed, here is the fix which uses irq lines 14 and 15 instead in the

RE: [PATCH] kvm: Enable device LTR/OBFF capibility before doing guest device assignment

2012-05-08 Thread Alex Williamson
On Tue, 2012-05-08 at 09:16 +, Hao, Xudong wrote: -Original Message- From: Alex Williamson [mailto:alex.william...@redhat.com] Sent: Tuesday, May 08, 2012 12:16 AM To: Hao, Xudong Cc: Avi Kivity; Xudong Hao; mtosa...@redhat.com; kvm@vger.kernel.org;

Re: [PATCH RFC dontapply 5/5] kvm_para: guest side for eoi avoidance

2012-05-08 Thread Paolo Bonzini
Il 23/04/2012 16:04, Michael S. Tsirkin ha scritto: +/* Our own copy of __test_and_clear_bit to make sure + * it is done with a single instruction */ Is this for microoptimization or correctness? If the latter, it does not ensure anything without a lock prefix. Paolo +static inline int

Re: [PATCH RFC dontapply 5/5] kvm_para: guest side for eoi avoidance

2012-05-08 Thread Gleb Natapov
On Tue, May 08, 2012 at 05:26:55PM +0200, Paolo Bonzini wrote: Il 23/04/2012 16:04, Michael S. Tsirkin ha scritto: +/* Our own copy of __test_and_clear_bit to make sure + * it is done with a single instruction */ Is this for microoptimization or correctness? If the latter, it does not

Re: [Qemu-devel] KVM call agenda for May, Tuesday 8th

2012-05-08 Thread Anthony Liguori
On 05/08/2012 10:13 AM, Andreas Färber wrote: Am 08.05.2012 16:53, schrieb Andreas Färber: Am 08.05.2012 16:24, schrieb Anthony Liguori: On 05/08/2012 09:10 AM, Andreas Färber wrote: With rc0 not being provided as tarball, it would be nice to document the official, reproducible way of

Re: [PATCH RFC dontapply 5/5] kvm_para: guest side for eoi avoidance

2012-05-08 Thread H. Peter Anvin
On 05/08/2012 08:28 AM, Gleb Natapov wrote: On Tue, May 08, 2012 at 05:26:55PM +0200, Paolo Bonzini wrote: Il 23/04/2012 16:04, Michael S. Tsirkin ha scritto: +/* Our own copy of __test_and_clear_bit to make sure + * it is done with a single instruction */ Is this for microoptimization or

Re: [PATCH RFC dontapply 5/5] kvm_para: guest side for eoi avoidance

2012-05-08 Thread Gleb Natapov
On Tue, May 08, 2012 at 08:45:39AM -0700, H. Peter Anvin wrote: On 05/08/2012 08:28 AM, Gleb Natapov wrote: On Tue, May 08, 2012 at 05:26:55PM +0200, Paolo Bonzini wrote: Il 23/04/2012 16:04, Michael S. Tsirkin ha scritto: +/* Our own copy of __test_and_clear_bit to make sure + * it is

Re: [PATCH RFC dontapply 5/5] kvm_para: guest side for eoi avoidance

2012-05-08 Thread Michael S. Tsirkin
On Tue, May 08, 2012 at 08:45:39AM -0700, H. Peter Anvin wrote: On 05/08/2012 08:28 AM, Gleb Natapov wrote: On Tue, May 08, 2012 at 05:26:55PM +0200, Paolo Bonzini wrote: Il 23/04/2012 16:04, Michael S. Tsirkin ha scritto: +/* Our own copy of __test_and_clear_bit to make sure + * it is

Re: [PATCH RFC dontapply 5/5] kvm_para: guest side for eoi avoidance

2012-05-08 Thread H. Peter Anvin
On 05/08/2012 09:57 AM, Michael S. Tsirkin wrote: Will do. OK to only define them for x86 for now? They would be unused on other arches even if I defined them ... I don't know if it's possible/practical to define them so they fall back to the fully atomic versions unless arch-overridden,

1G huge pages in Linux guest VM

2012-05-08 Thread Sriram Murthy
Hi, I wanted to know if we can pass a hugetlbfs with pagesize=1G created on the host to a Linux guest (The host is running RHEL 6.2 - x86_64 on Intel Westmere)?. I am using RHEL 6.2 on the host and guest and the processor that has been passed by KVM to the guest is Intel Westmere and has

Re: [PATCH RFC dontapply 5/5] kvm_para: guest side for eoi avoidance

2012-05-08 Thread Michael S. Tsirkin
On Tue, May 08, 2012 at 11:06:10AM -0700, H. Peter Anvin wrote: On 05/08/2012 09:57 AM, Michael S. Tsirkin wrote: Will do. OK to only define them for x86 for now? They would be unused on other arches even if I defined them ... I don't know if it's possible/practical to define them so

Re: Semantics of -cpu host (was Re: [Qemu-devel] [PATCH 2/2] Expose tsc deadline timer cpuid to guest)

2012-05-08 Thread Eduardo Habkost
On Tue, May 08, 2012 at 02:58:11AM +0200, Alexander Graf wrote: On 07.05.2012, at 20:21, Eduardo Habkost wrote: Andre? Are you able to help to answer the question below? I would like to clarify what's the expected behavior of -cpu host to be able to continue working on it. I believe

Re: Semantics of -cpu host (was Re: [Qemu-devel] [PATCH 2/2] Expose tsc deadline timer cpuid to guest)

2012-05-08 Thread Alexander Graf
On 08.05.2012, at 22:14, Eduardo Habkost wrote: On Tue, May 08, 2012 at 02:58:11AM +0200, Alexander Graf wrote: On 07.05.2012, at 20:21, Eduardo Habkost wrote: Andre? Are you able to help to answer the question below? I would like to clarify what's the expected behavior of -cpu host to

RE: [PATCH] kvm: Enable device LTR/OBFF capibility before doing guest device assignment

2012-05-08 Thread Hao, Xudong
-Original Message- From: Alex Williamson [mailto:alex.william...@redhat.com] Sent: Tuesday, May 08, 2012 11:18 PM To: Hao, Xudong Cc: Avi Kivity; Xudong Hao; mtosa...@redhat.com; kvm@vger.kernel.org; linux-ker...@vger.kernel.org; Zhang, Xiantao Subject: RE: [PATCH] kvm: Enable

Re: [PATCH] kvm-unittests: Fix apic unittest for latest qemu-kvm

2012-05-08 Thread Amos Kong
On 08/05/12 23:17, Joerg Roedel wrote: Since commit b334ec56 in qemu-kvm the use of irqlines 15 is not supported anymore. This causes the apic unittest to fail since this commit. Since the commit-msg explicitly states that potential users of this needs to be fixed, here is the fix which uses

RE: [PATCH] kvm: Enable device LTR/OBFF capibility before doing guest device assignment

2012-05-08 Thread Alex Williamson
On Wed, 2012-05-09 at 01:18 +, Hao, Xudong wrote: -Original Message- From: Alex Williamson [mailto:alex.william...@redhat.com] Sent: Tuesday, May 08, 2012 11:18 PM To: Hao, Xudong Cc: Avi Kivity; Xudong Hao; mtosa...@redhat.com; kvm@vger.kernel.org;

[PATCH] qemu-kvm: Build fixes for ppc64-softmmu

2012-05-08 Thread Benjamin Herrenschmidt
This is a small collection of build fixes that allow the qemu-kvm tree to build a ppc64-softmmu target with kvm enabled (provided device-assignment is disabled). Signed-off-by: Benjamin Herrenschmidt b...@kernel.crashing.org --- Avi, Marcelo: This is really only for qemu-kvm, not upstream qemu,

[PATCH] KVM: PPC: Book3S HV: Fix refcounting of hugepages

2012-05-08 Thread Paul Mackerras
From: David Gibson da...@gibson.dropbear.id.au The H_REGISTER_VPA hcall implementation in HV Power KVM needs to pin some guest memory pages into host memory so that they can be safely accessed from usermode. It does this used get_user_pages_fast(). When the VPA is unregistered, or the VCPUs are

Re: [PATCH v10 1/5] KVM: PPC: Factor out guest epapr initialization

2012-05-08 Thread Alexander Graf
On 15.03.2012, at 21:52, Stuart Yoder wrote: From: Liu Yu-B13201 yu@freescale.com epapr paravirtualization support is now a Kconfig selectable option Signed-off-by: Liu Yu yu@freescale.com [stuart.yo...@freescale.com: misc minor fixes, description update] Signed-off-by: Stuart