Re: Re:[PATCH v14 06/17] Use callback to deal with skb_release_data() specially.

2010-11-08 Thread Eric Dumazet
Le lundi 08 novembre 2010 à 16:03 +0800, xiaohui@intel.com a écrit : > From: Xin Xiaohui > > >> Hmm, I suggest you read the comment two lines above. > >> > >> If destructor_arg is now cleared each time we allocate a new skb, then, > >> please move it before dataref in shinfo structure, so tha

RE: Re:[PATCH v14 06/17] Use callback to deal with skb_release_data() specially.

2010-11-08 Thread Xin, Xiaohui
>-Original Message- >From: Eric Dumazet [mailto:eric.duma...@gmail.com] >Sent: Monday, November 08, 2010 4:25 PM >To: Xin, Xiaohui >Cc: net...@vger.kernel.org; kvm@vger.kernel.org; linux-ker...@vger.kernel.org; >m...@redhat.com; mi...@elte.hu; da...@davemloft.net; >herb...@gondor.apana.org

[kvm.git & 2.6.37-rc1] KVM deadlock with CONFIG_PREEMPT host

2010-11-08 Thread Jan Kiszka
Hi, I'm seeing lock-ups of the QEMU process on kvm.git as well as current upstream kernels. This is a backtrace of the hanging VCPU thread: [] __stop_cpus+0x184/0x1a7 [] try_stop_cpus+0x40/0x59 [] synchronize_sched_expedited+0x84/0x9d [] __synchronize_srcu+0x33/0x72 [] synchronize_srcu_expedited+

Re: [kvm.git & 2.6.37-rc1] KVM deadlock with CONFIG_PREEMPT host

2010-11-08 Thread Markus Trippelsdorf
On Mon, Nov 08, 2010 at 10:04:00AM +0100, Jan Kiszka wrote: > Hi, > > I'm seeing lock-ups of the QEMU process on kvm.git as well as current > upstream kernels. This is a backtrace of the hanging VCPU thread: > > [] __stop_cpus+0x184/0x1a7 > [] try_stop_cpus+0x40/0x59 > [] synchronize_sched_expedi

Re: [kvm.git & 2.6.37-rc1] KVM deadlock with CONFIG_PREEMPT host

2010-11-08 Thread Jan Kiszka
Am 08.11.2010 10:18, Markus Trippelsdorf wrote: > On Mon, Nov 08, 2010 at 10:04:00AM +0100, Jan Kiszka wrote: >> Hi, >> >> I'm seeing lock-ups of the QEMU process on kvm.git as well as current >> upstream kernels. This is a backtrace of the hanging VCPU thread: >> >> [] __stop_cpus+0x184/0x1a7 >> [

[PATCH v4 5/9] KVM: Refactor IRQ names of assigned devices

2010-11-08 Thread Jan Kiszka
Cosmetic change, but it helps to correlate IRQs with PCI devices. Signed-off-by: Jan Kiszka --- include/linux/kvm_host.h |1 + virt/kvm/assigned-dev.c | 11 ++- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index

[PATCH v4 6/9] KVM: Save/restore state of assigned PCI device

2010-11-08 Thread Jan Kiszka
The guest may change states that pci_reset_function does not touch. So we better save/restore the assigned device across guest usage. Signed-off-by: Jan Kiszka --- virt/kvm/assigned-dev.c |5 - 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/virt/kvm/assigned-dev.c b/virt/

[PATCH v4 8/9] KVM: Document device assigment API

