Re: kvm-77 Excessive Disk Access causes real time clock hang!

2009-04-27 Thread Avi Kivity
Erik Rull wrote: Are you using qcow2? In some cases qcow2 will stall the guest cpu. Note that defragmenting the guest drive may cause the qcow2 file to fragment even more, and will certainly increase its size. I recommend only defragmenting when using raw storage. I don't think so. I

Re: qemu-kvm.git now live

2009-04-27 Thread Avi Kivity
Cameron Macdonell wrote: Great. They work as expected. One thing I noticed is that make clean doesn't remove libkvm.{o,a} and .libkvm.d. Should it? Should, but doesn't. Another thing to fix. -- Do not meddle in the internals of kernels, for they are subtle and quick to panic. -- To

Re: [PATCH] Assign the correct pci id range to virtio_pci

2009-04-27 Thread Gerd Hoffmann
On 04/24/09 15:19, Anthony Liguori wrote: Pantelis Koukousoulas wrote: According to the file pci-ids.txt in qemu sources, the range of PCI device IDs assigned to virtio_pci is 0x1000 to 0x10ff, with a few subranges that have different rules regarding who can get an ID there and how.

kvm-85 won't boot guests with virtio block device

2009-04-27 Thread Pauline Middelink
Added the sacred signoff at numerious request :) Met vriendelijke groet, Pauline Middelink -- GPG Key fingerprint = 2D5B 87A7 DDA6 0378 5DEA BD3B 9A50 B416 E2D0 C3C2 For more details look at my website http://www.polyware.nl/~middelink Small regression. libvirt determines the use of

[PATCH] qemu-kvm: make clean should propagate into libkvm directory

2009-04-27 Thread Michael S. Tsirkin
make 'clean' target propage into libkvm if it's enabled Signed-off-by: Michael S. Tsirkin m...@redhat.com --- Makefile.target |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/Makefile.target b/Makefile.target index d890220..28dce60 100644 --- a/Makefile.target +++

[PATCH] qemu-kvm: fix compiler warning

2009-04-27 Thread Michael S. Tsirkin
kvm-common.h:25:7: warning: __ia64__ is not defined Signed-off-by: Michael S. Tsirkin m...@redhat.com --- kvm/libkvm/kvm-common.h |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/kvm/libkvm/kvm-common.h b/kvm/libkvm/kvm-common.h index 96361e8..591fb53 100644 ---

[PATCH] qemu-kvm: make kvm_create_pit static

2009-04-27 Thread Michael S. Tsirkin
libkvm-x86.c:55: warning: no previous prototype for ‘kvm_create_pit’ Signed-off-by: Michael S. Tsirkin m...@redhat.com --- kvm/libkvm/libkvm-x86.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/kvm/libkvm/libkvm-x86.c b/kvm/libkvm/libkvm-x86.c index 2fc4fce..df8cc81

[PATCH] virtio_blk: SG_IO passthru support

