Re: [PATCH V2 0/6] tcm_vhost hotplug/hotunplug support and locking/flushing fix

2013-03-08 Thread Stefan Hajnoczi
On Fri, Mar 08, 2013 at 10:21:41AM +0800, Asias He wrote: > Changes in v2: > - Remove code duplication in tcm_vhost_{hotplug,hotunplug} > - Fix racing of vs_events_nr > - Add flush fix patch to this series > > Asias He (6): > tcm_vhost: Add missed lock in vhost_scsi_clear_endpoint() > tcm_vhos

Re: kvm + ceph performance issues

2013-03-08 Thread Stefan Hajnoczi
On Thu, Mar 07, 2013 at 12:57:55PM +0100, Wolfgang Hennerbichler wrote: > I'm running a virtual machine with the following command: > > LC_ALL=C > PATH=/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/sbin:/sbin:/bin > QEMU_AUDIO_DRV=none /usr/bin/kvm -S -M pc-1.0 -enable-kvm -m 4096 -smp > 2,sockets=

Re: [STRAWMAN PATCH] KVM: PPC: Add ioctl to specify interrupt controller architecture to emulate

2013-03-08 Thread Paul Mackerras
On Thu, Mar 07, 2013 at 03:00:52PM +0100, Alexander Graf wrote: > > Could you please (in a quick and drafty way) try and see if setting the IRQ > arch (using enable_cap) after the vcpu got created would work for you? > > That enable_cap would then have to loop through all devices and notify irq

Re: [STRAWMAN PATCH] KVM: PPC: Add ioctl to specify interrupt controller architecture to emulate

2013-03-08 Thread Alexander Graf
Am 08.03.2013 um 11:37 schrieb Paul Mackerras : > On Thu, Mar 07, 2013 at 03:00:52PM +0100, Alexander Graf wrote: >> >> Could you please (in a quick and drafty way) try and see if setting the IRQ >> arch (using enable_cap) after the vcpu got created would work for you? >> >> That enable_cap w

Re: [kvmarm] [GIT PULL v2] KVM/ARM Fixes for 3.9-rc1

2013-03-08 Thread Gleb Natapov
On Fri, Mar 08, 2013 at 04:12:41AM +0100, Marc Zyngier wrote: > On Thu, 7 Mar 2013 16:09:00 -0300, Marcelo Tosatti > wrote: > > On Thu, Mar 07, 2013 at 07:57:23AM +0100, Marc Zyngier wrote: > >> On Wed, 6 Mar 2013 20:40:00 -0800, Christoffer Dall > >> > >> wrote: > >> > On Wed, Mar 6, 2013 at 7:5

Re: Ring privilege of host linux kernel

2013-03-08 Thread Gleb Natapov
On Thu, Mar 07, 2013 at 10:56:34PM -0500, l...@mymail.vcu.edu wrote: > As we have known, in KVM full virtualization, guest VM is running in > non-root mode and KVM is running in root mode. While, in non-root > mode, guest kernel is running in Ring 0 and Apps are running in Ring > 3. However, what

Re: [PATCH] kvm/powerpc/e500mc: fix tlb invalidation on cpu migration

2013-03-08 Thread Alexander Graf
On 19.02.2013, at 05:13, Scott Wood wrote: > The existing check handles the case where we've migrated to a different > core than we last ran on, but it doesn't handle the case where we're > still on the same cpu we last ran on, but some other vcpu has run on > this cpu in the meantime. > > Signe

Re: [PATCH 0/3] kvm/ppc/e500: TLB bugfixes

2013-03-08 Thread Alexander Graf
On 14.02.2013, at 06:37, Scott Wood wrote: > Scott Wood (3): > kvm/ppc/e500: h2g_tlb1_rmap: esel 0 is valid > kvm/ppc/e500: g2h_tlb1_map: clear old bit before setting new bit > kvm/ppc/e500: eliminate tlb_refs > > arch/powerpc/kvm/e500.h | 24 --- > arch/powerpc/kvm/e500_mmu

Re: [PATCH v5 2/5] KVM: VMX: Register a new IPI for posted interrupt

