Re: [RFC V2 PATCH 4/4] virtio-net: add multiqueue support

2012-07-02 Thread Jason Wang
On 07/01/2012 05:43 PM, Michael S. Tsirkin wrote: On Mon, Jun 25, 2012 at 06:04:49PM +0800, Jason Wang wrote: This patch let the virtio-net can transmit and recevie packets through multiuple VLANClientStates and abstract them as multiple virtqueues to guest. A new parameter 'queues' were introdu

Re: qemu-kvm-1.0.1 - unable to exit if vcpu is in infinite loop

2012-07-02 Thread Jan Kiszka
On 2012-07-01 21:18, Peter Lieven wrote: > > Am 01.07.2012 um 10:19 schrieb Avi Kivity: > >> On 06/28/2012 10:27 PM, Peter Lieven wrote: >>> >>> Am 28.06.2012 um 18:32 schrieb Avi Kivity: >>> On 06/28/2012 07:29 PM, Peter Lieven wrote: >> Yes. A signal is sent, and KVM returns from the g

Re: [bug 1.1] -M pc-1.0 + vhost = SIGSEGV

2012-07-02 Thread Jan Kiszka
On 2012-07-01 17:06, Michael Tokarev wrote: > When running current git version of qemu-kvm with -M pc-1.0 Just to clarify: you are talking about stable-1.1 git, not master. > and with vhost-net enabled, it crashes with SIGSEGV right when > linux guest loads a virtio-net module. > > I haven't tri

Re: RFD: virtio balloon API use (was Re: [PATCH 5 of 5] virtio: expose added descriptors immediately)

2012-07-02 Thread Michael S. Tsirkin
On Mon, Jul 02, 2012 at 10:35:47AM +0930, Rusty Russell wrote: > On Sun, 1 Jul 2012 12:20:51 +0300, "Michael S. Tsirkin" > wrote: > > On Thu, Nov 03, 2011 at 06:12:53PM +1030, Rusty Russell wrote: > > > A virtio driver does virtqueue_add_buf() multiple times before finally > > > calling virtqueue

[PATCH RFC] virtio-balloon: fix add/get API use

2012-07-02 Thread Michael S. Tsirkin
In virtio balloon virtqueue_get_buf might now run concurrently with virtqueue_kick. I audited both and this seems safe in practice but this is not guaranteed by the API. Additionally, a spurious interrupt might in theory make virtqueue_get_buf run in parallel with virtqueue_add_buf, which is racy.

[PATCH stable-1.1] qemu-kvm: Add missing default machine options

2012-07-02 Thread Jan Kiszka
qemu-kvm-specific machine defaults were missing for pc-0.15 and pc-1.0. Signed-off-by: Jan Kiszka --- hw/pc_piix.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/hw/pc_piix.c b/hw/pc_piix.c index c3fb74e..4e8a280 100644 --- a/hw/pc_piix.c +++ b/hw/pc_piix.c @@ -393,6 +

Re: [RFC V2 PATCH 4/4] virtio-net: add multiqueue support

2012-07-02 Thread Michael S. Tsirkin
On Mon, Jul 02, 2012 at 03:04:00PM +0800, Jason Wang wrote: > On 07/01/2012 05:43 PM, Michael S. Tsirkin wrote: > >On Mon, Jun 25, 2012 at 06:04:49PM +0800, Jason Wang wrote: > >>This patch let the virtio-net can transmit and recevie packets through > >>multiuple > >>VLANClientStates and abstract

[PATCH stable-1.1] qemu-kvm: virtio: Do not register mask notifiers without in-kernel irqchip support

2012-07-02 Thread Jan Kiszka
We crash if we registers mask notifiers without backing in-kernel irqchip. This corresponds to the check in QEMU upstream after 1.1 now. Signed-off-by: Jan Kiszka --- Not needed for master as we have upstream logic there already. hw/virtio-pci.c |4 ++-- 1 files changed, 2 insertions(+), 2

Re: qemu-kvm-1.0.1 - unable to exit if vcpu is in infinite loop

2012-07-02 Thread Peter Lieven
On 02.07.2012 09:05, Jan Kiszka wrote: On 2012-07-01 21:18, Peter Lieven wrote: Am 01.07.2012 um 10:19 schrieb Avi Kivity: On 06/28/2012 10:27 PM, Peter Lieven wrote: Am 28.06.2012 um 18:32 schrieb Avi Kivity: On 06/28/2012 07:29 PM, Peter Lieven wrote: Yes. A signal is sent, and KVM retur

[PATCH 0/8] KVM: Optimize MMU notifier's THP page invalidation -v4

2012-07-02 Thread Takuya Yoshikawa
v3->v4: Resolved trace_kvm_age_page() issue -- patch 6,7 v2->v3: Fixed intersection calculations. -- patch 3, 8 Takuya Takuya Yoshikawa (8): KVM: MMU: Use __gfn_to_rmap() to clean up kvm_handle_hva() KVM: Introduce hva_to_gfn_memslot() for kvm_handle_hva() KVM: MMU: Make kvm_handle_

[PATCH 1/8] KVM: MMU: Use __gfn_to_rmap() to clean up kvm_handle_hva()

2012-07-02 Thread Takuya Yoshikawa
We can treat every level uniformly. Signed-off-by: Takuya Yoshikawa --- arch/x86/kvm/mmu.c | 12 ++-- 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index 3b53d9e..d3e7e6a 100644 --- a/arch/x86/kvm/mmu.c +++ b/arch/x86/kvm/mmu.c @