2009-04-27 Thread Christoph Hellwig
From: Hannes Reinecke h...@suse.de Add support for SG_IO passthru to virtio_blk. We add the scsi command block after the normal outhdr, and the scsi inhdr with full status information aswell as the sense buffer before the regular inhdr. [hch: forward ported, added the VIRTIO_BLK_F_SCSI flags,

[PATCH] virtio-blk: add SGI_IO passthru support

2009-04-27 Thread Christoph Hellwig
Add support for SG_IO passthru (packet commands) to the virtio-blk backend. Conceptually based on an older patch from Hannes Reinecke but largely rewritten to match the code structure and layering in virtio-blk. Note that currently we issue the hose SG_IO synchronously. We could easily switch

Re: [PATCH] Assign the correct pci id range to virtio_pci

2009-04-27 Thread Pantelis Koukousoulas
I'd suggest to exclude the experimental range by default (enable via module parameter) to make clear it isn't for regular use. Module parameter on what? The module parameter parsing code is afaict provided by the end-driver (e.g., virtio-net) which only speaks virtio and has no idea there is an

Re: [KVM PATCH v2 2/2] kvm: add support for irqfd via eventfd-notification interface

2009-04-27 Thread Avi Kivity
Gregory Haskins wrote: This allows an eventfd to be registered as an irq source with a guest. Any signaling operation on the eventfd (via userspace or kernel) will inject the registered GSI at the next available window. +struct kvm_irqfd { + __u32 fd; + __u32 gsi; +}; + I

Re: [PATCH] Assign the correct pci id range to virtio_pci

2009-04-27 Thread Gerd Hoffmann
On 04/27/09 10:39, Pantelis Koukousoulas wrote: I'd suggest to exclude the experimental range by default (enable via module parameter) to make clear it isn't for regular use. Module parameter on what? virtio_pci.ko Then you'll do something like this ... echo options virtio_pci

Re: [PATCH] Assign the correct pci id range to virtio_pci

2009-04-27 Thread Gerd Hoffmann
On 04/27/09 11:11, Pantelis Koukousoulas wrote: Module parameter on what? virtio_pci.ko Then you'll do something like this ... echo options virtio_pci experimental=1 /etc/modprobe.d/virtio.conf ... to enable the experimental IDs. Ok, I can sure live with such an arrangement :) Should the

Re: [PATCH] Assign the correct pci id range to virtio_pci

2009-04-27 Thread Avi Kivity
Gerd Hoffmann wrote: On 04/27/09 11:11, Pantelis Koukousoulas wrote: Module parameter on what? virtio_pci.ko Then you'll do something like this ... echo options virtio_pci experimental=1 /etc/modprobe.d/virtio.conf ... to enable the experimental IDs. Ok, I can sure live with such an

[PATCH 2/2] KVM: Enable snooping control for supported hardware

2009-04-27 Thread Sheng Yang
Memory aliases with different memory type is a problem for guest. For the guest without assigned device, the memory type of guest memory would always been the same as host(WB); but for the assigned device, some part of memory may be used as DMA and then set to uncacheable memory type(UC/WC), which

Re: Unable to boot guest on kernel 2.6.29.1 with kvm-84 or kvm-85

2009-04-27 Thread Avi Kivity
Eino Malinen wrote: Can you try a bisect? I confirm having the same trouble with kvm. Bisect with the vanilla kernel gave the following result: (f438349...|BISECTING)$ git bisect log # bad: [8d7bff2d72660d9d60aa371ae3d1356bbf329a09] Linux 2.6.29.1 # good:

Re: [Qemu-devel] [PATCH] virtio-blk: add SGI_IO passthru support

2009-04-27 Thread Avi Kivity
Christoph Hellwig wrote: [had the qemu list address wrong the first time, reply to this message, not the previous if you were on Cc] Add support for SG_IO passthru (packet commands) to the virtio-blk backend. Conceptually based on an older patch from Hannes Reinecke but largely rewritten to

Re: [PATCH] virtio_blk: SG_IO passthru support

2009-04-27 Thread Christian Borntraeger
Am Monday 27 April 2009 10:21:21 schrieben Sie: From: Hannes Reinecke h...@suse.de Add support for SG_IO passthru to virtio_blk. We add the scsi command block after the normal outhdr, and the scsi inhdr with full status information aswell as the sense buffer before the regular inhdr.

Re: [KVM PATCH v2 2/2] kvm: add support for irqfd via eventfd-notification interface

2009-04-27 Thread Gregory Haskins
Gregory Haskins wrote: Avi Kivity wrote: One day we'll have lockless injection and we'll want to drop this. I guess if we create the fd ourselves we can make it work, but I don't see how we can do this with eventfd. Hmm...this is a good point. There probably is no way to use

Re: [PATCH v2 00/16] interrupt injection rework

2009-04-27 Thread Avi Kivity
Gleb Natapov wrote: Hi, This patch series aims to consolidate IRQ injection code for in kernel IRQ chip and userspace one. Also to move IRQ injection logic from SVM/VMX specific code to x86.c. Applied all, thanks for this excellent patchset. -- error compiling committee.c: too many

Re: [PATCH v2] qemu-kvm: add irqfd support

2009-04-27 Thread Gregory Haskins
Michael S. Tsirkin wrote: On Fri, Apr 24, 2009 at 12:30:17AM -0400, Gregory Haskins wrote: +int kvm_irqfd(kvm_context_t kvm, int gsi) +{ +int fd, r; + +if (!kvm_check_extension(kvm, KVM_CAP_IRQFD)) +return -ENOENT; + +fd = eventfd(0, 0); +if (fd 0) +

Re: [KVM PATCH v2 2/2] kvm: add support for irqfd via eventfd-notification interface

2009-04-27 Thread Avi Kivity
Gregory Haskins wrote: Something else to consider: eventfd supports calling eventfd_signal() from interrupt context, so even if the callback were not invoked from a preempt/irq off CS due to the wqh-lock, the context may still be a CS anyway. Now, userspace and vbus based injection do not need

Re: [PATCH] Assign the correct pci id range to virtio_pci

2009-04-27 Thread Pantelis Koukousoulas
Or maybe  modprobe virtio-pci claim=0x10f2 claim=0x10f7 How about claim=0x10f2,0x10f7 instead so that it can be implemented as a standard module array parameter? -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a message to majord...@vger.kernel.org More majordomo

Re: [PATCH] Assign the correct pci id range to virtio_pci

2009-04-27 Thread Avi Kivity
Pantelis Koukousoulas wrote: Or maybe modprobe virtio-pci claim=0x10f2 claim=0x10f7 How about claim=0x10f2,0x10f7 instead so that it can be implemented as a standard module array parameter? Even better. -- error compiling committee.c: too many arguments to function -- To

kvm-kmod.git

2009-04-27 Thread Avi Kivity
This is a small git repository for the kvm external module kit. It includes a submodule link to the kernel tree, so when you check out the repository, it also checks out a kernel tree for a specific revision. This way the various scripts and the kernel source are always synchronized. $ git

[PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Michael S. Tsirkin
Add optional MSI-X support: use a vector per virtqueue with fallback to a common vector and finally to regular interrupt. Teach all drivers to use it. I added 2 new virtio operations: request_vqs/free_vqs because MSI needs to know the total number of vectors upfront. Signed-off-by: Michael S.

[PATCH 1/8] virtio: add request_vqs/free_vqs operations

2009-04-27 Thread Michael S. Tsirkin
This adds 2 new optional virtio operations: request_vqs/free_vqs. They will be used for MSI support, because MSI needs to know the total number of vectors upfront. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- include/linux/virtio_config.h | 35 +++ 1

[PATCH 2/8] virtio_blk: add request_vqs/free_vqs calls

2009-04-27 Thread Michael S. Tsirkin
Add request_vqs/free_vqs calls to virtio_blk. These will be required for MSI support. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- drivers/block/virtio_blk.c |9 - 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/drivers/block/virtio_blk.c

[PATCH 3/8] virtio-rng: add request_vqs/free_vqs calls

2009-04-27 Thread Michael S. Tsirkin
Add request_vqs/free_vqs calls to virtio-rng. These will be required for MSI support. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- drivers/char/hw_random/virtio-rng.c | 10 +- 1 files changed, 9 insertions(+), 1 deletions(-) diff --git a/drivers/char/hw_random/virtio-rng.c

[PATCH 7/8] virtio_pci: split up vp_interrupt

2009-04-27 Thread Michael S. Tsirkin
This reorganizes virtio-pci code in vp_interrupt slightly, so that it's easier to add per-vq MSI support on top. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- drivers/virtio/virtio_pci.c | 45 +- 1 files changed, 35 insertions(+), 10 deletions(-)

[PATCH 8/8] virtio_pci: optional MSI-X support

2009-04-27 Thread Michael S. Tsirkin
This implements optional MSI-X support in virtio_pci. MSI-X is used whenever the host supports at least 2 MSI-X vectors: 1 for configuration changes and 1 for virtqueues. Per-virtqueue vectors are allocated if enough vectors available. Signed-off-by: Michael S. Tsirkin m...@redhat.com ---

[PATCH 5/8] virtio_net: add request_vqs/free_vqs calls

2009-04-27 Thread Michael S. Tsirkin
Add request_vqs/free_vqs calls to virtio_net. These will be required for MSI support. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- drivers/net/virtio_net.c | 16 +--- 1 files changed, 13 insertions(+), 3 deletions(-) diff --git a/drivers/net/virtio_net.c

[PATCH 2/2] KVM: Enable snooping control for supported hardware

2009-04-27 Thread Sheng Yang
Memory aliases with different memory type is a problem for guest. For the guest without assigned device, the memory type of guest memory would always been the same as host(WB); but for the assigned device, some part of memory may be used as DMA and then set to uncacheable memory type(UC/WC), which

[PATCH 1/2] KVM: Replace get_mt_mask_shift with get_mt_mask

2009-04-27 Thread Sheng Yang
Shadow_mt_mask is out of date, now it have only been used as a flag to indicate if TDP enabled. Get rid of it and use tdp_enabled instead. Also put memory type logical in kvm_x86_ops-get_mt_mask(). Signed-off-by: Sheng Yang sh...@linux.intel.com --- arch/x86/include/asm/kvm_host.h |5 +++--

Re: kvm-userspace broken?

2009-04-27 Thread Avi Kivity
Oliver Rath wrote: Hi List, maybe i missed some announcements, but git clone git://git.kernel.org/pub/scm/virt/kvm/kvm-userspace.git givs no response: kvm-userspace # git clone git://git.kernel.org/pub/scm/virt/kvm/kvm-userspace.git Initialized empty Git repository in

Re: [PATCH] kvm-userspace: Make PC speaker emulation aware of in-kernel PIT

2009-04-27 Thread Sheng Yang
On Sunday 26 April 2009 03:59:11 Anthony Liguori wrote: Jan Kiszka wrote: Anthony Liguori wrote: Marcelo Tosatti wrote: Jan, While the patch itself looks fine, IMO it would be better to move all of the timer handling to userspace, except the performance critical parts, since most

qemu/hw/device-assignment: questions about msix_table_page

2009-04-27 Thread Michael S. Tsirkin
Sheng, Marcelo, I've been reading code in qemu/hw/device-assignment.c, and I have a couple of questions about msi-x implementation: 1. What is the reason that msix_table_page is allocated with mmap and not with e.g. malloc? 2. msix_table_page has the guest view of the msix table for the device.

Re:

2009-04-27 Thread Sheng Yang
On Monday 27 April 2009 18:41:17 Michael S. Tsirkin wrote: Sheng, Marcelo, I've been reading code in qemu/hw/device-assignment.c, and I have a couple of questions about msi-x implementation: Hi Michael 1. What is the reason that msix_table_page is allocated with mmap and not with e.g.

Re: [KVM PATCH v2 2/2] kvm: add support for irqfd via eventfd-notification interface

2009-04-27 Thread Gregory Haskins
Avi Kivity wrote: Gregory Haskins wrote: This allows an eventfd to be registered as an irq source with a guest. Any signaling operation on the eventfd (via userspace or kernel) will inject the registered GSI at the next available window. +struct kvm_irqfd { +__u32 fd; +__u32

Re: qemu/hw/device-assignment: questions about msix_table_page

2009-04-27 Thread Michael S. Tsirkin
On Mon, Apr 27, 2009 at 09:16:14PM +0800, Sheng Yang wrote: On Monday 27 April 2009 18:41:17 Michael S. Tsirkin wrote: Sheng, Marcelo, I've been reading code in qemu/hw/device-assignment.c, and I have a couple of questions about msi-x implementation: Hi Michael 1. What is the reason

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Christian Borntraeger
Am Monday 27 April 2009 14:31:36 schrieb Michael S. Tsirkin: Add optional MSI-X support: use a vector per virtqueue with fallback to a common vector and finally to regular interrupt. Teach all drivers to use it. I added 2 new virtio operations: request_vqs/free_vqs because MSI needs to know

Re: qemu/hw/device-assignment: questions about msix_table_page

2009-04-27 Thread Sheng Yang
On Monday 27 April 2009 21:51:34 Michael S. Tsirkin wrote: On Mon, Apr 27, 2009 at 09:16:14PM +0800, Sheng Yang wrote: On Monday 27 April 2009 18:41:17 Michael S. Tsirkin wrote: Sheng, Marcelo, I've been reading code in qemu/hw/device-assignment.c, and I have a couple of questions

Re: kvm-kmod.git

2009-04-27 Thread Farkas Levente
Avi Kivity wrote: This is a small git repository for the kvm external module kit. It includes a submodule link to the kernel tree, so when you check out the repository, it also checks out a kernel tree for a specific revision. This way the various scripts and the kernel source are always

Re: qemu/hw/device-assignment: questions about msix_table_page

2009-04-27 Thread Michael S. Tsirkin
On Mon, Apr 27, 2009 at 10:03:59PM +0800, Sheng Yang wrote: On Monday 27 April 2009 21:51:34 Michael S. Tsirkin wrote: On Mon, Apr 27, 2009 at 09:16:14PM +0800, Sheng Yang wrote: On Monday 27 April 2009 18:41:17 Michael S. Tsirkin wrote: Sheng, Marcelo, I've been reading code in

Re: qemu/hw/device-assignment: questions about msix_table_page

2009-04-27 Thread Sheng Yang
On Monday 27 April 2009 22:15:04 Michael S. Tsirkin wrote: On Mon, Apr 27, 2009 at 10:03:59PM +0800, Sheng Yang wrote: On Monday 27 April 2009 21:51:34 Michael S. Tsirkin wrote: On Mon, Apr 27, 2009 at 09:16:14PM +0800, Sheng Yang wrote: On Monday 27 April 2009 18:41:17 Michael S.

[PATCH] kvm: qemu: framebuffer: build fix for target-arm

2009-04-27 Thread Mark McLoughlin
Include qemu-kvm.h for non-KVM_UPSTREAM building and surround the kvm code with USE_KVM guards. Fixes target-arm: qemu/hw/framebuffer.c: In function 'framebuffer_update_display': qemu/hw/framebuffer.c:53: warning: implicit declaration of function 'kvm_enabled' qemu/hw/framebuffer.c:54:

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Michael S. Tsirkin
On Mon, Apr 27, 2009 at 04:00:30PM +0200, Christian Borntraeger wrote: Am Monday 27 April 2009 14:31:36 schrieb Michael S. Tsirkin: Add optional MSI-X support: use a vector per virtqueue with fallback to a common vector and finally to regular interrupt. Teach all drivers to use it. I

Re: qemu/hw/device-assignment: questions about msix_table_page

2009-04-27 Thread Michael S. Tsirkin
On Mon, Apr 27, 2009 at 10:30:17PM +0800, Sheng Yang wrote: My suggestion is get mask bit support first, then consider optimization. Yea. Thanks for the explanations! -- MST -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a message to majord...@vger.kernel.org

Re: [PATCH] virtio-blk: add SGI_IO passthru support

2009-04-27 Thread Anthony Liguori
Christoph Hellwig wrote: [had the qemu list address wrong the first time, reply to this message, not the previous if you were on Cc] Add support for SG_IO passthru (packet commands) to the virtio-blk backend. Conceptually based on an older patch from Hannes Reinecke but largely rewritten to

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Anthony Liguori
Michael S. Tsirkin wrote: Add optional MSI-X support: use a vector per virtqueue with fallback to a common vector and finally to regular interrupt. Teach all drivers to use it. I added 2 new virtio operations: request_vqs/free_vqs because MSI needs to know the total number of vectors upfront.

Re: [ANNOUNCE] kvm-85 release

2009-04-27 Thread Mark McLoughlin
Hi Avi, On Tue, 2009-04-21 at 12:32 +0300, Avi Kivity wrote: Again a long delayed release; I'll try to reduce the lag between releases. kvm-85 comes in two flavors: the traditional kernel+qemu package (kvm-85.tar.gz), as well as separate qemu (qemu-kvm-devel-85.tar.gz) I packaged this

Re: [ANNOUNCE] kvm-85 release

2009-04-27 Thread Alexander Graf
On 27.04.2009, at 16:41, Mark McLoughlin wrote: Hi Avi, On Tue, 2009-04-21 at 12:32 +0300, Avi Kivity wrote: Again a long delayed release; I'll try to reduce the lag between releases. kvm-85 comes in two flavors: the traditional kernel+qemu package (kvm-85.tar.gz), as well as separate qemu

Re: [ANNOUNCE] kvm-85 release

2009-04-27 Thread Christoph Hellwig
On Mon, Apr 27, 2009 at 04:45:23PM +0200, Alexander Graf wrote: - Disabled pwritev() support until glibc stops writing random junk. See https://bugzilla.redhat.com/497429 Wouldn't it be useful to have it disabled upstream then? No glibc has been released with the broken one yet, I gusee

CPU Limitations

2009-04-27 Thread Cornelius Wefelscheid
Hi, i have the following problem: I got a amd opteron server with 32 (4*8) cpus. Since kvm is only able to created a virtual machine with 16 cpus, i changed KVM_MAX_VCPUS, MAX_VCPUS and MAX_CPUS as suggested in http://www.linux-kvm.org/wiki/images/b/be/KvmForum2008$kdf2008_6.pdf after compiling

[ kvm-Bugs-2768533 ] SCSI/VirtIO: VM unable to reboot from non-IDE controller

2009-04-27 Thread SourceForge.net
Bugs item #2768533, was opened at 2009-04-16 16:01 Message generated for change (Settings changed) made by technologov You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=893831aid=2768533group_id=180599 Please note that this message will contain a full copy of the

Re: kvm-kmod.git

2009-04-27 Thread Avi Kivity
Farkas Levente wrote: hi, i see this big reorganization of the sources (which is good), but does it means that there will be separate tarball releases for kvm-kmod and kvm userspace (which can be compiled without other tarball and git commands)? if yes, it means there'll be one kvm-kmod tarball

Re: [ANNOUNCE] kvm-85 release

2009-04-27 Thread Avi Kivity
Mark McLoughlin wrote: Hi Avi, On Tue, 2009-04-21 at 12:32 +0300, Avi Kivity wrote: Again a long delayed release; I'll try to reduce the lag between releases. kvm-85 comes in two flavors: the traditional kernel+qemu package (kvm-85.tar.gz), as well as separate qemu

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Avi Kivity
Christian Borntraeger wrote: Am Monday 27 April 2009 14:31:36 schrieb Michael S. Tsirkin: Add optional MSI-X support: use a vector per virtqueue with fallback to a common vector and finally to regular interrupt. Teach all drivers to use it. I added 2 new virtio operations:

Re: [ANNOUNCE] kvm-85 release

2009-04-27 Thread Mark McLoughlin
On Mon, 2009-04-27 at 10:50 -0400, Christoph Hellwig wrote: On Mon, Apr 27, 2009 at 04:45:23PM +0200, Alexander Graf wrote: - Disabled pwritev() support until glibc stops writing random junk. See https://bugzilla.redhat.com/497429 Wouldn't it be useful to have it disabled upstream

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Christian Borntraeger
Am Monday 27 April 2009 16:32:56 schrieb Michael S. Tsirkin: I dont know, if that is feasible for MSI, but the transport(virtio_pci) should already know the number of virtqueues, which should match the number of vectors, no? I think no, the transport can find out the max number of

bad virtio disk performance

2009-04-27 Thread Lucas Nussbaum
Hi, I'm experiencing bad disk I/O performance using virtio disks. I'm using Linux 2.6.29 (host guest), kvm 84 userspace. On the host, and in a non-virtio guest, I get ~120 MB/s when writing with dd (the disks are fast RAID0 SAS disks). In a guest with a virtio disk, I get at most ~32 MB/s.

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Michael S. Tsirkin
On Mon, Apr 27, 2009 at 06:06:48PM +0300, Avi Kivity wrote: Christian Borntraeger wrote: Am Monday 27 April 2009 14:31:36 schrieb Michael S. Tsirkin: Add optional MSI-X support: use a vector per virtqueue with fallback to a common vector and finally to regular interrupt. Teach all drivers

Re: [PATCH] reserved-ram for pci-passthrough without VT-d capable hardware

2009-04-27 Thread Passera, Pablo R
Andrea, We are working with embedded hardware that does not have VT-d and we need 1-1 mapping. I wonder which is the status of this patch. Have you continued updating it with the latest KVM version? Regards, Pablo On Wed, Jul 30, 2008 at 05:16:06PM +0300, Dor Laor wrote: In addition

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Christian Borntraeger
Am Monday 27 April 2009 17:39:36 schrieb Michael S. Tsirkin: So we'll probably need to rename request_vqs to request_vectors, but we probably still need the driver to pass the number of vectors it wants to the transport. Right? This might be a stupid idea, but would something like the

Re: [PATCH 3/7] kvm/mmu: rename is_largepage_backed to mapping_level

2009-04-27 Thread Marcelo Tosatti
Joerg, On Fri, Apr 24, 2009 at 01:58:43PM +0200, Joerg Roedel wrote: With the new name and the corresponding backend changes this function can now support multiple hugepage sizes. Signed-off-by: Joerg Roedel joerg.roe...@amd.com --- arch/x86/kvm/mmu.c | 100

Re: kvm-kmod.git

2009-04-27 Thread Cam Macdonell
Avi Kivity wrote: This is a small git repository for the kvm external module kit. It includes a submodule link to the kernel tree, so when you check out the repository, it also checks out a kernel tree for a specific revision. This way the various scripts and the kernel source are always

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Michael S. Tsirkin
On Mon, Apr 27, 2009 at 05:37:25PM +0200, Christian Borntraeger wrote: As number of virtqueues = number of vectors, we could pre-allocate all vectors that host supports, but this seems a bit drastic as an MSI-X device could support up to 2K vectors. In fact, the transport has to have

Re: kvm-77 Excessive Disk Access causes real time clock hang!

2009-04-27 Thread Erik Rull
Hi Avi, Avi Kivity wrote: interface: virtio cache: none format: raw, using a partition or logical volume What are you using? uhm, I'm not sure, I call qemu with: qemu-system-x86_64 -usb -hda /dev/hda2 -m 1536 -net nic,macaddr=$MACADDR -net tap,script=/etc/qemu-ifup -no-acpi -monitor stdio

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Michael S. Tsirkin
On Mon, Apr 27, 2009 at 06:59:52PM +0200, Christian Borntraeger wrote: Am Monday 27 April 2009 17:39:36 schrieb Michael S. Tsirkin: So we'll probably need to rename request_vqs to request_vectors, but we probably still need the driver to pass the number of vectors it wants to the transport.

Boot problems with qemu-kvm

2009-04-27 Thread Cam Macdonell
Hi, I've tried booting two VMs (Ubuntu and Fedora 11) that previously worked with the latest kvm-userspace. At start, I get the following warning: Could not open '/dev/kqemu' - QEMU acceleration layer not activated: No such file or directory But, booting proceeds quickly which seems to

Re: bad virtio disk performance

2009-04-27 Thread john cooper
Lucas Nussbaum wrote: Hi, I'm experiencing bad disk I/O performance using virtio disks. I'm using Linux 2.6.29 (host guest), kvm 84 userspace. On the host, and in a non-virtio guest, I get ~120 MB/s when writing with dd (the disks are fast RAID0 SAS disks). Could you provide detail of the

Re: [PATCH] reserved-ram for pci-passthrough without VT-d capable hardware

2009-04-27 Thread Andrea Arcangeli
Hello Pablo, On Mon, Apr 27, 2009 at 11:00:51AM -0600, Passera, Pablo R wrote: Andrea, We are working with embedded hardware that does not have VT-d and we need 1-1 mapping. I wonder which is the status of this patch. Have you continued updating it with the latest KVM version? Sorry to

Re: [PATCH RFC 0/8] virtio: add guest MSI-X support

2009-04-27 Thread Michael S. Tsirkin
On Mon, Apr 27, 2009 at 09:39:06AM -0500, Anthony Liguori wrote: Michael S. Tsirkin wrote: Add optional MSI-X support: use a vector per virtqueue with fallback to a common vector and finally to regular interrupt. Teach all drivers to use it. I added 2 new virtio operations:

Re: bad virtio disk performance

2009-04-27 Thread Lucas Nussbaum
On 27/04/09 at 13:36 -0400, john cooper wrote: Lucas Nussbaum wrote: Hi, I'm experiencing bad disk I/O performance using virtio disks. I'm using Linux 2.6.29 (host guest), kvm 84 userspace. On the host, and in a non-virtio guest, I get ~120 MB/s when writing with dd (the disks are fast

[KVM PATCH v3 1/2] eventfd: export fget and signal interfaces for module use

2009-04-27 Thread Gregory Haskins
We will use this later in the series Signed-off-by: Gregory Haskins ghask...@novell.com --- fs/eventfd.c |4 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/fs/eventfd.c b/fs/eventfd.c index 2a701d5..faf9e60 100644 --- a/fs/eventfd.c +++ b/fs/eventfd.c @@ -16,6 +16,7 @@

[KVM PATCH v3 0/2] irqfd

2009-04-27 Thread Gregory Haskins
(Applies to kvm.git 41b76d8d0487c26d6d4d3fe53c1ff59b3236f096) This series implements a mechanism called irqfd. It lets you create an eventfd based file-desriptor to inject interrupts to a kvm guest. We associate one gsi per fd for fine-grained routing. [ Changelog: v3: *) The

[KVM PATCH v3 2/2] kvm: add support for irqfd via eventfd-notification interface

2009-04-27 Thread Gregory Haskins
This allows an eventfd to be registered as an irq source with a guest. Any signaling operation on the eventfd (via userspace or kernel) will inject the registered GSI at the next available window. Signed-off-by: Gregory Haskins ghask...@novell.com --- arch/x86/kvm/Makefile|2 -

[PATCH v3] qemu-kvm: add irqfd support

2009-04-27 Thread Gregory Haskins
(Applies to qemu-kvm.git 8f7a30dbc40a1d4c09275566f9ed9647ed1ee50f) irqfd lets you create an eventfd based file-desriptor to inject interrupts to a kvm guest. We associate one gsi per fd for fine-grained routing. Signed-off-by: Gregory Haskins ghask...@novell.com --- kvm/libkvm/libkvm.c | 18

[patch 1/4] KVM: MMU: protect kvm_mmu_change_mmu_pages with mmu_lock

2009-04-27 Thread mtosatti
kvm_handle_hva, called by MMU notifiers, manipulates mmu data only with the protection of mmu_lock. Update kvm_mmu_change_mmu_pages callers to take mmu_lock, thus protecting against kvm_handle_hva. CC: Andrea Arcangeli aarca...@redhat.com Signed-off-by: Marcelo Tosatti mtosa...@redhat.com

[patch 4/4] KVM: x86: disallow changing a slots size

2009-04-27 Thread mtosatti
Support to shrinking aliases complicates kernel code unnecessarily, while userspace can do the same with two operations, delete an alias, and create a new alias. Signed-off-by: Marcelo Tosatti mtosa...@redhat.com Index: kvm/arch/x86/kvm/x86.c

[patch 2/4] KVM: take mmu_lock when updating a deleted slot

2009-04-27 Thread mtosatti
kvm_handle_hva relies on mmu_lock protection to safely access the memslot structures. Signed-off-by: Marcelo Tosatti mtosa...@redhat.com Index: kvm/virt/kvm/kvm_main.c === --- kvm.orig/virt/kvm/kvm_main.c +++

[patch 0/4] set_memory_region locking fixes / vcpu-arch.cr3 + removal of memslots

2009-04-27 Thread mtosatti
-- 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

[patch 3/4] KVM: introduce kvm_arch_can_free_memslot, disallow slot deletion if cached cr3

2009-04-27 Thread mtosatti
Disallow the deletion of memory slots (and aliases, for x86 case), if a vcpu contains a cr3 that points to such slot/alias. This complements commit 6c20e1442bb1c62914bb85b7f4a38973d2a423ba. Signed-off-by: Marcelo Tosatti mtosa...@redhat.com Index: kvm/arch/ia64/kvm/kvm-ia64.c

[patch 1/4] qemu: external module: smp_send_reschedule compat

2009-04-27 Thread mtosatti
smp_send_reschedule was exported (via smp_ops) in v2.6.24. Create a compat function which schedules the IPI to keventd context, in case interrupts are disabled, for kernels 2.6.24. Signed-off-by: Marcelo Tosatti mtosa...@redhat.com diff --git a/kvm/kernel/external-module-compat-comm.h

[patch 3/4] KVM: use smp_send_reschedule in kvm_vcpu_kick

2009-04-27 Thread mtosatti
KVM uses a function call IPI to cause the exit of a guest running on a physical cpu. For virtual interrupt notification there is no need to wait on IPI receival, or to execute any function. This is exactly what the reschedule IPI does, without the overhead of function IPI. So use it instead of

[patch 4/4] KVM: protect assigned dev workqueue, int handler and irq acker

2009-04-27 Thread mtosatti
kvm_assigned_dev_ack_irq is vulnerable to a race condition with the interrupt handler function. It does: if (dev-host_irq_disabled) { enable_irq(dev-host_irq); dev-host_irq_disabled = false; } If an interrupt triggers before the

[patch 2/4] KVM: x86: wake up waitqueue before calling get_cpu()

2009-04-27 Thread mtosatti
From: Jan Blunck jblu...@suse.de This moves the get_cpu() call down to be called after we wake up the waiters. Therefore the waitqueue locks can savely be rt mutex. Signed-off-by: Jan Blunck jblu...@suse.de Signed-off-by: Sven-Thorsten Dietrich s...@thebigcorporation.com Signed-off-by: Marcelo

boot problems with if=virtio

2009-04-27 Thread Andrew Theurer
I know there have been a couple other threads here about booting with if=virtio, but I think this might be a different problem, not sure: I am using kvm.git (41b76d8d0487c26d6d4d3fe53c1ff59b3236f096) and qemu-kvm.git (8f7a30dbc40a1d4c09275566f9ed9647ed1ee50f) and linux 2.6.20-rc3 It appears to

Re: [PATCH 1/2] KVM: Discard shadow_mt_mask

2009-04-27 Thread Marcelo Tosatti
On Mon, Apr 27, 2009 at 05:47:44PM +0800, Sheng Yang wrote: mt_mask is out of date, now it have only been used as a flag to indicate if TDP enabled. Get rid of it and use tdp_enabled instead. Signed-off-by: Sheng Yang sh...@linux.intel.com --- arch/x86/include/asm/kvm_host.h |2 +-

Re: [PATCH] kvm-userspace: Make PC speaker emulation aware of in-kernel PIT

2009-04-27 Thread Marcelo Tosatti
On Thu, Apr 23, 2009 at 10:24:05PM +0200, Jan Kiszka wrote: When using the in-kernel PIT the speaker emulation has to synchronize the PIT state with KVM. Enhance the existing speaker sound device and allow it to take over port 0x61 by using KVM_CREATE_PIT_NOSPKR when available. This unbreaks

Re: [PATCH 5/5] add ksm kernel shared memory driver.

2009-04-27 Thread Andrew Morton
On Mon, 20 Apr 2009 04:36:06 +0300 Izik Eidus iei...@redhat.com wrote: Ksm is driver that allow merging identical pages between one or more applications in way unvisible to the application that use it. Pages that are merged are marked as readonly and are COWed when any application try to

Re: Boot problems with qemu-kvm

2009-04-27 Thread Cam Macdonell
Cam Macdonell wrote: Hi, I've tried booting two VMs (Ubuntu and Fedora 11) that previously worked with the latest kvm-userspace. At start, I get the following warning: Could not open '/dev/kqemu' - QEMU acceleration layer not activated: No such file or directory But, booting proceeds

Re: [PATCH 5/5] add ksm kernel shared memory driver.

2009-04-27 Thread Izik Eidus
Andrew Morton wrote: On Mon, 20 Apr 2009 04:36:06 +0300 Izik Eidus iei...@redhat.com wrote: Ksm is driver that allow merging identical pages between one or more applications in way unvisible to the application that use it. Pages that are merged are marked as readonly and are COWed when any

Re: bad virtio disk performance

2009-04-27 Thread john cooper
Lucas Nussbaum wrote: On 27/04/09 at 13:36 -0400, john cooper wrote: Lucas Nussbaum wrote: non-virtio: kvm -drive file=/tmp/debian-amd64.img,if=scsi,cache=writethrough -net nic,macaddr=00:16:3e:5a:28:1,model=e1000 -net tap -nographic -kernel /boot/vmlinuz-2.6.29 -initrd

Re: [PATCH 1/2] KVM: Discard shadow_mt_mask

2009-04-27 Thread Sheng Yang
On Tuesday 28 April 2009 06:27:22 Marcelo Tosatti wrote: On Mon, Apr 27, 2009 at 05:47:44PM +0800, Sheng Yang wrote: mt_mask is out of date, now it have only been used as a flag to indicate if TDP enabled. Get rid of it and use tdp_enabled instead. Signed-off-by: Sheng Yang

Re: OT: Intel-Matrix for VT-capability?

2009-04-27 Thread Marc Bevand
Arnd Bergmann arnd at arndb.de writes: http://en.wikipedia.org/wiki/List_of_Intel_Core_2_microprocessors is quite good here. As a rule of thumb, anything higher than 6000 will have VT, anything below 6000 will not. Interesting exceptions are Doesn't have VT: E7300, Q8200, Q8400, E8190

Re: [PATCH] kvm-userspace: Make PC speaker emulation aware of in-kernel PIT

2009-04-27 Thread David S. Ahern
Anthony Liguori wrote: Jan Kiszka wrote: Anthony Liguori wrote: Marcelo Tosatti wrote: Jan, While the patch itself looks fine, IMO it would be better to move all of the timer handling to userspace, except the performance critical parts, since most of it is generic. Either

[COMMIT maint/2.6.30] Merge commit 'qemu-svn/stable_0_10' into maint/2.6.30

2009-04-27 Thread Avi Kivity
From: Avi Kivity a...@redhat.com * commit 'qemu-svn/stable_0_10': Fix savevm after BDRV_FILE size enforcement stop dirty tracking just at the end of migration (Glauber Costa) create qemu_file_set_error (Glauber Costa) propagate error on failed completion (Glauber Costa) qcow2: fix image

[COMMIT maint/2.6.30] kvm: libkvm: Compile with correct kernel include directory

2009-04-27 Thread Avi Kivity
From: Avi Kivity a...@redhat.com Signed-off-by: Avi Kivity a...@redhat.com diff --git a/configure b/configure index dfbff37..df4d686 100755 --- a/configure +++ b/configure @@ -1679,7 +1679,7 @@ configure_kvm() { \( $cpu = i386 -o $cpu = x86_64 -o $cpu = ia64 -o $cpu = powerpc \);

[COMMIT maint/2.6.30] Build libkvm from libkvm directory in new layout

2009-04-27 Thread Avi Kivity
From: Avi Kivity a...@redhat.com Signed-off-by: Avi Kivity a...@redhat.com diff --git a/Makefile.target b/Makefile.target index 9ec7068..440857e 100644 --- a/Makefile.target +++ b/Makefile.target @@ -605,7 +605,7 @@ endif ifdef CONFIG_KVM_KERNEL_INC CFLAGS += -I $(CONFIG_KVM_KERNEL_INC) LIBS

  1   2   >