2013-03-08 Thread Ingo Molnar
* Yang Zhang wrote: > diff --git a/arch/x86/kernel/irqinit.c b/arch/x86/kernel/irqinit.c > index 6e03b0d..2329a54 100644 > --- a/arch/x86/kernel/irqinit.c > +++ b/arch/x86/kernel/irqinit.c > @@ -205,6 +205,10 @@ static void __init apic_intr_init(void) > > /* IPI for X86 platform specific

Re: [PATCH v5 2/5] KVM: VMX: Register a new IPI for posted interrupt

2013-03-08 Thread Gleb Natapov
On Fri, Mar 08, 2013 at 02:26:25PM +0100, Ingo Molnar wrote: > > * Yang Zhang wrote: > > > diff --git a/arch/x86/kernel/irqinit.c b/arch/x86/kernel/irqinit.c > > index 6e03b0d..2329a54 100644 > > --- a/arch/x86/kernel/irqinit.c > > +++ b/arch/x86/kernel/irqinit.c > > @@ -205,6 +205,10 @@ static

Re: [PATCH v5 2/5] KVM: VMX: Register a new IPI for posted interrupt

2013-03-08 Thread Ingo Molnar
* Gleb Natapov wrote: > On Fri, Mar 08, 2013 at 02:26:25PM +0100, Ingo Molnar wrote: > > > > * Yang Zhang wrote: > > > > > diff --git a/arch/x86/kernel/irqinit.c b/arch/x86/kernel/irqinit.c > > > index 6e03b0d..2329a54 100644 > > > --- a/arch/x86/kernel/irqinit.c > > > +++ b/arch/x86/kernel/i

RE: [PATCH v5 2/5] KVM: VMX: Register a new IPI for posted interrupt

2013-03-08 Thread Zhang, Yang Z
Ingo Molnar wrote on 2013-03-08: > > * Gleb Natapov wrote: > >> On Fri, Mar 08, 2013 at 02:26:25PM +0100, Ingo Molnar wrote: >>> >>> * Yang Zhang wrote: >>> diff --git a/arch/x86/kernel/irqinit.c b/arch/x86/kernel/irqinit.c index 6e03b0d..2329a54 100644 --- a/arch/x86/kernel/ir

Re: [PATCH v5 2/5] KVM: VMX: Register a new IPI for posted interrupt

2013-03-08 Thread Gleb Natapov
On Fri, Mar 08, 2013 at 03:05:45PM +0100, Ingo Molnar wrote: > > * Gleb Natapov wrote: > > > On Fri, Mar 08, 2013 at 02:26:25PM +0100, Ingo Molnar wrote: > > > > > > * Yang Zhang wrote: > > > > > > > diff --git a/arch/x86/kernel/irqinit.c b/arch/x86/kernel/irqinit.c > > > > index 6e03b0d..232

Re: Ring privilege of host linux kernel

2013-03-08 Thread Min Li
On 03/08/2013 06:42 AM, Gleb Natapov wrote: On Thu, Mar 07, 2013 at 10:56:34PM -0500, l...@mymail.vcu.edu wrote: As we have known, in KVM full virtualization, guest VM is running in non-root mode and KVM is running in root mode. While, in non-root mode, guest kernel is running in Ring 0 and Apps

Re: TCP small packets throughput and multiqueue virtio-net

2013-03-08 Thread Eric Dumazet
On Fri, 2013-03-08 at 14:24 +0800, Jason Wang wrote: > Hello all: > > I meet an issue when testing multiqueue virtio-net. When I testing guest > small packets stream sending performance with netperf. I find an > regression of multiqueue. When I run 2 sessions of TCP_STREAM test with > 1024 byte fr

Re: [PATCH v5 2/5] KVM: VMX: Register a new IPI for posted interrupt

2013-03-08 Thread Ingo Molnar
* Gleb Natapov wrote: > On Fri, Mar 08, 2013 at 03:05:45PM +0100, Ingo Molnar wrote: > > > > * Gleb Natapov wrote: > > > > > On Fri, Mar 08, 2013 at 02:26:25PM +0100, Ingo Molnar wrote: > > > > > > > > * Yang Zhang wrote: > > > > > > > > > diff --git a/arch/x86/kernel/irqinit.c b/arch/x86/

Re: TCP small packets throughput and multiqueue virtio-net

2013-03-08 Thread Rick Jones
Well, the point is : if your app does write(1024) bytes, thats probably because it wants small packets from the very beginning. (See the TCP PUSH flag ?) I think that raises the question of whether or not Jason was setting the test-specific -D option on his TCP_STREAM tests, to have netperf

Re: Guest host cannot be connected to the LAN through 802.1q VLANs

2013-03-08 Thread Vlad Yasevich
On 03/04/2013 02:33 AM, Frank Bonnet wrote: Hello Not sure if this is the right list. You might get more help on the qemu-devel list. I'm in trouble with a guest host that is not living on the same subnet than the hypervisor that I would like to connect to my LAN through 802.1q VLAN ( ubu

Re: [kvmarm] [GIT PULL v2] KVM/ARM Fixes for 3.9-rc1

2013-03-08 Thread Christoffer Dall
On Thu, Mar 7, 2013 at 7:12 PM, Marc Zyngier wrote: > On Thu, 7 Mar 2013 16:09:00 -0300, Marcelo Tosatti > wrote: >> On Thu, Mar 07, 2013 at 07:57:23AM +0100, Marc Zyngier wrote: >>> On Wed, 6 Mar 2013 20:40:00 -0800, Christoffer Dall >>> >>> wrote: >>> > On Wed, Mar 6, 2013 at 7:54 PM, Marc Zyn

Re: [PATCH v5 4/5] KVM: VMX: Add the algorithm of deliver posted interrupt

2013-03-08 Thread Marcelo Tosatti
On Fri, Mar 08, 2013 at 09:23:20AM +0800, Yang Zhang wrote: > From: Yang Zhang > > Only deliver the posted interrupt when target vcpu is running > and there is no previous interrupt pending in pir. > > Signed-off-by: Yang Zhang > +static bool vmx_deliver_posted_interrupt(struct kvm_vcpu *vcpu,

Re: [PATCH v5 5/5] KVM : VMX: Use posted interrupt to deliver virtual interrupt

2013-03-08 Thread Marcelo Tosatti
On Fri, Mar 08, 2013 at 09:23:21AM +0800, Yang Zhang wrote: > From: Yang Zhang > > If posted interrupt is avaliable, then uses it to inject virtual > interrupt to guest. > > Signed-off-by: Yang Zhang > --- > arch/x86/kvm/irq.c |2 +- > arch/x86/kvm/lapic.c | 16 +--- > arch

[PATCH] kvm/powerpc/e500mc: fix tlb invalidation on cpu migration

2013-03-08 Thread Scott Wood
The existing check handles the case where we've migrated to a different core than we last ran on, but it doesn't handle the case where we're still on the same cpu we last ran on, but some other vcpu has run on this cpu in the meantime. Without this, guest segfaults (and other misbehavior) have bee

Re: [PATCH] kvm/powerpc/e500mc: fix tlb invalidation on cpu migration

2013-03-08 Thread Alexander Graf
On 08.03.2013, at 21:25, Scott Wood wrote: > The existing check handles the case where we've migrated to a different > core than we last ran on, but it doesn't handle the case where we're > still on the same cpu we last ran on, but some other vcpu has run on > this cpu in the meantime. > > Witho

RE: [PATCH v5 4/5] KVM: VMX: Add the algorithm of deliver posted interrupt

2013-03-08 Thread Zhang, Yang Z
Marcelo Tosatti wrote on 2013-03-09: > On Fri, Mar 08, 2013 at 09:23:20AM +0800, Yang Zhang wrote: >> From: Yang Zhang >> >> Only deliver the posted interrupt when target vcpu is running >> and there is no previous interrupt pending in pir. >> >> Signed-off-by: Yang Zhang >> >> +static bool vm

RE: [PATCH v5 5/5] KVM : VMX: Use posted interrupt to deliver virtual interrupt

2013-03-08 Thread Zhang, Yang Z
Marcelo Tosatti wrote on 2013-03-09: > On Fri, Mar 08, 2013 at 09:23:21AM +0800, Yang Zhang wrote: >> From: Yang Zhang >> >> If posted interrupt is avaliable, then uses it to inject virtual >> interrupt to guest. >> >> Signed-off-by: Yang Zhang >> --- >> arch/x86/kvm/irq.c |2 +- >> arch

Re: [STRAWMAN PATCH] KVM: PPC: Add ioctl to specify interrupt controller architecture to emulate

2013-03-08 Thread Paul Mackerras
On Fri, Mar 08, 2013 at 12:04:30PM +0100, Alexander Graf wrote: > > > Am 08.03.2013 um 11:37 schrieb Paul Mackerras : > > > I have > > used the first argument (cap->args[0]) to specify which interrupt > > controller you want to connect the vcpu to. > > Ah, nice idea. So you basically make the v

[PATCH] x86: kvm: reset the bootstrap processor when it gets an INIT

2013-03-08 Thread Paolo Bonzini
After receiving an INIT signal (either via the local APIC, or through KVM_SET_MP_STATE), the bootstrap processor should reset immediately and start execution at 0xfff0. Also, SIPIs have no effect on the bootstrap processor. However, KVM currently does not differentiate between the BSP and APs

[PATCH uq/master 0/2] CPU reset (INIT#) support for KVM

2013-03-08 Thread Paolo Bonzini
This is a follow up to the series I posted earlier this week to support CPU soft reset. It is a no-op without that series, but it can be applied independently. The combined series is available at branch x86-soft-reset of my github repository (git://github.com/bonzini/qemu.git). With this series

[PATCH uq/master 1/2] kvm: detect errors from kvm_arch_process_async_events

2013-03-08 Thread Paolo Bonzini
The next patch will call a ioctl from kvm_arch_process_async_events. Trap errors and abort the program if one comes. Signed-off-by: Paolo Bonzini --- kvm-all.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/kvm-all.c b/kvm-all.c index 4decfdc..bc1534c 100644 --- a/kvm

[PATCH uq/master 2/2] kvm: forward INIT signals coming from the chipset

2013-03-08 Thread Paolo Bonzini
CPU_INTERRUPT_INIT can also be generated if you have an internal APIC, since the keyboard controller and the southbridge can also pulse the CPU's INIT# pin. Exit the VCPU is one is received, and process it by changing the mp_state to KVM_MP_STATE_INIT_RECEIVED. Signed-off-by: Paolo Bonzini ---

[PATCH v7 1/3] VFIO: Wrapper for getting reference to vfio_device from device

2013-03-08 Thread Vijay Mohan Pandarathil
- Added vfio_device_get_from_dev() as wrapper to get reference to vfio_device from struct device. - Added vfio_device_data() as a wrapper to get device_data from vfio_device. Signed-off-by: Vijay Mohan Pandarathil --- drivers/vfio/vfio.c | 30 +++

[PATCH v7 3/3] QEMU-AER: Qemu changes to support AER for VFIO-PCI devices

2013-03-08 Thread Vijay Mohan Pandarathil
- Create eventfd per vfio device assigned to a guest and register an event handler - This fd is passed to the vfio_pci driver through the SET_IRQ ioctl - When the device encounters an error, the eventfd is signalled and the qemu eventfd handler gets inv

[PATCH v7 0/3] AER-KVM: Error containment of VFIO devices assigned to KVM guests

2013-03-08 Thread Vijay Mohan Pandarathil
Add support for error containment when a VFIO device assigned to a KVM guest encounters an error. This is for PCIe devices/drivers that support AER functionality. When the host OS is notified of an error in a device either through the firmware first approach or through an interrupt handled by the A

[PATCH v7 2/3] VFIO-AER: Vfio-pci driver changes for supporting AER

2013-03-08 Thread Vijay Mohan Pandarathil
- New VFIO_SET_IRQ ioctl option to pass the eventfd that is signaled when an error occurs in the vfio_pci_device - Register pci_error_handler for the vfio_pci driver - When the device encounters an error, the error handler registered by the vfio_pci dr