2010-11-08 Thread Jan Kiszka
Adds API documentation for KVM_[DE]ASSIGN_PCI_DEVICE, KVM_[DE]ASSIGN_DEV_IRQ, KVM_SET_GSI_ROUTING, KVM_ASSIGN_SET_MSIX_NR, and KVM_ASSIGN_SET_MSIX_ENTRY. Signed-off-by: Jan Kiszka --- Documentation/kvm/api.txt | 178 + 1 files changed, 178 insertions(

[PATCH v4 2/9] KVM: Switch IRQ subsystem to SRCU

2010-11-08 Thread Jan Kiszka
Ack and mask notifiers typically call back into kvm_set_irq, thus may iterate over all VCPUs of a VM. Better keep this path preemptible to prevent that user-space can massivle influence scheduling latencies. Use sleepable RCU for the protection of irq_routing and the notfier lists. Signed-off-by:

[PATCH v4 1/9] KVM: Fix srcu struct leakage

2010-11-08 Thread Jan Kiszka
Clean up the srcu struct on vm destruction and refactor its release on early errors. Signed-off-by: Jan Kiszka --- virt/kvm/kvm_main.c | 15 +++ 1 files changed, 7 insertions(+), 8 deletions(-) diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c index 4111a4b..6cfcde7 100644 --

[PATCH v4 0/9] KVM: Improve IRQ assignment for device passthrough

2010-11-08 Thread Jan Kiszka
Nine patches (yeah, it's getting more and more) to improve "classic" device assigment /wrt IRQs. Highlight is the last one that resolves the host IRQ sharing issue for all PCI 2.3 devices. Quite essential when passing non-MSI-ready devices like many USB host controllers. As there were concerns reg

[PATCH v4 4/9] KVM: Switch assigned device IRQ forwarding to threaded handler

2010-11-08 Thread Jan Kiszka
This improves the IRQ forwarding for assigned devices: By using the kernel's threaded IRQ scheme, we can get rid of the latency-prone work queue and simplify the code in the same run. Moreover, we no longer have to hold assigned_dev_lock while raising the guest IRQ, which can be a lenghty operatio

[PATCH v4 9/9] KVM: Allow host IRQ sharing for passed-through PCI 2.3 devices

2010-11-08 Thread Jan Kiszka
PCI 2.3 allows to generically disable IRQ sources at device level. This enables us to share IRQs of such devices between on the host side when passing them to a guest. This feature is optional, user space has to request it explicitly. Moreover, user space can inform us about its view of PCI_COMMAND

[PATCH v4 7/9] KVM: Clean up kvm_vm_ioctl_assigned_device

2010-11-08 Thread Jan Kiszka
Any arch not supporting device assigment will also not build assigned-dev.c. So testing for KVM_CAP_DEVICE_DEASSIGNMENT is pointless. KVM_CAP_ASSIGN_DEV_IRQ is unconditinally set. Moreover, add a default case for dispatching the ioctl. Signed-off-by: Jan Kiszka --- virt/kvm/assigned-dev.c |9

[PATCH v4 3/9] KVM: Clear assigned guest IRQ on release

2010-11-08 Thread Jan Kiszka
When we deassign a guest IRQ, clear the potentially asserted guest line. There might be no chance for the guest to do this, specifically if we switch from INTx to MSI mode. Signed-off-by: Jan Kiszka --- virt/kvm/assigned-dev.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --

[PATCH] pci-assign: Use PCI-2.3-based shared legacy interrupts

2010-11-08 Thread Jan Kiszka
Make use of the new KVM feature that allows legacy interrupt sharing for PCI-2.3-compliant devices. As exclusive mode (with IRQ masking at interrupt controller level) is generally faster, the new mode has to be enabled explicitly via the property "host_pci_2_3". Signed-off-by: Jan Kiszka --- hw/

Re: [PATCH 0/6] Save state error handling (kill off no_migrate)

2010-11-08 Thread Michael S. Tsirkin
On Wed, Oct 06, 2010 at 02:58:57PM -0600, Alex Williamson wrote: > Our code paths for saving or migrating a VM are full of functions that > return void, leaving no opportunity for a device to cancel a migration, > either from error or incompatibility. The ivshmem driver attempted to > solve this w

Why so many vm exits caused by ept violation

2010-11-08 Thread lidong chen
I run my application both on xen and kvm, and I found the performance on kvm is worse than xen. kvm: 2.6.32-60.el6.x86_64 redhat 6 bate 2 xen: xen3.4.2 then i stat the vm exit reason, and i found the ept violation reason, kvm is much more than xen. the static result is : (XEN) 10 times on cp

KVM: High CPU load with audio enabled

2010-11-08 Thread Stefan Pietsch
Hi, I'm running a Windows XP guest in KVM. After enabling the audio support (-soundhw es1370) the CPU load of the KVM process in the host system goes up to 100%. Tested with: qemu-kvm-0.13.0 Debian 0.13.0+dfsg-1 KVM start command: kvm -m 512 -hda xp.img -soundhw es1370 Did you experience simil

Re: [PATCH 2/3] KVM: MMU: don not retry #PF for nonpaging guest

2010-11-08 Thread Gleb Natapov
On Mon, Nov 08, 2010 at 10:14:35AM +0800, Xiao Guangrong wrote: > On 11/05/2010 06:31 PM, Gleb Natapov wrote: > > On Fri, Nov 05, 2010 at 04:03:28PM +0800, Xiao Guangrong wrote: > >> On 11/05/2010 03:45 PM, Gleb Natapov wrote: > >> > > It looks like something broken: apfs can generated in

Re: Why so many vm exits caused by ept violation

2010-11-08 Thread Avi Kivity
On 11/08/2010 02:15 PM, lidong chen wrote: I run my application both on xen and kvm, and I found the performance on kvm is worse than xen. kvm: 2.6.32-60.el6.x86_64 redhat 6 bate 2 xen: xen3.4.2 then i stat the vm exit reason, and i found the ept violation reason, kvm is much more than xen. the

Re: Disk I/O stuck with KVM - no clue how to solve that

2010-11-08 Thread Hermann Himmelbauer
Am Montag 08 November 2010 07:32:39 schrieb Stefan Hajnoczi: > If you have the time, you can use perf probes to trace I/O requests in > the host kernel. Perhaps completion interrupts are being dropped. > You may wish to start by tracing requests issued and completed by the > SATA driver. Fortunat

KVM call agenda for Nov 9

2010-11-08 Thread Juan Quintela
Please send in any agenda items you are interested in covering. For once I start: - report from linux plumbers virt track (jes?, anthony?) - report from linux kernel summit (avi?) Cheers, Juan. -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord..

Re: [PATCH 0/6] Save state error handling (kill off no_migrate)

2010-11-08 Thread Alex Williamson
On Mon, 2010-11-08 at 13:40 +0200, Michael S. Tsirkin wrote: > On Wed, Oct 06, 2010 at 02:58:57PM -0600, Alex Williamson wrote: > > Our code paths for saving or migrating a VM are full of functions that > > return void, leaving no opportunity for a device to cancel a migration, > > either from erro

Re: Why so many vm exits caused by ept violation

2010-11-08 Thread lidong chen
> What workload is this? Are you using virtio? yes,i using virtio and vhost. the cpu rate is 70%. I found it maybe caused by 2M HugePages. if didn't use 2M HugePages, there are no vm exits caused by ept violation. I will test the performance without 2M Hugepages later, and see why HugePage ca

Re: KVM: High CPU load with audio enabled

2010-11-08 Thread lidong chen
you can use "perf top" to collect some information. 2010/11/8 Stefan Pietsch : > Hi, > > I'm running a Windows XP guest in KVM. After enabling the audio support > (-soundhw es1370) the CPU load of the KVM process in the host system > goes up to 100%. > > Tested with: qemu-kvm-0.13.0 Debian 0.13.0+

Re: [PATCH 0/6] Save state error handling (kill off no_migrate)

2010-11-08 Thread Michael S. Tsirkin
On Mon, Nov 08, 2010 at 07:59:57AM -0700, Alex Williamson wrote: > On Mon, 2010-11-08 at 13:40 +0200, Michael S. Tsirkin wrote: > > On Wed, Oct 06, 2010 at 02:58:57PM -0600, Alex Williamson wrote: > > > Our code paths for saving or migrating a VM are full of functions that > > > return void, leavin

Re: [PATCH 2/3] KVM: MMU: don not retry #PF for nonpaging guest

2010-11-08 Thread Xiao Guangrong
I mean the second case, the problem is in "d:", now, A-apf is on L0->L1 mapping, and A-apf.gva is nested fault address(L2's physics address in L0->L2 mapping), you use this address to retry #pf in L0->L1 mapping? it is just waste. On 11/8/10, Gleb Natapov wrote: > On Mon, Nov 08, 2010 at 10:14:35

Re: [PATCH v4 1/9] KVM: Fix srcu struct leakage

2010-11-08 Thread Michael S. Tsirkin
On Mon, Nov 08, 2010 at 12:21:45PM +0100, Jan Kiszka wrote: > Clean up the srcu struct on vm destruction and refactor its release on > early errors. > > Signed-off-by: Jan Kiszka Yay, I suspected something's wrong with error handling in srcu. Acked-by: Michael S. Tsirkin This one actually has

Re: [PATCH 2/3] KVM: MMU: don not retry #PF for nonpaging guest

2010-11-08 Thread Gleb Natapov
On Tue, Nov 09, 2010 at 12:58:24AM +0800, Xiao Guangrong wrote: > I mean the second case, the problem is in "d:", now, A-apf is on > L0->L1 mapping, and A-apf.gva is nested fault address(L2's physics > address in L0->L2 mapping), you use this address to retry #pf in > L0->L1 mapping? it is just was

Re: KVM call agenda for Nov 9

2010-11-08 Thread Anthony Liguori
On 11/08/2010 08:23 AM, Juan Quintela wrote: Please send in any agenda items you are interested in covering. For once I start: - report from linux plumbers virt track (jes?, anthony?) - report from linux kernel summit (avi?) Good thinking. Regards, Anthony Liguori Cheers, Juan. -- To u

Re: [PATCHv2 7/8] Change pci bus get_dev_path callback to print only slot and func

2010-11-08 Thread Michael S. Tsirkin
On Sun, Oct 31, 2010 at 01:40:08PM +0200, Gleb Natapov wrote: > Domain should be determined form parent bus and bus number is configured > by guest and should not be used in qemu internally. > > Signed-off-by: Gleb Natapov > --- > hw/pci.c | 11 ++- > 1 files changed, 6 insertions(+),

Re: [PATCH 0/6] Save state error handling (kill off no_migrate)

2010-11-08 Thread Alex Williamson
On Mon, 2010-11-08 at 18:54 +0200, Michael S. Tsirkin wrote: > On Mon, Nov 08, 2010 at 07:59:57AM -0700, Alex Williamson wrote: > > On Mon, 2010-11-08 at 13:40 +0200, Michael S. Tsirkin wrote: > > > On Wed, Oct 06, 2010 at 02:58:57PM -0600, Alex Williamson wrote: > > > > Our code paths for saving o

Re: [PATCHv2 7/8] Change pci bus get_dev_path callback to print only slot and func

2010-11-08 Thread Michael S. Tsirkin
On Sun, Oct 31, 2010 at 01:40:08PM +0200, Gleb Natapov wrote: > Domain should be determined form parent bus and bus number is configured > by guest and should not be used in qemu internally. > > Signed-off-by: Gleb Natapov > --- > hw/pci.c | 11 ++- > 1 files changed, 6 insertions(+),

Re: [PATCHv2 7/8] Change pci bus get_dev_path callback to print only slot and func

2010-11-08 Thread Gleb Natapov
On Mon, Nov 08, 2010 at 07:17:37PM +0200, Michael S. Tsirkin wrote: > On Sun, Oct 31, 2010 at 01:40:08PM +0200, Gleb Natapov wrote: > > Domain should be determined form parent bus and bus number is configured > > by guest and should not be used in qemu internally. > > > > Signed-off-by: Gleb Natap

Re: [PATCH v4 1/9] KVM: Fix srcu struct leakage

2010-11-08 Thread Jan Kiszka
Am 08.11.2010 18:00, Michael S. Tsirkin wrote: > On Mon, Nov 08, 2010 at 12:21:45PM +0100, Jan Kiszka wrote: >> Clean up the srcu struct on vm destruction and refactor its release on >> early errors. >> >> Signed-off-by: Jan Kiszka > > Yay, I suspected something's wrong with error handling in src

Re: [PATCHv2 7/8] Change pci bus get_dev_path callback to print only slot and func

2010-11-08 Thread Michael S. Tsirkin
On Mon, Nov 08, 2010 at 07:29:50PM +0200, Gleb Natapov wrote: > On Mon, Nov 08, 2010 at 07:17:37PM +0200, Michael S. Tsirkin wrote: > > On Sun, Oct 31, 2010 at 01:40:08PM +0200, Gleb Natapov wrote: > > > Domain should be determined form parent bus and bus number is configured > > > by guest and sho

Re: [PATCHv2 7/8] Change pci bus get_dev_path callback to print only slot and func

2010-11-08 Thread Gleb Natapov
On Mon, Nov 08, 2010 at 08:12:55PM +0200, Michael S. Tsirkin wrote: > On Mon, Nov 08, 2010 at 07:29:50PM +0200, Gleb Natapov wrote: > > On Mon, Nov 08, 2010 at 07:17:37PM +0200, Michael S. Tsirkin wrote: > > > On Sun, Oct 31, 2010 at 01:40:08PM +0200, Gleb Natapov wrote: > > > > Domain should be de

2.6.36 modprobe kvm-intel - general protection fault

2010-11-08 Thread Nikola Ciprich
Hi, after booting 2.6.36 on one of my testing machines, modprobe kvm-intel produces: [ 1349.991299] general protection fault: [#1] PREEMPT SMP [ 1349.997199] last sysfs file: /sys/module/drbd/parameters/cn_idx [ 1350.003201] CPU 2 [ 1350.005081] Modules linked in: kvm(+) ocfs2 ocfs2_nodeman

Re: [PATCH -v2] Monitor command: pfa2hva, translate guest physical address to host virtual address

2010-11-08 Thread Huang Ying
Hi, Anthony, On Mon, 2010-11-08 at 11:39 +0800, Anthony Liguori wrote: > On 11/07/2010 07:29 PM, Huang Ying wrote: > > On Sun, 2010-11-07 at 00:24 +0800, Avi Kivity wrote: > > > >> On 11/01/2010 03:22 PM, Anthony Liguori wrote: > >> > >>> On 11/01/2010 02:20 PM, Huang Ying wrote: > >>>

Re: [PATCH 0/6] Save state error handling (kill off no_migrate)

2010-11-08 Thread Michael S. Tsirkin
On Mon, Nov 08, 2010 at 10:20:46AM -0700, Alex Williamson wrote: > On Mon, 2010-11-08 at 18:54 +0200, Michael S. Tsirkin wrote: > > On Mon, Nov 08, 2010 at 07:59:57AM -0700, Alex Williamson wrote: > > > On Mon, 2010-11-08 at 13:40 +0200, Michael S. Tsirkin wrote: > > > > On Wed, Oct 06, 2010 at 02:

Re: [PATCHv2 7/8] Change pci bus get_dev_path callback to print only slot and func

2010-11-08 Thread Michael S. Tsirkin
On Mon, Nov 08, 2010 at 07:29:50PM +0200, Gleb Natapov wrote: > > This will make it compatible with existing code and generally > > what users expect. > > > It will drop domain and bus number part anyway. Yes but the proposal was to add :00: in front to make it have the expected format for mo

Re: [PATCHv2 7/8] Change pci bus get_dev_path callback to print only slot and func

2010-11-08 Thread Gleb Natapov
On Mon, Nov 08, 2010 at 11:00:17PM +0200, Michael S. Tsirkin wrote: > On Mon, Nov 08, 2010 at 07:29:50PM +0200, Gleb Natapov wrote: > > > This will make it compatible with existing code and generally > > > what users expect. > > > > > It will drop domain and bus number part anyway. > > Yes but th

Re: [PATCH 0/6] Save state error handling (kill off no_migrate)

2010-11-08 Thread Alex Williamson
On Mon, 2010-11-08 at 22:59 +0200, Michael S. Tsirkin wrote: > On Mon, Nov 08, 2010 at 10:20:46AM -0700, Alex Williamson wrote: > > On Mon, 2010-11-08 at 18:54 +0200, Michael S. Tsirkin wrote: > > > On Mon, Nov 08, 2010 at 07:59:57AM -0700, Alex Williamson wrote: > > > > On Mon, 2010-11-08 at 13:40

Using qemu-img to directly convert physical disk to KVM image

2010-11-08 Thread Emmanuel Noobadmin
I'm trying to convert a physical Windows XP machine into a KVM guest. All the guides so far mentions using dd to create a flat image file, then using qemu-img to convert that to qcow2. Since I've been making mistake here and there, retrying the process several times (initially converting each logic

Re: Using qemu-img to directly convert physical disk to KVM image

2010-11-08 Thread Michael Tokarev
09.11.2010 01:48, Emmanuel Noobadmin wrote: > I'm trying to convert a physical Windows XP machine into a KVM guest. > All the guides so far mentions using dd to create a flat image file, > then using qemu-img to convert that to qcow2. Since I've been making > mistake here and there, retrying the pr

Re: KVM: High CPU load with audio enabled

2010-11-08 Thread Michael Tokarev
08.11.2010 15:40, Stefan Pietsch wrote: > Hi, > > I'm running a Windows XP guest in KVM. After enabling the audio support > (-soundhw es1370) the CPU load of the KVM process in the host system > goes up to 100%. > > Tested with: qemu-kvm-0.13.0 Debian 0.13.0+dfsg-1 > > KVM start command: kvm -m

Re: Using qemu-img to directly convert physical disk to KVM image

2010-11-08 Thread Emmanuel Noobadmin
Thanks for the confirmation and just for the benefit of anybody else who subsequently searches for KVM QEMU convert physical drive virtual machine image , yes it works :) On 11/9/10, Michael Tokarev wrote: > 09.11.2010 01:48, Emmanuel Noobadmin wrote: >> I'm trying to convert a physical Windows

Re: [PATCH -v2] Monitor command: pfa2hva, translate guest physical address to host virtual address

2010-11-08 Thread Huang Ying
On Mon, 2010-11-08 at 11:39 +0800, Anthony Liguori wrote: > On 11/07/2010 07:29 PM, Huang Ying wrote: > > On Sun, 2010-11-07 at 00:24 +0800, Avi Kivity wrote: > > > >> On 11/01/2010 03:22 PM, Anthony Liguori wrote: > >> > >>> On 11/01/2010 02:20 PM, Huang Ying wrote: > >>> >

Re: [v3 RFC PATCH 0/4] Implement multiqueue virtio-net

2010-11-08 Thread Krishna Kumar2
"Michael S. Tsirkin" wrote on 10/26/2010 02:27:09 PM: > Re: [v3 RFC PATCH 0/4] Implement multiqueue virtio-net > > On Mon, Oct 25, 2010 at 09:20:38PM +0530, Krishna Kumar2 wrote: > > > Krishna Kumar2/India/i...@ibmin wrote on 10/20/2010 02:24:52 PM: > > > > Any feedback, comments, objections, iss

Re: Why so many vm exits caused by ept violation

2010-11-08 Thread lidong chen
sorry,i take mistake, the ept violation is not caused by 2M hugepages, but caused by e1000 emulated by qemu. I test uesd 2M hugepages and virio, the performance is better than e1000. but is still worse than xen. I will continue to find out other reason. so, there are two question: 1.why have so

Re: Why so many vm exits caused by ept violation

2010-11-08 Thread Gleb Natapov
On Tue, Nov 09, 2010 at 03:37:44PM +0800, lidong chen wrote: > sorry,i take mistake, > > the ept violation is not caused by 2M hugepages, but caused by e1000 > emulated by qemu. > I test uesd 2M hugepages and virio, the performance is better than > e1000. but is still worse than xen. I will contin

Re: Using qemu-img to directly convert physical disk to KVM image

2010-11-08 Thread Michael Tokarev
09.11.2010 05:54, Emmanuel Noobadmin wrote: > Thanks for the confirmation and just for the benefit of anybody else > who subsequently searches for KVM QEMU convert physical > drive virtual machine image , yes it works :) Heh. Well, it is not something unexpected really. Just a few more comments