[PATCH 2/8] KVM: Introduce hva_to_gfn_memslot() for kvm_handle_hva()

2012-07-02 Thread Takuya Yoshikawa
This restricts hva handling in mmu code and makes it easier to extend kvm_handle_hva() so that it can treat a range of addresses later in this patch series. Signed-off-by: Takuya Yoshikawa Cc: Alexander Graf Cc: Paul Mackerras --- arch/powerpc/kvm/book3s_64_mmu_hv.c |6 +++--- arch/x86/kvm

[PATCH 3/8] KVM: MMU: Make kvm_handle_hva() handle range of addresses

2012-07-02 Thread Takuya Yoshikawa
When guest's memory is backed by THP pages, MMU notifier needs to call kvm_unmap_hva(), which in turn leads to kvm_handle_hva(), in a loop to invalidate a range of pages which constitute one huge page: for each page for each memslot if page is in memslot unmap using rmap This

[PATCH 4/8] KVM: Introduce kvm_unmap_hva_range() for kvm_mmu_notifier_invalidate_range_start()

2012-07-02 Thread Takuya Yoshikawa
When we tested KVM under memory pressure, with THP enabled on the host, we noticed that MMU notifier took a long time to invalidate huge pages. Since the invalidation was done with mmu_lock held, it not only wasted the CPU but also made the host harder to respond. This patch mitigates this by usi

[PATCH 5/8] KVM: Separate rmap_pde from kvm_lpage_info->write_count

2012-07-02 Thread Takuya Yoshikawa
This makes it possible to loop over rmap_pde arrays in the same way as we do over rmap so that we can optimize kvm_handle_hva_range() easily in the following patch. Signed-off-by: Takuya Yoshikawa --- arch/x86/include/asm/kvm_host.h |2 +- arch/x86/kvm/mmu.c |6 +++--- arch/

[PATCH 6/8] KVM: MMU: Add memslot parameter to hva handlers

2012-07-02 Thread Takuya Yoshikawa
This is needed to push trace_kvm_age_page() into kvm_age_rmapp() in the following patch. Signed-off-by: Takuya Yoshikawa --- arch/x86/kvm/mmu.c | 16 +--- 1 files changed, 9 insertions(+), 7 deletions(-) diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c index f2c408a..bf8d50e 1

[PATCH 7/8] KVM: MMU: Push trace_kvm_age_page() into kvm_age_rmapp()

2012-07-02 Thread Takuya Yoshikawa
This restricts the tracing to page aging and makes it possible to optimize kvm_handle_hva_range() further in the following patch. Signed-off-by: Takuya Yoshikawa --- arch/x86/kvm/mmu.c | 23 ++- 1 files changed, 10 insertions(+), 13 deletions(-) diff --git a/arch/x86/kvm/m

Re: [PATCH v4] KVM: x86: Implement PCID/INVPCID for guests with EPT

