RE: [PATCH v15 00/17] Provide a zero-copy method on KVM virtio-net.

2010-11-17 Thread Xin, Xiaohui
-Original Message- From: kvm-ow...@vger.kernel.org [mailto:kvm-ow...@vger.kernel.org] On Behalf Of Xin, Xiaohui Sent: Thursday, November 11, 2010 4:28 PM To: David Miller Cc: net...@vger.kernel.org; kvm@vger.kernel.org; linux-ker...@vger.kernel.org; m...@redhat.com; mi...@elte.hu;

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

2010-11-17 Thread Avi Kivity
On 11/16/2010 08:26 PM, Jan Kiszka wrote: Am 16.11.2010 17:55, Marcelo Tosatti wrote: On Mon, Nov 08, 2010 at 12:21:44PM +0100, Jan Kiszka wrote: Nine patches (yeah, it's getting more and more) to improve classic device assigment /wrt IRQs. Highlight is the last one that resolves the

Re: [PATCH v5-light 0/6] KVM: Improve IRQ assignment for device passthrough

2010-11-17 Thread Avi Kivity
On 11/16/2010 11:30 PM, Jan Kiszka wrote: This is the rebased light version of the previous series, i.e. without PCI-2.3-based IRQ masking or any SRCU conversion. PCI-2.3 support is under rework to explore options for automatic mode switches. Looks good, especially the threaded irq - a real

Re: [Qemu-devel] [PATCH v2 2/2] RAM API: Make use of it for x86 PC

2010-11-17 Thread Gleb Natapov
On Tue, Nov 16, 2010 at 02:24:06PM -0700, Alex Williamson wrote: On Tue, 2010-11-16 at 08:58 -0600, Anthony Liguori wrote: On 11/01/2010 10:14 AM, Alex Williamson wrote: Register the actual VM RAM using the new API Signed-off-by: Alex Williamsonalex.william...@redhat.com ---

[PATCH v3 0/2] Type-safe ioport callbacks

2010-11-17 Thread Avi Kivity
A not-so-recent qemu - qemu-kvm merge broke cpu hotplug without the compiler complaining because of the type-unsafeness of the ioport callbacks. This patchset adds a type-safe variant of ioport callbacks and coverts a sample ioport. Converting the other 300-odd registrations is left as an

[PATCH v3 2/2] piix4 acpi: convert io BAR to type-safe ioport callbacks

2010-11-17 Thread Avi Kivity
Acked-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Avi Kivity a...@redhat.com --- hw/acpi_piix4.c | 55 ++- 1 files changed, 22 insertions(+), 33 deletions(-) diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c index f549089..173d781

[PATCH v3 1/2] Type-safe ioport callbacks

2010-11-17 Thread Avi Kivity
The current ioport callbacks are not type-safe, in that they accept an opaque pointer as an argument whose type must match the argument to the registration function; this is not checked by the compiler. This patch adds an alternative that is type-safe. Instead of an opaque argument, both

[PATCH] KVM test: Minor enhancement for kdump

2010-11-17 Thread Jason Wang
Make the crash kerenl prob command could be configurated. Use carshkernel=128M instead of crashkerenl=1...@64m. Signed-off-by: Jason Wang jasow...@redhat.com --- client/tests/kvm/tests/kdump.py| 10 ++ client/tests/kvm/tests_base.cfg.sample |4 +++- 2 files changed, 9

[PATCH 1/2] KVM test: Support params for netdev

2010-11-17 Thread Jason Wang
Qemu-kvm can config the netdev through its command line parameters, this patch add the support for it and user could use pass params like sndbuf to qemu through netdev_extra_params in config file. Signed-off-by: Jason Wang jasow...@redhat.com --- client/tests/kvm/kvm_vm.py |8 1

[PATCH 2/2] KVM test: Let vhost use netdev_extra_params

2010-11-17 Thread Jason Wang
As we have a more generic support for netdev configuration, this patch enable the vhost through netdev_extra_params. Signed-off-by: Jason Wang jasow...@redhat.com --- client/tests/kvm/tests_base.cfg.sample |8 +--- 1 files changed, 5 insertions(+), 3 deletions(-) diff --git

Re: [PATCH v5-light 0/6] KVM: Improve IRQ assignment for device passthrough

2010-11-17 Thread Michael S. Tsirkin
On Tue, Nov 16, 2010 at 10:30:01PM +0100, Jan Kiszka wrote: This is the rebased light version of the previous series, i.e. without PCI-2.3-based IRQ masking or any SRCU conversion. PCI-2.3 support is under rework to explore options for automatic mode switches. Jan Kiszka (6): KVM: Clear

[PATCH 1/2] KVM: x86 emulator: drop unused #ifndef __KERNEL__

2010-11-17 Thread Avi Kivity
Signed-off-by: Avi Kivity a...@redhat.com --- arch/x86/kvm/emulate.c |7 --- 1 files changed, 0 insertions(+), 7 deletions(-) diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c index 38b6e8d..ffd6e01 100644 --- a/arch/x86/kvm/emulate.c +++ b/arch/x86/kvm/emulate.c @@ -20,16

[PATCH 0/2] Minor emulator cleanups

2010-11-17 Thread Avi Kivity
A couple of trivial patches that clean up a bit of cruft from the emulator. Avi Kivity (2): KVM: x86 emulator: drop unused #ifndef __KERNEL__ KVM: x86 emulator: drop DPRINTF() arch/x86/kvm/emulate.c | 14 +- 1 files changed, 1 insertions(+), 13 deletions(-) -- 1.7.3.1 -- To

[PATCH 2/2] KVM: x86 emulator: drop DPRINTF()

2010-11-17 Thread Avi Kivity
Failed emulation is reported via a tracepoint; the cmps printk is pointless. Signed-off-by: Avi Kivity a...@redhat.com --- arch/x86/kvm/emulate.c |7 +-- 1 files changed, 1 insertions(+), 6 deletions(-) diff --git a/arch/x86/kvm/emulate.c b/arch/x86/kvm/emulate.c index ffd6e01..3325b47

[PATCH 0/2] Introduce segmented addresses to the emulator

2010-11-17 Thread Avi Kivity
Currently we lose segment information associated with memory operands. This prevents us from doing proper segment checks. This patchset prepares the way by remembering which segment is associated with a memory operand. Avi Kivity (2): KVM: x86 emulator: preserve an operand's segment identity

[PATCH 2/2] KVM: x86 emulator: do not perform address calculations on linear addresses

2010-11-17 Thread Avi Kivity
Linear addresses are supposed to already have segment checks performed on them; if we play with these addresses the checks become invalid. Signed-off-by: Avi Kivity a...@redhat.com --- arch/x86/kvm/emulate.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git

[PATCH 1/2] KVM: x86 emulator: preserve an operand's segment identity

2010-11-17 Thread Avi Kivity
Currently the x86 emulator converts the segment register associated with an operand into a segment base which is added into the operand address. This loss of information results in us not doing segment limit checks properly. Replace struct operand's addr.mem field by a segmented_address structure

[RFC PATCH] KVM test: Introduce a command-line wrapper

2010-11-17 Thread Jason Wang
This patch adds a command line wrapper in order make it easier to let user to run dedicated tests with specified params. The idea is simple: user specifiy the test params through commnad line, then wrapper modifiy the configuration file automatically. This is possible as the variants limitations

[PATCH v2] device-assignment: register a reset function

2010-11-17 Thread Bernhard Kohl
This is necessary because during reboot of a VM the assigned devices continue DMA transfers which causes memory corruption. Signed-off-by: Thomas Ostler thomas.ost...@nsn.com Signed-off-by: Bernhard Kohl bernhard.k...@nsn.com --- Changes v1 - v2: - use defined macros, e.g. PCI_COMMAND - write all

[PATCH v2 0/2] Introduce segmented addresses to the emulator

2010-11-17 Thread Avi Kivity
Currently we lose segment information associated with memory operands. This prevents us from doing proper segment checks. This patchset prepares the way by remembering which segment is associated with a memory operand. Avi Kivity (2): KVM: x86 emulator: preserve an operand's segment identity

[PATCH v2 1/2] KVM: x86 emulator: preserve an operand's segment identity

2010-11-17 Thread Avi Kivity
Currently the x86 emulator converts the segment register associated with an operand into a segment base which is added into the operand address. This loss of information results in us not doing segment limit checks properly. Replace struct operand's addr.mem field by a segmented_address structure

[PATCH v2 2/2] KVM: x86 emulator: do not perform address calculations on linear addresses

2010-11-17 Thread Avi Kivity
Linear addresses are supposed to already have segment checks performed on them; if we play with these addresses the checks become invalid. Signed-off-by: Avi Kivity a...@redhat.com --- arch/x86/kvm/emulate.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git

Re: [PATCH 6/6] KVM: assigned dev: MSI-X mask support

2010-11-17 Thread Marcelo Tosatti
On Wed, Nov 17, 2010 at 09:29:22AM +0800, Sheng Yang wrote: + adev-msix_mask_bitmap); + memcpy(val, entry[addr % PCI_MSIX_ENTRY_SIZE / sizeof *entry], len); Division by zero? Not quite understand. You mean sizeof *entry or PCI_MSIX_ENTRY_SIZE? Both of them should