2012-07-02 Thread Avi Kivity
On 07/02/2012 03:32 AM, Mao, Junjie wrote: >> > I think this means I can replace the code here with a check in >> nested_vmx_run. Do I understand correctly? >> >> Correct, but the check already exists: >> if (!vmx_control_verify(vmcs12->cpu_based_vm_exec_control, >> nested_vmx_procba

[PATCH 8/8] KVM: MMU: Avoid handling same rmap_pde in kvm_handle_hva_range()

2012-07-02 Thread Takuya Yoshikawa
When we invalidate a THP page, we call the handler with the same rmap_pde argument 512 times in the following loop: for each guest page in the range for each level unmap using rmap This patch avoids these extra handler calls by changing the loop order like this: for each level

Re: [PATCH v3 2/7] memory: Flush coalesced MMIO on selected region access

2012-07-02 Thread Avi Kivity
On 06/29/2012 07:37 PM, Jan Kiszka wrote: > Instead of flushing pending coalesced MMIO requests on every vmexit, > this provides a mechanism to selectively flush when memory regions > related to the coalesced one are accessed. This first of all includes > the coalesced region itself but can also ap

Re: [PATCH v3 2/7] memory: Flush coalesced MMIO on selected region access

2012-07-02 Thread Avi Kivity
On 07/02/2012 12:07 PM, Avi Kivity wrote: > > Reviewed-by: Avi Kivity (for the entire patchset) -- error compiling committee.c: too many arguments to function -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordo

Re: [PATCH 0/8] KVM: Optimize MMU notifier's THP page invalidation -v4

2012-07-02 Thread Avi Kivity
On 07/02/2012 11:52 AM, Takuya Yoshikawa wrote: > v3->v4: Resolved trace_kvm_age_page() issue -- patch 6,7 > v2->v3: Fixed intersection calculations. -- patch 3, 8 > > Takuya > > Takuya Yoshikawa (8): > KVM: MMU: Use __gfn_to_rmap() to clean up kvm_handle_hva() > KVM: Introduce hva_to_g

Re: [PATCH stable-1.1] qemu-kvm: virtio: Do not register mask notifiers without in-kernel irqchip support

2012-07-02 Thread Michael S. Tsirkin
On Mon, Jul 02, 2012 at 10:05:39AM +0200, Jan Kiszka wrote: > We crash if we registers mask notifiers without backing in-kernel > irqchip. This corresponds to the check in QEMU upstream after 1.1 now. > > Signed-off-by: Jan Kiszka Acked-by: Michael S. Tsirkin > --- > > Not needed for master a

plan for device assignment upstream

2012-07-02 Thread Michael S. Tsirkin
I've been thinking hard about Jan's patches for device assignment. Basically while I thought it makes sense to make all devices: assignment and not - behave the same and use same APIs for injecting irqs, Anthony thinks there is huge value in making irq propagation hierarchical and device assignment

Re: plan for device assignment upstream

2012-07-02 Thread Avi Kivity
On 07/02/2012 12:18 PM, Michael S. Tsirkin wrote: > I've been thinking hard about Jan's patches for device > assignment. Basically while I thought it makes sense > to make all devices: assignment and not - behave the > same and use same APIs for injecting irqs, Anthony thinks there is huge > value

Re: [bug 1.1] -M pc-1.0 + vhost = SIGSEGV

2012-07-02 Thread Michael Tokarev
02.07.2012 11:20, Jan Kiszka wrote: > On 2012-07-01 17:06, Michael Tokarev wrote: >> When running current git version of qemu-kvm with -M pc-1.0 > > Just to clarify: you are talking about stable-1.1 git, not master. Yes, as the $Subject (partially) says. [] >> So it looks like msix isn't initial

Re: plan for device assignment upstream

2012-07-02 Thread Jan Kiszka
On 2012-07-02 11:18, Michael S. Tsirkin wrote: > I've been thinking hard about Jan's patches for device > assignment. Basically while I thought it makes sense > to make all devices: assignment and not - behave the > same and use same APIs for injecting irqs, Anthony thinks there is huge > value in

Re: plan for device assignment upstream

2012-07-02 Thread Avi Kivity
On 07/02/2012 12:30 PM, Jan Kiszka wrote: > On 2012-07-02 11:18, Michael S. Tsirkin wrote: >> I've been thinking hard about Jan's patches for device >> assignment. Basically while I thought it makes sense >> to make all devices: assignment and not - behave the >> same and use same APIs for injectin

Re: [PATCH 0/6] kvm/s390: sigp related changes for 3.6

2012-07-02 Thread Martin Schwidefsky
On Fri, 29 Jun 2012 20:19:46 -0300 Marcelo Tosatti wrote: > On Tue, Jun 26, 2012 at 04:06:35PM +0200, Cornelia Huck wrote: > > Avi, Marcelo, > > > > here are some more s390 patches for the next release. > > > > Patches 1 and 2 are included for dependency reasons; they will also > > be sent thro

KVM call agenda for Tuesday, July 3rd

2012-07-02 Thread Juan Quintela
Hi Please send in any agenda items you are interested in covering. Later, Juan. -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[RFC PATCH] Expose tsc deadline timer feature to guest

2012-07-02 Thread Liu, Jinsong
Eduardo, Jan, Andreas As we sync 3 months ago, I wait until qemu1.1 done, then re-write patch based on qemu1.1. Now it's time to re-write my patch based on qemu1.1. Attached is a RFC patch for exposing tsc deadline timer to guest. I have checked current qemu1.1 code, and read some emails regardi

Re: [RFC PATCH] Expose tsc deadline timer feature to guest

2012-07-02 Thread Andreas Färber
Am 02.07.2012 13:08, schrieb Liu, Jinsong: > Eduardo, Jan, Andreas > > As we sync 3 months ago, I wait until qemu1.1 done, then re-write patch based > on qemu1.1. > Now it's time to re-write my patch based on qemu1.1. > > Attached is a RFC patch for exposing tsc deadline timer to guest. > I have

Re: [PATCH v2 3/5] KVM: Flush TLB in mmu notifier without holding mmu_lock

2012-07-02 Thread Avi Kivity
Revisiting after hiatus. On 05/21/2012 11:58 PM, Marcelo Tosatti wrote: > On Thu, May 17, 2012 at 01:24:42PM +0300, Avi Kivity wrote: >> Signed-off-by: Avi Kivity >> --- >> virt/kvm/kvm_main.c | 16 >> 1 file changed, 8 insertions(+), 8 deletions(-) >> >> diff --git a/virt/kv

Re: [PATCH v11 4/8] KVM: PPC: Add support for ePAPR idle hcall in host kernel

2012-07-02 Thread Alexander Graf
On 22.06.2012, at 22:04, Stuart Yoder wrote: > From: Liu Yu-B13201 > > 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 > [stuart.yo...@freescale.com: cleanup,fixes for conditions allowing idle] > Signed-off-b

Re: [PATCH v11 5/8] KVM: PPC: ev_idle hcall support for e500 guests

2012-07-02 Thread Alexander Graf
On 22.06.2012, at 22:04, Stuart Yoder wrote: > From: Liu Yu-B13201 > > Signed-off-by: Liu Yu > [varun: 64-bit changes] > Signed-off-by: Varun Sethi > Signed-off-by: Stuart Yoder > --- > -v11: > -added comment about origin of idle instruction sequence > -update for 64-bit support found in

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Alexander Graf
On 22.06.2012, at 22:06, Stuart Yoder wrote: > From: Liu Yu-B13201 > > Signed-off-by: Liu Yu > Signed-off-by: Stuart Yoder > --- > -v11: no changes > > arch/powerpc/include/asm/epapr_hcalls.h | 22 +- > arch/powerpc/include/asm/fsl_hcalls.h | 36 +++--

Re: [PATCH v2 3/5] KVM: Flush TLB in mmu notifier without holding mmu_lock

2012-07-02 Thread Avi Kivity
On 07/02/2012 03:05 PM, Avi Kivity wrote: > We need something for lockbreaking too: > >def mmu_lockbreak(): >if not (contended or need_resched): >return False >remember flush counter >cond_resched_lock >return flush counter changed > > The caller wo

Re: [PATCH v8 11/15] ARM: KVM: World-switch implementation

2012-07-02 Thread Avi Kivity
On 06/21/2012 08:54 PM, Christoffer Dall wrote: >>> @@ -504,6 +514,13 @@ int kvm_arch_vcpu_ioctl_run(struct kvm_vcpu >>> *vcpu, struct kvm_run *run) >>>*/ >>> preempt_disable(); >>> local_irq_disable(); >>> + >>> + if (check_new_vmid_gen(kvm))

Re: [PATCH v11 5/8] KVM: PPC: ev_idle hcall support for e500 guests

2012-07-02 Thread Benjamin Herrenschmidt
On Mon, 2012-07-02 at 14:20 +0200, Alexander Graf wrote: > > Ben, would you be opposed to a macro that does this? Open-coding > subtile details like this always makes me wary we could screw them > up :) That's definitely material for a macro (and fixup the gazillion places where we do it by hand

[Bug 15298] kernel BUG at /usr/src/packages/BUILD/kernel-desktop-2.6.31.8/linux-2.6.31/mm/slab.c:532!

2012-07-02 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=15298 Alan changed: What|Removed |Added Status|NEW |RESOLVED CC|

Re: [PATCH v11 5/8] KVM: PPC: ev_idle hcall support for e500 guests

2012-07-02 Thread Alexander Graf
On 02.07.2012, at 15:24, Benjamin Herrenschmidt wrote: > On Mon, 2012-07-02 at 14:20 +0200, Alexander Graf wrote: >> >> Ben, would you be opposed to a macro that does this? Open-coding >> subtile details like this always makes me wary we could screw them >> up :) > > That's definitely material