Re: [PATCH v3] device-assignment: Register as un-migratable

2010-11-17 Thread Marcelo Tosatti
On Mon, Nov 15, 2010 at 04:11:19PM -0700, Alex Williamson wrote: Use register_device_unmigratable() to declare ourselves as non-migratable. Signed-off-by: Alex Williamson alex.william...@redhat.com --- v3: Use .name instead of repeating pci-assign v2: Use dummy vmsd instead of dummy

Re: [PATCH 6/6] KVM: assigned dev: MSI-X mask support

2010-11-17 Thread Avi Kivity
On 11/15/2010 11:15 AM, Sheng Yang wrote: This patch enable per-vector mask for assigned devices using MSI-X. This patch provided two new APIs: one is for guest to specific device's MSI-X table address in MMIO, the other is for userspace to get information about mask bit. All the mask bit

Re: [PATCH 4/6] KVM: Add kvm_get_irq_routing_entry() func

2010-11-17 Thread Avi Kivity
On 11/15/2010 11:15 AM, Sheng Yang wrote: We need to query the entry later. +int kvm_get_irq_routing_entry(struct kvm *kvm, int gsi, + struct kvm_kernel_irq_routing_entry *entry) +{ + int count = 0; + struct kvm_kernel_irq_routing_entry *ei = NULL; + struct

Re: [PATCH v2] device-assignment: register a reset function

2010-11-17 Thread Marcelo Tosatti
On Tue, Nov 16, 2010 at 03:05:29PM +0100, Bernhard Kohl wrote: This is necessary because during reboot of a VM the assigned devices continue DMA transfers which causes memory corruption. Signed-off-by: Thomas Ostler thomas.ost...@nsn.com Signed-off-by: Bernhard Kohl bernhard.k...@nsn.com

Re: [Qemu-devel] [PATCH v2 1/2] Minimal RAM API support

2010-11-17 Thread Anthony Liguori
On 11/01/2010 10:14 AM, Alex Williamson wrote: This adds a minimum chunk of Anthony's RAM API support so that we can identify actual VM RAM versus all the other things that make use of qemu_ram_alloc. Signed-off-by: Alex Williamsonalex.william...@redhat.com --- Makefile.objs |1 +

Re: [PATCH v5-light 0/6] KVM: Improve IRQ assignment for device passthrough

2010-11-17 Thread Marcelo Tosatti
On Tue, Nov 16, 2010 at 10:30:01PM +0100, Jan Kiszka wrote: This is the rebased light version of the previous series, i.e. without PCI-2.3-based IRQ masking or any SRCU conversion. PCI-2.3 support is under rework to explore options for automatic mode switches. Jan Kiszka (6): KVM: Clear

Re: [PATCH v2 1/6] KVM: MMU: fix forgot flush vcpu tlbs

2010-11-17 Thread Marcelo Tosatti
On Wed, Nov 17, 2010 at 12:10:08PM +0800, Xiao Guangrong wrote: Some paths forgot to flush vcpu tlbs after remove rmap, this patch fix it. Signed-off-by: Xiao Guangrong xiaoguangr...@cn.fujitsu.com --- arch/x86/kvm/mmu.c | 14 +++--- arch/x86/kvm/paging_tmpl.h |1 +

Re: [PATCH v2 2/6] KVM: MMU: don't drop spte if overwrite it from W to RO

2010-11-17 Thread Marcelo Tosatti
On Wed, Nov 17, 2010 at 12:10:50PM +0800, Xiao Guangrong wrote: We just need flush tlb if overwrite a writable spte with a read-only one. And we should move this operation to set_spte() for sync_page path Signed-off-by: Xiao Guangrong xiaoguangr...@cn.fujitsu.com --- arch/x86/kvm/mmu.c

Re: [PATCH v2 2/6] KVM: MMU: don't drop spte if overwrite it from W to RO

2010-11-17 Thread Avi Kivity
On 11/17/2010 05:42 PM, Marcelo Tosatti wrote: On Wed, Nov 17, 2010 at 12:10:50PM +0800, Xiao Guangrong wrote: We just need flush tlb if overwrite a writable spte with a read-only one. And we should move this operation to set_spte() for sync_page path Signed-off-by: Xiao

Re: [PATCH v2 1/6] KVM: MMU: fix forgot flush vcpu tlbs

2010-11-17 Thread Avi Kivity
On 11/17/2010 05:29 PM, Marcelo Tosatti wrote: diff --git a/arch/x86/kvm/paging_tmpl.h b/arch/x86/kvm/paging_tmpl.h index ba00eef..58b4d9a 100644 --- a/arch/x86/kvm/paging_tmpl.h +++ b/arch/x86/kvm/paging_tmpl.h @@ -781,6 +781,7 @@ static int FNAME(sync_page)(struct kvm_vcpu *vcpu,

[PATCHv6 00/16] boot order specification

2010-11-17 Thread Gleb Natapov
I am using open firmware naming scheme to specify device path names. In this version: added SCSI bus support. Pass boot order list as file to firmware. Names look like this on pci machine: /p...@i0cf8/i...@1,1/dr...@1/d...@0 /p...@i0cf8/i...@1/f...@03f1/flo...@1

[PATCHv6 02/16] Introduce new BusInfo callback get_fw_dev_path.

2010-11-17 Thread Gleb Natapov
New get_fw_dev_path callback will be used for build device path usable by firmware in contrast to qdev qemu internal device path. Signed-off-by: Gleb Natapov g...@redhat.com --- hw/qdev.h |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/hw/qdev.h b/hw/qdev.h index

[PATCHv6 04/16] Add get_fw_dev_path callback to ISA bus in qdev.

2010-11-17 Thread Gleb Natapov
Use device ioports to create unique device path. Signed-off-by: Gleb Natapov g...@redhat.com --- hw/isa-bus.c | 16 1 files changed, 16 insertions(+), 0 deletions(-) diff --git a/hw/isa-bus.c b/hw/isa-bus.c index c0ac7e9..c423c1b 100644 --- a/hw/isa-bus.c +++ b/hw/isa-bus.c

[PATCHv6 03/16] Keep track of ISA ports ISA device is using in qdev.

2010-11-17 Thread Gleb Natapov
Store all io ports used by device in ISADevice structure. Signed-off-by: Gleb Natapov g...@redhat.com --- hw/cs4231a.c |1 + hw/fdc.c |3 +++ hw/gus.c |4 hw/ide/isa.c |2 ++ hw/isa-bus.c | 25 + hw/isa.h |4

[PATCHv6 11/16] Add get_dev_path callback to scsi bus.

2010-11-17 Thread Gleb Natapov
Signed-off-by: Gleb Natapov g...@redhat.com --- hw/scsi-bus.c | 23 +++ 1 files changed, 23 insertions(+), 0 deletions(-) diff --git a/hw/scsi-bus.c b/hw/scsi-bus.c index 5a3fd4b..db7482a 100644 --- a/hw/scsi-bus.c +++ b/hw/scsi-bus.c @@ -5,9 +5,12 @@ #include qdev.h

[PATCHv6 05/16] Store IDE bus id in IDEBus structure for easy access.

2010-11-17 Thread Gleb Natapov
Signed-off-by: Gleb Natapov g...@redhat.com --- hw/ide/cmd646.c |4 ++-- hw/ide/internal.h |3 ++- hw/ide/isa.c |2 +- hw/ide/piix.c |4 ++-- hw/ide/qdev.c |3 ++- hw/ide/via.c |4 ++-- 6 files changed, 11 insertions(+), 9 deletions(-) diff --git

[PATCHv6 16/16] Pass boot device list to firmware.

2010-11-17 Thread Gleb Natapov
Signed-off-by: Gleb Natapov g...@redhat.com --- hw/fw_cfg.c | 14 ++ sysemu.h|1 + vl.c| 48 3 files changed, 63 insertions(+), 0 deletions(-) diff --git a/hw/fw_cfg.c b/hw/fw_cfg.c index 7b9434f..20a816f 100644

[PATCHv6 12/16] Add bootindex parameter to net/block/fd device

2010-11-17 Thread Gleb Natapov
If bootindex is specified on command line a string that describes device in firmware readable way is added into sorted list. Later this list will be passed into firmware to control boot order. Signed-off-by: Gleb Natapov g...@redhat.com --- block_int.h |4 +++- hw/e1000.c |4

[PATCHv6 06/16] Add get_fw_dev_path callback to IDE bus.

2010-11-17 Thread Gleb Natapov
Signed-off-by: Gleb Natapov g...@redhat.com --- hw/ide/qdev.c | 13 + 1 files changed, 13 insertions(+), 0 deletions(-) diff --git a/hw/ide/qdev.c b/hw/ide/qdev.c index 88ff657..01a181b 100644 --- a/hw/ide/qdev.c +++ b/hw/ide/qdev.c @@ -24,9 +24,12 @@ /*

[PATCHv6 13/16] Change fw_cfg_add_file() to get full file path as a parameter.

2010-11-17 Thread Gleb Natapov
Change fw_cfg_add_file() to get full file path as a parameter instead of building one internally. Two reasons for that. First caller may need to know how file is named. Second this moves policy of file naming out from fw_cfg. Platform may want to use more then two levels of directories for

[PATCHv6 15/16] Add notifier that will be called when machine is fully created.

2010-11-17 Thread Gleb Natapov
Action that depends on fully initialized device model should register with this notifier chain. Signed-off-by: Gleb Natapov g...@redhat.com --- sysemu.h |2 ++ vl.c | 15 +++ 2 files changed, 17 insertions(+), 0 deletions(-) diff --git a/sysemu.h b/sysemu.h index

[PATCHv6 09/16] Record which USBDevice USBPort belongs too.

2010-11-17 Thread Gleb Natapov
Ports on root hub will have NULL here. This is needed to reconstruct path from device to its root hub to build device path. Signed-off-by: Gleb Natapov g...@redhat.com --- hw/usb-bus.c |3 ++- hw/usb-hub.c |2 +- hw/usb-musb.c |2 +- hw/usb-ohci.c |2 +- hw/usb-uhci.c |2 +-

[PATCHv6 08/16] Add get_fw_dev_path callback for pci bus.

2010-11-17 Thread Gleb Natapov
Signed-off-by: Gleb Natapov g...@redhat.com --- hw/pci.c | 108 - 1 files changed, 85 insertions(+), 23 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index 438c0d1..8514e15 100644 --- a/hw/pci.c +++ b/hw/pci.c @@ -43,12 +43,14 @@

[PATCHv6 14/16] Add bootindex for option roms.

2010-11-17 Thread Gleb Natapov
Extend -option-rom command to have additional parameter ,bootindex=. Signed-off-by: Gleb Natapov g...@redhat.com --- hw/loader.c| 16 +++- hw/loader.h|8 hw/multiboot.c |3 ++- hw/ne2000.c|2 +- hw/nseries.c |4 ++-- hw/palm.c |6

[PATCHv6 10/16] Add get_dev_path callback for usb bus.

2010-11-17 Thread Gleb Natapov
Signed-off-by: Gleb Natapov g...@redhat.com --- hw/usb-bus.c | 42 ++ 1 files changed, 42 insertions(+), 0 deletions(-) diff --git a/hw/usb-bus.c b/hw/usb-bus.c index 256b881..8b4583c 100644 --- a/hw/usb-bus.c +++ b/hw/usb-bus.c @@ -5,11 +5,13 @@

[PATCHv6 01/16] Introduce fw_name field to DeviceInfo structure.

2010-11-17 Thread Gleb Natapov
Add fw_name to DeviceInfo to use in device path building. In contrast to name fw_name should refer to functionality device provides instead of particular device model like name does. Signed-off-by: Gleb Natapov g...@redhat.com --- hw/fdc.c|1 + hw/ide/isa.c|1 + hw/ide/qdev.c

[PATCHv6 07/16] Add get_dev_path callback for system bus.

2010-11-17 Thread Gleb Natapov
Prints out mmio or pio used to access child device. Signed-off-by: Gleb Natapov g...@redhat.com --- hw/pci_host.c |2 ++ hw/sysbus.c | 30 ++ hw/sysbus.h |4 3 files changed, 36 insertions(+), 0 deletions(-) diff --git a/hw/pci_host.c

[PATCH] KVM: Record instruction set in kvm_exit tracepoint

2010-11-17 Thread Avi Kivity
exit_reason's meaning depend on the instruction set; record it so a trace taken on one machine can be interpreted on another. Signed-off-by: Avi Kivity a...@redhat.com --- arch/x86/kvm/svm.c |2 +- arch/x86/kvm/trace.h | 10 -- arch/x86/kvm/vmx.c |2 +- 3 files changed, 10

Re: [PATCH v2 5/6] KVM: MMU: remove 'clear_unsync' parameter

2010-11-17 Thread Marcelo Tosatti
On Wed, Nov 17, 2010 at 12:13:17PM +0800, Xiao Guangrong wrote: Remove it since we can jude it by sp-unsync Signed-off-by: Xiao Guangrong xiaoguangr...@cn.fujitsu.com --- arch/x86/include/asm/kvm_host.h |2 +- arch/x86/kvm/mmu.c |8 arch/x86/kvm/paging_tmpl.h

Re: [PATCH v2 4/6] KVM: MMU: rename 'reset_host_protection' to 'host_writable'

2010-11-17 Thread Marcelo Tosatti
On Wed, Nov 17, 2010 at 12:12:38PM +0800, Xiao Guangrong wrote: From: Lai Jiangshan la...@cn.fujitsu.com Rename it to fix the sense better Signed-off-by: Lai Jiangshan la...@cn.fujitsu.com Signed-off-by: Xiao Guangrong xiaoguangr...@cn.fujitsu.com --- arch/x86/kvm/mmu.c |8

Re: [PATCH v2 3/6] KVM: MMU: don't mark spte notrap if reserved bit set

2010-11-17 Thread Marcelo Tosatti
On Wed, Nov 17, 2010 at 12:11:41PM +0800, Xiao Guangrong wrote: If reserved bit is set, we need inject the #PF with PFEC.RSVD=1, but shadow_notrap_nonpresent_pte injects #PF with PFEC.RSVD=0 only Signed-off-by: Xiao Guangrong xiaoguangr...@cn.fujitsu.com --- arch/x86/kvm/paging_tmpl.h |

Re: [PATCH v2 6/6] KVM: MMU: cleanup update_pte, pte_prefetch and sync_page functions

2010-11-17 Thread Marcelo Tosatti
On Wed, Nov 17, 2010 at 12:13:59PM +0800, Xiao Guangrong wrote: Abstract the same operation to cleanup them Signed-off-by: Xiao Guangrong xiaoguangr...@cn.fujitsu.com --- arch/x86/kvm/mmu.c |3 -- arch/x86/kvm/paging_tmpl.h | 70 ++- 2

Re: [PATCH v2 1/6] KVM: MMU: fix forgot flush vcpu tlbs

2010-11-17 Thread Marcelo Tosatti
On Wed, Nov 17, 2010 at 06:26:51PM +0200, Avi Kivity wrote: On 11/17/2010 05:29 PM, Marcelo Tosatti wrote: diff --git a/arch/x86/kvm/paging_tmpl.h b/arch/x86/kvm/paging_tmpl.h index ba00eef..58b4d9a 100644 --- a/arch/x86/kvm/paging_tmpl.h +++ b/arch/x86/kvm/paging_tmpl.h @@ -781,6

[PATCH] KVM test: build subtest: Add path_to_rom_images

2010-11-17 Thread Lucas Meneghel Rodrigues
In some cases, KVM userspace source might miss the roms needed for it to boot. In those cases, allow people to specify a path_to_rom_images, that will be used to copy roms to the recently compiled qemu-kvm. Signed-off-by: Lucas Meneghel Rodrigues l...@redhat.com ---

early kernel panic in linux guest (div-by-zero in pvclock_tsc_khz)

2010-11-17 Thread Stefan Bühler
Hi, i get an early kernel panic with some kernels: The physical host runs 2.6.32-5-amd64 (debian stable/testing), and uses qemu-kvm/0.12.5+dfsg-4 with libvirt 0.8.3-4. The node is based on debian testing. The host has two cores, the guest uses one. The following tested kernel versions

[no subject]

2010-11-17 Thread satimis
http://www.decaza.com/TER healthtworx.ru cid=extasy.html -- 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] ceph/rbd block driver for qemu-kvm (v8)

2010-11-17 Thread Christian Brunner
Here is another update for the ceph storage driver. It includes changes for the annotations Stefan made last week and a bit more things Sage discovered while looking over the driver again. I really hope that this time we are not only close, but have reached a quality that everyone is satisfied

Re: [PATCHv4 15/15] Pass boot device list to firmware.

2010-11-17 Thread Blue Swirl
2010/11/16 Gleb Natapov g...@redhat.com: On Tue, Nov 16, 2010 at 06:30:19PM +, Blue Swirl wrote: Perhaps the FW path should use device class names if no name is specified. What do you mean by device class name. We can do something like this: if (dev-child_bus.lh_first)        return

[PATCH RFC] kvm: fast-path msi injection with irqfd

2010-11-17 Thread Michael S. Tsirkin
Store irq routing table pointer in the irqfd object, and use that to inject MSI directly without bouncing out to a kernel thread. While we touch this structure, rearrange irqfd fields to make fastpath better packed for better cache utilization. Some notes on the design: - Use pointer into the rt

HAL type for Win2003 Server on recent KVM versions?

2010-11-17 Thread Kenni Lund
Hi I'm about to move a couple of virtual machines from a Fedora 11 system to a new server with a more recent operating system and newer version of KVM, etc. One of the guests is a Windows Server 2003 Standard SP2, which is currently running with the ACPI Multiprocessor PC HAL. Considering

Re: [Qemu-devel] [PATCH v2 2/2] RAM API: Make use of it for x86 PC

2010-11-17 Thread Anthony Liguori
On 11/16/2010 03:24 PM, Alex Williamson wrote: On Tue, 2010-11-16 at 08:58 -0600, Anthony Liguori wrote: On 11/01/2010 10:14 AM, Alex Williamson wrote: Register the actual VM RAM using the new API Signed-off-by: Alex Williamsonalex.william...@redhat.com --- hw/pc.c | 12

RE: [PATCH]KVM: VMX: Inform user about INTEL_TXT dependency

2010-11-17 Thread Wang, Shane
After discussing with Joe, we gave it up (i.e. not depend on enabled-inside-smx;) Thanks. Shane -Original Message- From: Jan Kiszka [mailto:jan.kis...@siemens.com] Sent: 2010年11月17日 15:56 To: Wang, Shane Cc: a...@redhat.com; mtosa...@redhat.com; kvm@vger.kernel.org; Cihula, Joseph

[PATCH v4] virtio-9p: fix build on !CONFIG_UTIMENSAT

2010-11-17 Thread Hidetoshi Seto
This patch introduce a fallback mechanism for old systems that do not support utimensat(). This fix build failure with following warnings: hw/virtio-9p-local.c: In function 'local_utimensat': hw/virtio-9p-local.c:479: warning: implicit declaration of function 'utimensat'

Re: [PATCH 6/6] KVM: assigned dev: MSI-X mask support

2010-11-17 Thread Sheng Yang
On Wednesday 17 November 2010 21:58:00 Avi Kivity wrote: On 11/15/2010 11:15 AM, Sheng Yang wrote: This patch enable per-vector mask for assigned devices using MSI-X. This patch provided two new APIs: one is for guest to specific device's MSI-X table address in MMIO, the other is for

Re: [PATCH 1/2] KVM: take kvm_lock for hardware_disable() during cpu hotplug

2010-11-17 Thread Zachary Amsden
On 11/15/2010 10:35 PM, Takuya Yoshikawa wrote: In kvm_cpu_hotplug(), only CPU_STARTING case is protected by kvm_lock. This patch adds missing protection for CPU_DYING case. Signed-off-by: Takuya Yoshikawayoshikawa.tak...@oss.ntt.co.jp --- virt/kvm/kvm_main.c |2 ++ 1 files changed, 2

Re: [PATCH 1/2] KVM: take kvm_lock for hardware_disable() during cpu hotplug

2010-11-17 Thread Takuya Yoshikawa
(2010/11/18 10:59), Zachary Amsden wrote: On 11/15/2010 10:35 PM, Takuya Yoshikawa wrote: In kvm_cpu_hotplug(), only CPU_STARTING case is protected by kvm_lock. This patch adds missing protection for CPU_DYING case. Signed-off-by: Takuya Yoshikawayoshikawa.tak...@oss.ntt.co.jp ---

Re: [PATCH 4/6] KVM: Add kvm_get_irq_routing_entry() func

2010-11-17 Thread Sheng Yang
On Wednesday 17 November 2010 22:01:41 Avi Kivity wrote: On 11/15/2010 11:15 AM, Sheng Yang wrote: We need to query the entry later. +int kvm_get_irq_routing_entry(struct kvm *kvm, int gsi, + struct kvm_kernel_irq_routing_entry *entry) +{ + int count = 0; + struct

Re: [PATCH 1/2] KVM: take kvm_lock for hardware_disable() during cpu hotplug

2010-11-17 Thread Zachary Amsden
On 11/17/2010 04:04 PM, Takuya Yoshikawa wrote: (2010/11/18 10:59), Zachary Amsden wrote: On 11/15/2010 10:35 PM, Takuya Yoshikawa wrote: In kvm_cpu_hotplug(), only CPU_STARTING case is protected by kvm_lock. This patch adds missing protection for CPU_DYING case. Signed-off-by: Takuya

Re: [PATCH 1/2] KVM: take kvm_lock for hardware_disable() during cpu hotplug

2010-11-17 Thread Takuya Yoshikawa
(2010/11/18 11:33), Zachary Amsden wrote: On 11/17/2010 04:04 PM, Takuya Yoshikawa wrote: (2010/11/18 10:59), Zachary Amsden wrote: On 11/15/2010 10:35 PM, Takuya Yoshikawa wrote: In kvm_cpu_hotplug(), only CPU_STARTING case is protected by kvm_lock. This patch adds missing protection for

[RFC PATCH 0/2] KVM: dirty logging optimization

2010-11-17 Thread Takuya Yoshikawa
Hi, Yesterday, I tried to read mmu code but soon came back to dirty logging! -- My brain's tlb flush seems to have a serious bug! Soon after that, I reached to this patch set. What I thought was that I might be able to improve KVM's interactivity in the future if I can suppress write

[RFC PATCH 1/2] KVM: count the number of dirty bits for each memslot

2010-11-17 Thread Takuya Yoshikawa
This patch introduces the counter to hold the number of dirty bits in each memslot. We will use this to optimize dirty logging later. Signed-off-by: Takuya Yoshikawa yoshikawa.tak...@oss.ntt.co.jp --- arch/x86/kvm/x86.c |9 +++-- include/linux/kvm_host.h |1 +

[RFC PATCH 2/2] KVM: selective write protection using dirty bitmap

2010-11-17 Thread Takuya Yoshikawa
Lai Jiangshan once tried to rewrite kvm_mmu_slot_remove_write_access() using rmap: kvm: rework remove-write-access for a slot http://www.spinics.net/lists/kvm/msg35871.html One problem pointed out there was that this approach might hurt cache locality and make things slow down. But if we

Re: [PATCH v2] device-assignment: register a reset function

2010-11-17 Thread Jan Kiszka
Am 16.11.2010 15:37, Alex Williamson wrote: On Tue, 2010-11-16 at 15:05 +0100, Bernhard Kohl wrote: This is necessary because during reboot of a VM the assigned devices continue DMA transfers which causes memory corruption. Signed-off-by: Thomas Ostler thomas.ost...@nsn.com Signed-off-by:

Re: [PATCH 1/2] KVM: take kvm_lock for hardware_disable() during cpu hotplug

2010-11-17 Thread Zachary Amsden
On 11/17/2010 04:41 PM, Takuya Yoshikawa wrote: (2010/11/18 11:33), Zachary Amsden wrote: On 11/17/2010 04:04 PM, Takuya Yoshikawa wrote: (2010/11/18 10:59), Zachary Amsden wrote: On 11/15/2010 10:35 PM, Takuya Yoshikawa wrote: In kvm_cpu_hotplug(), only CPU_STARTING case is protected by

Re: [PATCH 6/6] KVM: assigned dev: MSI-X mask support

2010-11-17 Thread Michael S. Tsirkin
On Thu, Nov 18, 2010 at 09:58:55AM +0800, Sheng Yang wrote: +static int msix_mmio_write(struct kvm_io_device *this, gpa_t addr, int len, + const void *val) +{ + struct kvm_assigned_dev_kernel *adev = + container_of(this, struct

Re: 2.6.37-rc2 after KVM shutdown - unregister_netdevice: waiting for vmtst01eth0 to become free. Usage count = 1

2010-11-17 Thread Nikola Ciprich
Yep, this is a known problem, thanks ! fix is there : http://patchwork.ozlabs.org/patch/71354/ Thanks Eric, this indeed fixes the problem.. I noticed the fix didn't make it to 2.6.37-rc2-git3 though, maybe it just got omited? anyways, thanks for help! n. -- To unsubscribe from

Re: [PATCH 6/6] KVM: assigned dev: MSI-X mask support

2010-11-17 Thread Sheng Yang
On Thursday 18 November 2010 14:21:40 Michael S. Tsirkin wrote: On Thu, Nov 18, 2010 at 09:58:55AM +0800, Sheng Yang wrote: +static int msix_mmio_write(struct kvm_io_device *this, gpa_t addr, int len, + const void *val) +{ + struct

Re: KVM with hugepages generate huge load with two guests

2010-11-17 Thread Dmitry Golubev
Hi, Sorry to bother you again. I have more info: 1. router with 32MB of RAM (hugepages) and 1VCPU ... Is it too much to have 3 guests with hugepages? OK, this router is also out of equation - I disabled hugepages for it. There should be also additional pages available to guests because of

Re: [PATCH v2 2/6] KVM: MMU: don't drop spte if overwrite it from W to RO

2010-11-17 Thread Xiao Guangrong
On 11/17/2010 11:57 PM, Avi Kivity wrote: set_pte: update_spte(sptep, spte); +/* + * If we overwrite a writable spte with a read-only one we + * should flush remote TLBs. Otherwise rmap_write_protect + * will find a read-only spte, even though the writable spte +

Re: [PATCH v2 1/6] KVM: MMU: fix forgot flush vcpu tlbs

2010-11-17 Thread Xiao Guangrong
On 11/18/2010 01:36 AM, Marcelo Tosatti wrote: I don't think we need to flush immediately; set a tlb dirty bit somewhere that is cleareded when we flush the tlb. kvm_mmu_notifier_invalidate_page() can consult the bit and force a flush if set. Yep. Great, i'll do it in the v3. Do we

Re: [PATCH v2 5/6] KVM: MMU: remove 'clear_unsync' parameter

2010-11-17 Thread Xiao Guangrong
On 11/18/2010 12:49 AM, Marcelo Tosatti wrote: bool clear_unsync) +static int FNAME(sync_page)(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp) { int i, offset, nr_present; bool host_writable; @@ -781,7 +780,7 @@ static int FNAME(sync_page)(struct