Re: [PATCH] KVM: PPC: bookehv: Add ESR flag to Data Storage Interrupt

2012-07-02 Thread Alexander Graf
On 23.06.2012, at 01:33, Mihai Caraman wrote: > ESR register is required by Data Storage Interrupt handling code. > Add the specific flag to the interrupt handler. > > Signed-off-by: Mihai Caraman Thanks, applied to kvm-ppc-next. Alex -- To unsubscribe from this list: send the line "unsubsc

Re: [Qemu-devel] [PATCH v2 1/3] KVM: Add new -cpu best

2012-07-02 Thread Alexander Graf
On 26.06.2012, at 18:39, Alexander Graf wrote: > During discussions on whether to make -cpu host the default in SLE, I found > myself disagreeing to the thought, because it potentially opens a big can > of worms for potential bugs. But if I already am so opposed to it for SLE, how > can it possib

Re: [PATCH v2 3/5] KVM: Flush TLB in mmu notifier without holding mmu_lock

2012-07-02 Thread Takuya Yoshikawa
On Mon, 02 Jul 2012 15:41:30 +0300 Avi Kivity wrote: > kvm_mmu_slot_remove_write_access: same. It's hard to continue the loop > after a lockbreak though. We can switch it to be rmap based instead. Switching to rmap based protection was on my queue before, but I wanted to do that after your wor

Re: [PATCH v2 3/5] KVM: Flush TLB in mmu notifier without holding mmu_lock

2012-07-02 Thread Avi Kivity
On 07/02/2012 05:09 PM, Takuya Yoshikawa wrote: > On Mon, 02 Jul 2012 15:41:30 +0300 > Avi Kivity wrote: > >> kvm_mmu_slot_remove_write_access: same. It's hard to continue the loop >> after a lockbreak though. We can switch it to be rmap based instead. > > Switching to rmap based protection wa

Re: [Qemu-devel] [PATCH v2 1/3] KVM: Add new -cpu best

2012-07-02 Thread Andreas Färber
Am 26.06.2012 18:39, schrieb Alexander Graf: > During discussions on whether to make -cpu host the default in SLE, I found s/make -cpu host the default/support/? > myself disagreeing to the thought, because it potentially opens a big can > of worms for potential bugs. But if I already am so oppos

Re: [PATCH v2 1/3] KVM: Add new -cpu best

2012-07-02 Thread Avi Kivity
On 06/26/2012 07:39 PM, Alexander Graf wrote: > During discussions on whether to make -cpu host the default in SLE, I found > myself disagreeing to the thought, because it potentially opens a big can > of worms for potential bugs. But if I already am so opposed to it for SLE, how > can it possibly

Re: [PATCH v2 2/3] KVM: Use -cpu best as default on x86

2012-07-02 Thread Avi Kivity
On 06/26/2012 07:39 PM, Alexander Graf wrote: > When running QEMU without -cpu parameter, the user usually wants a sane > default. So far, we're using the qemu64/qemu32 CPU type, which basically > means "the maximum TCG can emulate". > > That's a really good default when using TCG, but when runnin

Re: [PATCH] kvm: handle last_boosted_vcpu = 0 case

2012-07-02 Thread Rik van Riel
On 06/28/2012 06:55 PM, Vinod, Chegu wrote: Hello, I am just catching up on this email thread... Perhaps one of you may be able to help answer this query.. preferably along with some data. [BTW, I do understand the basic intent behind PLE in a typical [sweet spot] use case where there is ove

Re: race between kvm-kmod-3.0 and kvm-kmod-3.3 // was: race condition in qemu-kvm-1.0.1

2012-07-02 Thread Avi Kivity
On 06/28/2012 12:38 PM, Peter Lieven wrote: > does anyone know whats that here in handle_mmio? > > /* hack: Red Hat 7.1 generates these weird accesses. */ > if ((addr > 0xa-4 && addr <= 0xa) && kvm_run->mmio.len == 3) > return 0; > Just what it says. There is a 4-byte ac

Re: [PATCH v3 3/3] kvm: Sanitize KVM_IRQFD flags

2012-07-02 Thread Alex Williamson
On Sun, 2012-07-01 at 11:26 +0300, Michael S. Tsirkin wrote: > On Fri, Jun 29, 2012 at 09:56:24AM -0600, Alex Williamson wrote: > > We only know of one so far. > > > > Signed-off-by: Alex Williamson > > BTW should we sanitize padding as well? I imagine that to make use of a field in the padding

Re: [PATCH v3 0/3] kvm: KVM_IRQFD cleanup, docs, sanitize flags

2012-07-02 Thread Alex Williamson
On Fri, 2012-06-29 at 09:56 -0600, Alex Williamson wrote: > Before we start fiddling with what we can and can't add to KVM_IRQFD > we need to figure out if anyone has been sloppy in their use of the > ioctl flags. This series has a minor cleanup to pass the struct > kvm_irqfd to seup functions rat

Re: [PATCH v3 0/3] kvm: KVM_IRQFD cleanup, docs, sanitize flags

2012-07-02 Thread Avi Kivity
On 07/02/2012 06:51 PM, Alex Williamson wrote: > On Fri, 2012-06-29 at 09:56 -0600, Alex Williamson wrote: >> Before we start fiddling with what we can and can't add to KVM_IRQFD >> we need to figure out if anyone has been sloppy in their use of the >> ioctl flags. This series has a minor cleanup

Re: race between kvm-kmod-3.0 and kvm-kmod-3.3 // was: race condition in qemu-kvm-1.0.1

2012-07-02 Thread Peter Lieven
On 02.07.2012 17:05, Avi Kivity wrote: On 06/28/2012 12:38 PM, Peter Lieven wrote: does anyone know whats that here in handle_mmio? /* hack: Red Hat 7.1 generates these weird accesses. */ if ((addr> 0xa-4&& addr<= 0xa)&& kvm_run->mmio.len == 3) return 0; Just wha

Re: RFD: virtio balloon API use (was Re: [PATCH 5 of 5] virtio: expose added descriptors immediately)

2012-07-02 Thread Rafael Aquini
On Mon, Jul 02, 2012 at 10:25:58AM +0300, Michael S. Tsirkin wrote: > On Mon, Jul 02, 2012 at 10:35:47AM +0930, Rusty Russell wrote: > > On Sun, 1 Jul 2012 12:20:51 +0300, "Michael S. Tsirkin" > > wrote: > > > On Thu, Nov 03, 2011 at 06:12:53PM +1030, Rusty Russell wrote: > > > > A virtio driver

Re: [PATCHv3 RFC 0/2] kvm: direct msix injection

2012-07-02 Thread Alex Williamson
On Mon, 2012-06-25 at 11:32 +0200, Jan Kiszka wrote: > On 2012-06-11 13:19, Michael S. Tsirkin wrote: > > We can deliver certain interrupts, notably MSIX, > > from atomic context. > > Here's an untested patch to do this (compiled only). > > > > Changes from v2: > > Don't inject broadcast interrupt

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Alexander Graf
On 02.07.2012, at 19:10, Scott Wood wrote: > On 07/02/2012 07:30 AM, Alexander Graf wrote: >> >> On 22.06.2012, at 22:06, Stuart Yoder wrote: >> >>> From: Liu Yu-B13201 >>> >>> Signed-off-by: Liu Yu >>> Signed-off-by: Stuart Yoder >>> --- >>> -v11: no changes >>> >>> arch/powerpc/include/a

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Scott Wood
On 07/02/2012 12:13 PM, Alexander Graf wrote: > > On 02.07.2012, at 19:10, Scott Wood wrote: > >> On 07/02/2012 07:30 AM, Alexander Graf wrote: >>> >>> On 22.06.2012, at 22:06, Stuart Yoder wrote: >>> From: Liu Yu-B13201 Signed-off-by: Liu Yu Signed-off-by: Stuart Yoder >>>

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Alexander Graf
On 02.07.2012, at 19:16, Scott Wood wrote: > On 07/02/2012 12:13 PM, Alexander Graf wrote: >> >> On 02.07.2012, at 19:10, Scott Wood wrote: >> >>> On 07/02/2012 07:30 AM, Alexander Graf wrote: On 22.06.2012, at 22:06, Stuart Yoder wrote: > From: Liu Yu-B13201 > >

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Scott Wood
On 07/02/2012 12:17 PM, Alexander Graf wrote: > > On 02.07.2012, at 19:16, Scott Wood wrote: > >> On 07/02/2012 12:13 PM, Alexander Graf wrote: >>> >>> On 02.07.2012, at 19:10, Scott Wood wrote: >>> On 07/02/2012 07:30 AM, Alexander Graf wrote: > > On 22.06.2012, at 22:06, Stuart Yod

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Scott Wood
On 07/02/2012 07:30 AM, Alexander Graf wrote: > > On 22.06.2012, at 22:06, Stuart Yoder wrote: > >> From: Liu Yu-B13201 >> >> Signed-off-by: Liu Yu >> Signed-off-by: Stuart Yoder >> --- >> -v11: no changes >> >> arch/powerpc/include/asm/epapr_hcalls.h | 22 +- >> arch/powerpc/

Re: [Qemu-devel] KVM call agenda for Tuesday, July 3rd

2012-07-02 Thread Eric Blake
On 07/02/2012 04:16 AM, Juan Quintela wrote: > > Hi > > Please send in any agenda items you are interested in covering. Can we discuss the future of 'getfd', the possibility of 'pass-fd', or even the enhancement of all existing monitor commands to take an optional 'nfds' JSON argument for atomic

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Timur Tabi
Scott Wood wrote: > Hmm. The comment says, "XER, CTR, and LR are currently listed as > clobbers because it's uncertain whether they will be clobbered." Maybe > it dates back to when the ABI was still being discussed? Timur, do you > recall? Nope, sorry. I'm sure we discussed this and looked a

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Scott Wood
On 07/02/2012 12:34 PM, Timur Tabi wrote: > Scott Wood wrote: > >> Hmm. The comment says, "XER, CTR, and LR are currently listed as >> clobbers because it's uncertain whether they will be clobbered." Maybe >> it dates back to when the ABI was still being discussed? Timur, do you >> recall? > >

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Timur Tabi
Scott Wood wrote: >> > I'm still a little confused. Which inline assembly code is clobbering LR? >> > Are you talking about the "BL" instruction, which wasn't there before? > Yes, I didn't realize that LR had been in the clobber list before that. So are you saying that it was wrong before, but

Re: [RFC PATCH] Expose tsc deadline timer feature to guest

2012-07-02 Thread Eduardo Habkost
On Mon, Jul 02, 2012 at 11:08:14AM +, Liu, Jinsong wrote: > Eduardo, Jan, Andreas > > As we sync 3 months ago, I wait until qemu1.1 done, then re-write patch based > on qemu1.1. > Now it's time to re-write my patch based on qemu1.1. > > Attached is a RFC patch for exposing tsc deadline timer

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Scott Wood
On 07/02/2012 12:53 PM, Timur Tabi wrote: > Scott Wood wrote: I'm still a little confused. Which inline assembly code is clobbering LR? Are you talking about the "BL" instruction, which wasn't there before? > >> Yes, I didn't realize that LR had been in the clobber list before that. >

Re: [PATCH v11 8/8] PPC: Don't use hardcoded opcode for ePAPR hcall invocation

2012-07-02 Thread Timur Tabi
Scott Wood wrote: >> > So are you saying that it was wrong before, but it's correct now? > Not really *wrong* before, but unnecessary. In that case, my code was really just ahead of its time. :-) -- Timur Tabi Linux kernel developer at Freescale -- To unsubscribe from this list: send the line

[PATCH 1/6] file_ram_alloc(): coding style fixes

2012-07-02 Thread Eduardo Habkost
Cc: Blue Swirl Signed-off-by: Eduardo Habkost --- exec.c |5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/exec.c b/exec.c index 8244d54..c8bfd27 100644 --- a/exec.c +++ b/exec.c @@ -2392,7 +2392,7 @@ static void *file_ram_alloc(RAMBlock *block, unlink(filename);

[RFC PATCH 6/6] add -keep-mem-path-files option (v2)

2012-07-02 Thread Eduardo Habkost
This make QEMU create files inside the -mem-path directory using more predictable names, and not remove them afterwards. This allow (for example) users or management layers to use numactl later, to set NUMA policy for the guest RAM. Changes v1 -> v2: - Fix trailing space issue - Coding style ch

[PATCH 2/6] file_ram_alloc(): use g_strdup_printf() instead of asprintf()

2012-07-02 Thread Eduardo Habkost
Cc: Blue Swirl Signed-off-by: Eduardo Habkost --- exec.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/exec.c b/exec.c index c8bfd27..d856325 100644 --- a/exec.c +++ b/exec.c @@ -24,6 +24,9 @@ #include #endif +#include +#include + #include "qemu-com

[RFC PATCH 0/6] option to not remove files inside -mem-path dir (v2)

2012-07-02 Thread Eduardo Habkost
Resending series, after fixing some coding style issues. Does anybody has any feedback about this proposal? Changes v1 -> v2: - Coding style fixes Original cover letter: I was investigating if there are any mechanisms that allow manually pinning of guest RAM to specific host NUMA nodes, in the

[PATCH 4/6] file_ram_alloc: change length argument to size_t (v2)

2012-07-02 Thread Eduardo Habkost
While we are at it, rename it to "length", as "memory" doesn't mean anything. Changes v1 -> v2: - Rebase after coding style changes Signed-off-by: Eduardo Habkost --- exec.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/exec.c b/exec.c index d856325..1e9824

[PATCH 3/6] vl.c: change mem_prealloc to bool (v2)

2012-07-02 Thread Eduardo Habkost
Changes v1 -> v2: - Do not initialize variable to false, to make checkpatch.pl happy Signed-off-by: Eduardo Habkost --- cpu-all.h |2 +- vl.c |4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cpu-all.h b/cpu-all.h index 9dc249a..2beed5a 100644 --- a/cpu-all.h

[PATCH 5/6] file_ram_alloc(): extract temporary-file creation code to separate function (v2)

2012-07-02 Thread Eduardo Habkost
Changes v1 -> v2: - Fix trailing space issue - Rebase against new code using g_strdup_printf() Signed-off-by: Eduardo Habkost --- exec.c | 29 ++--- 1 file changed, 22 insertions(+), 7 deletions(-) diff --git a/exec.c b/exec.c index 1e98244..456ac73 100644 --- a/exec

Re: [RFC PATCH 0/6] option to not remove files inside -mem-path dir (v2)

2012-07-02 Thread Daniel P. Berrange
On Mon, Jul 02, 2012 at 03:06:32PM -0300, Eduardo Habkost wrote: > Resending series, after fixing some coding style issues. Does anybody has any > feedback about this proposal? > > Changes v1 -> v2: > - Coding style fixes > > Original cover letter: > > I was investigating if there are any mecha

Re: [RFC PATCH 0/6] option to not remove files inside -mem-path dir (v2)

2012-07-02 Thread Eduardo Habkost
On Mon, Jul 02, 2012 at 07:56:58PM +0100, Daniel P. Berrange wrote: > On Mon, Jul 02, 2012 at 03:06:32PM -0300, Eduardo Habkost wrote: > > Resending series, after fixing some coding style issues. Does anybody has > > any > > feedback about this proposal? > > > > Changes v1 -> v2: > > - Coding st

First shot at adding IPMI to qemu

2012-07-02 Thread minyard
I had asked about getting an IPMI device into qemu and received some interest, and it's useful to me, so I've done some work to add it. The following patch set has a set of patches to add an IPMI KCS device, and IPMI BT device, a built-in BMC (IPMI management controller), and a way to attach an ext

[PATCH 3/9] isa: Add a way to query for a free interrupt

2012-07-02 Thread minyard
From: Corey Minyard This lets devices that don't care about their interrupt number, like IPMI, just grab any unused interrupt. Signed-off-by: Corey Minyard --- hw/isa-bus.c | 13 + hw/isa.h |2 ++ 2 files changed, 15 insertions(+), 0 deletions(-) diff --git a/hw/isa-bus.

[PATCH 5/9] IPMI: Add a PC ISA type structure

2012-07-02 Thread minyard
From: Corey Minyard This provides the base infrastructure to tie IPMI low-level interfaces into a PC ISA bus. Signed-off-by: Corey Minyard --- default-configs/i386-softmmu.mak |1 + default-configs/x86_64-softmmu.mak |1 + hw/Makefile.objs |1 + hw/isa_ipmi.c

[PATCH 9/9] IPMI: Add an external connection simulation interface

2012-07-02 Thread minyard
From: Corey Minyard This adds an interface for IPMI that connects to a remote BMC over a chardev (generally a TCP socket). The OpenIPMI lanserv simulator describes this interface, see that for interface details. Signed-off-by: Corey Minyard --- default-configs/i386-softmmu.mak |1 + def

[PATCH 1/9] smbios: Add a function to directly add an entry

2012-07-02 Thread minyard
From: Corey Minyard There was no way to directly add a table entry to the SMBIOS table, even though the BIOS supports this. So add a function to do this. This is in preparation for the IPMI handler adding it's SMBIOS table entry. Signed-off-by: Corey Minyard --- hw/smbios.c | 27 +++

[PATCH 8/9] IPMI: Add a local BMC simulation

2012-07-02 Thread minyard
From: Corey Minyard This provides a minimal local BMC, basically enough to comply with the spec and provide a complete watchdog timer (including a sensor, SDR, and event). Signed-off-by: Corey Minyard --- default-configs/i386-softmmu.mak |1 + default-configs/x86_64-softmmu.mak |1 +

[PATCH 4/9] Add a base IPMI interface

2012-07-02 Thread minyard
From: Corey Minyard Add the basic IPMI types and infrastructure to QEMU. Low-level interfaces and simulation interfaces will register with this; it's kind of the go-between to tie them together. Signed-off-by: Corey Minyard --- default-configs/i386-softmmu.mak |1 + default-configs/x86_

[PATCH 7/9] IPMI: Add a BT low-level interface

2012-07-02 Thread minyard
From: Corey Minyard This provides the simulation of the BT hardware interface for IPMI. Signed-off-by: Corey Minyard --- default-configs/i386-softmmu.mak |1 + default-configs/x86_64-softmmu.mak |1 + hw/Makefile.objs |1 + hw/ipmi_bt.c |

[PATCH 2/9] pc: move SMBIOS setup to after device init

2012-07-02 Thread minyard
From: Corey Minyard Setting up the firmware interface for the SMBIOS table needs to be done later in the process, after device initialization, so that devices can add entries to the table. Signed-off-by: Corey Minyard --- hw/pc.c | 22 +- hw/pc.h |9 +---

[PATCH 6/9] IPMI: Add a KCS low-level interface

2012-07-02 Thread minyard
From: Corey Minyard This provides the simulation of the KCS hardware interface. Signed-off-by: Corey Minyard --- default-configs/i386-softmmu.mak |1 + default-configs/x86_64-softmmu.mak |1 + hw/Makefile.objs |1 + hw/ipmi_kcs.c | 259

Re: [PATCH 3/3] virtio-blk: Add bio-based IO path for virtio-blk

2012-07-02 Thread Rusty Russell
On Mon, 02 Jul 2012 10:45:05 +0800, Asias He wrote: > On 07/02/2012 07:54 AM, Rusty Russell wrote: > > Confused. So, without merging we get 6k exits (per second?) How many > > do we get when we use the request-based IO path? > > Sorry for the confusion. The numbers were collected from request-b

Re: [PATCH 0/6] kvm/s390: sigp related changes for 3.6

2012-07-02 Thread Marcelo Tosatti
On Tue, Jun 26, 2012 at 04:06:35PM +0200, Cornelia Huck wrote: > Avi, Marcelo, > > here are some more s390 patches for the next release. > > Patches 1 and 2 are included for dependency reasons; they will also > be sent through Martin's s390 tree. > > The other patches fix several problems in our

[ANNOUNCE] qemu-kvm-1.1.0

2012-07-02 Thread Marcelo Tosatti
qemu-kvm-1.1.0 is now available. This release is based on the upstream qemu 1.1.0, plus kvm-specific enhancements. Please see the original QEMU 1.1.0 release announcement [1] for details. This release can be used with the kvm kernel modules provided by your distribution kernel, or by the modules

Re: [PATCH 3/3] virtio-blk: Add bio-based IO path for virtio-blk

2012-07-02 Thread Asias He
On 07/02/2012 02:41 PM, Rusty Russell wrote: On Mon, 02 Jul 2012 10:45:05 +0800, Asias He wrote: On 07/02/2012 07:54 AM, Rusty Russell wrote: Confused. So, without merging we get 6k exits (per second?) How many do we get when we use the request-based IO path? Sorry for the confusion. The n

Re: [PATCH v3 0/3] kvm: KVM_IRQFD cleanup, docs, sanitize flags

2012-07-02 Thread Marcelo Tosatti
On Mon, Jul 02, 2012 at 06:52:46PM +0300, Avi Kivity wrote: > On 07/02/2012 06:51 PM, Alex Williamson wrote: > > On Fri, 2012-06-29 at 09:56 -0600, Alex Williamson wrote: > >> Before we start fiddling with what we can and can't add to KVM_IRQFD > >> we need to figure out if anyone has been sloppy i

Re: [PATCH] kvm: handle last_boosted_vcpu = 0 case

2012-07-02 Thread Raghavendra K T
On 07/02/2012 08:19 PM, Rik van Riel wrote: On 06/28/2012 06:55 PM, Vinod, Chegu wrote: Hello, I am just catching up on this email thread... Perhaps one of you may be able to help answer this query.. preferably along with some data. [BTW, I do understand the basic intent behind PLE in a typica

Re: KVM call agenda for Tuesday, July 3rd

2012-07-02 Thread 王永博
does KVM have the function like vmsafe to develop security software for Virtualization 。 2012/7/2 Juan Quintela : > > Hi > > Please send in any agenda items you are interested in covering. > > Later, Juan. > -- > To unsubscribe from this list: send the line "unsubscribe kvm" in > the body of a me

Re: RFD: virtio balloon API use (was Re: [PATCH 5 of 5] virtio: expose added descriptors immediately)

2012-07-02 Thread Rusty Russell
On Mon, 2 Jul 2012 13:08:19 -0300, Rafael Aquini wrote: > As 'locking in balloon', may I assume the approach I took for the compaction > case > is OK and aligned to address these concerns of yours? If not, do not hesitate > in > giving me your thoughts, please. I'm respinning a V3 series to addr

Re: [PATCH 5/6 v5] deal with guest panicked event accoring to -onpanic parameter

2012-07-02 Thread Wen Congyang
At 06/28/2012 04:26 PM, Jan Kiszka Wrote: > On 2012-06-28 03:15, Wen Congyang wrote: >> At 06/27/2012 10:39 PM, Jan Kiszka Wrote: >>> On 2012-06-27 09:02, Wen Congyang wrote: When the guest is panicked, it will write 0x1 to the port KVM_PV_PORT. So if qemu reads 0x1 from this port, we can

[PATCH] mm: mmu_notifier: fix freed page still mapped in secondary MMU

2012-07-02 Thread Xiao Guangrong
mmu_notifier_release is called when the process is exiting, it will delete all the mmu notifiers, but, in this time, the page belonged to the process is still present at the page table and listed in the LRU list, so this race will happen: CPU 0 CPU 1 mmu_notifier_release:

[PATCH 1/3] KVM: fix fault page leak

2012-07-02 Thread Xiao Guangrong
fault_page is forgot to be freed Signed-off-by: Xiao Guangrong --- virt/kvm/kvm_main.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c index 02cb440..157226d 100644 --- a/virt/kvm/kvm_main.c +++ b/virt/kvm/kvm_main.c @@ -2857,6 +

[PATCH 2/3] KVM: MMU: fix shrinking page from the empty mmu

2012-07-02 Thread Xiao Guangrong
Fix: [ 3190.059226] BUG: unable to handle kernel NULL pointer dereference at (null) [ 3190.062224] IP: [] mmu_page_zap_pte+0x10/0xa7 [kvm] [ 3190.063760] PGD 104f50067 PUD 112bea067 PMD 0 [ 3190.065309] Oops: [#1] SMP DEBUG_PAGEALLOC [ 3190.066860] CPU 1 [ .. ] [ 3190.109

[PATCH 3/3] KVM: MMU: track the refcount when unmap the page

2012-07-02 Thread Xiao Guangrong
It will trigger a WARN_ON if the page has been freed but it is still used in mmu, it can help us to detect mm bug early Signed-off-by: Xiao Guangrong --- arch/x86/kvm/mmu.c |8 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c ind

  1   2   >