[PATCH] kvm: qemu: remove some unused variables

2008-08-19 Thread Avi Kivity
From: Jan Kiszka [EMAIL PROTECTED] This patch addresses all current warnings regarding unused variables in KVM userspace. Signed-off-by: Jan Kiszka [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] diff --git a/qemu/exec.c b/qemu/exec.c index 7a37dfd..37c8392 100644 ---

[PATCH] kvm: qemu: Add missing DEPLIBS in Makefile.target

2008-08-19 Thread Avi Kivity
From: Sheng Yang [EMAIL PROTECTED] Seems this flags is missing during merging long ago... And this result in updating of libkvm.a didn't affect make process of qemu, which is very puzzling... Signed-off-by: Sheng Yang [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] diff --git

[PATCH] kvm: bios: end AP boot code execution in rombios

2008-08-19 Thread Avi Kivity
From: Sebastian Herbszt [EMAIL PROTECTED] Jump to rombios before executing the halt loop. Signed-off-by: Sebastian Herbszt [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] diff --git a/bios/rombios32start.S b/bios/rombios32start.S index c4f3366..aaed78b 100644 ---

[PATCH] kvm: qemu: include header for register_ioport_write

2008-08-19 Thread Avi Kivity
From: Jan Kiszka [EMAIL PROTECTED] Signed-off-by: Jan Kiszka [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] diff --git a/qemu/kvm-tpr-opt.c b/qemu/kvm-tpr-opt.c index ab33ea0..122d8c3 100644 --- a/qemu/kvm-tpr-opt.c +++ b/qemu/kvm-tpr-opt.c @@ -12,6 +12,7 @@ #include string.h

[PATCH] kvm: qemu: work around dhclient brokenness

2008-08-19 Thread Avi Kivity
From: Anthony Liguori [EMAIL PROTECTED] With the latest GSO/csum offload patches, any guest using an unpatched version of dhclient (any Ubuntu guest, for instance), will no longer be able to get a DHCP address. dhclient is actually at fault here. It uses AF_PACKET to receive DHCP responses but

[PATCH] KVM: Fix KVM_GET_LAPIC using wrong size

2008-08-19 Thread Avi Kivity
From: Sheng Yang [EMAIL PROTECTED] Which caused migration fail in recent commits. Signed-off-by: Sheng Yang [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index ee005a6..4a03375 100644 --- a/arch/x86/kvm/x86.c +++

[PATCH] KVM: Device assignment: Check for privileges before assigning irq

2008-08-19 Thread Avi Kivity
From: Amit Shah [EMAIL PROTECTED] Even though we don't share irqs at the moment, we should ensure regular user processes don't try to allocate system resources. We check for capability to access IO devices (CAP_SYS_RAWIO) before we request_irq on behalf of the guest. Noticed by Avi.

[PATCH] KVM: VMX: Add module parameter and emulation flag.

2008-08-19 Thread Avi Kivity
From: Mohammed Gamal [EMAIL PROTECTED] The patch adds the module parameter required to enable emulating invalid guest state, as well as the emulation_required flag used to drive emulation whenever needed. Signed-off-by: Mohammed Gamal [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED]

[PATCH] KVM: VMX: Modify mode switching and vmentry functions

2008-08-19 Thread Avi Kivity
From: Mohammed Gamal [EMAIL PROTECTED] This patch modifies mode switching and vmentry function in order to drive invalid guest state emulation. Signed-off-by: Mohammed Gamal [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c index

[PATCH] KVM: ia64: add a dummy irq ack notification

2008-08-19 Thread Avi Kivity
From: Xiantao Zhang [EMAIL PROTECTED] Before enabling notify_acked_irq for ia64, leave the related APIs as nop-op first. Signed-off-by: Xiantao Zhang [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] diff --git a/arch/ia64/kvm/irq.h b/arch/ia64/kvm/irq.h new file mode 100644 index

Re: [PATCH] Work around dhclient brokenness

2008-08-19 Thread Rusty Russell
On Tuesday 19 August 2008 15:17:08 Herbert Xu wrote: On Mon, Aug 18, 2008 at 10:13:55PM -0700, Chris Wedgwood wrote: CSUM2 sounds so ugly though. Features seem to get added and never removed how about if this had a documented short lifetime (if it really must go in)? All we need is

Re: [PATCH] Work around dhclient brokenness

2008-08-19 Thread Avi Kivity
Rusty Russell wrote: On Monday 18 August 2008 21:44:25 Herbert Xu wrote: On Mon, Aug 18, 2008 at 02:40:55PM +0300, Avi Kivity wrote: Isn't that turned on automatically for real hardware? And what's to prevent a broken dhclient together with the (presumably) hacked up initscripts that

Re: [PATCH] Work around dhclient brokenness

2008-08-19 Thread Rusty Russell
On Tuesday 19 August 2008 15:28:40 Chris Wedgwood wrote: On Tue, Aug 19, 2008 at 03:17:08PM +1000, Herbert Xu wrote: All we need is a simple toggle to disable checksum offload. Every NIC that offers receive checksum offload allows it to be disabled. virtio shouldn't be any different. So

[PATCH] Fix KVM/IA-64 build issue in latest kvm.git.

2008-08-19 Thread Zhang, Xiantao
From d53dfacedea40213382694229700d02bfa72d923 Mon Sep 17 00:00:00 2001 From: Xiantao Zhang [EMAIL PROTECTED] Date: Tue, 19 Aug 2008 17:33:21 +0800 Subject: [PATCH] KVM: KVM/IA-64: Fix kvm/ia64's build issue. Disable irq ack notification for ia64. Signed-off-by: Xiantao Zhang [EMAIL PROTECTED] ---

Re: [PATCH] Work around dhclient brokenness

2008-08-19 Thread Herbert Xu
On Tue, Aug 19, 2008 at 07:08:23PM +1000, Rusty Russell wrote: Not really. We could extend the protocol, but that's currently how feature negotiation works: you can't do it while the device is live. That seemed simplest. I learnt from Xen :) (Of course, we don't need to *disable* it,

Re: [PATCH] Fix KVM/IA-64 build issue in latest kvm.git.

2008-08-19 Thread Avi Kivity
Zhang, Xiantao wrote: From d53dfacedea40213382694229700d02bfa72d923 Mon Sep 17 00:00:00 2001 From: Xiantao Zhang [EMAIL PROTECTED] Date: Tue, 19 Aug 2008 17:33:21 +0800 Subject: [PATCH] KVM: KVM/IA-64: Fix kvm/ia64's build issue. Disable irq ack notification for ia64. Signed-off-by: Xiantao

Re: Un-googlable

2008-08-19 Thread Jurrit de Vries
David Abrahams wrote: Serious question: has anyone considered changing the name of this project? Finding information about kvm on the web is extremely frustrating due to the enormous number of pages related to KVM switches and the heavily overlapping target audience (people who want to run

RE: [PATCH] Fix KVM/IA-64 build issue in latest kvm.git.

2008-08-19 Thread Zhang, Xiantao
OK, also fine to me! Attached the updated patch. Thanks Xiantao Avi Kivity wrote: Zhang, Xiantao wrote: From d53dfacedea40213382694229700d02bfa72d923 Mon Sep 17 00:00:00 2001 From: Xiantao Zhang [EMAIL PROTECTED] Date: Tue, 19 Aug 2008 17:33:21 +0800 Subject: [PATCH] KVM: KVM/IA-64: Fix

Re: [PATCH] Work around dhclient brokenness

2008-08-19 Thread Avi Kivity
Anthony Liguori wrote: I'd still like a way to disable it from the host. Even when it does nothing it will force the header into the host cache, which may be different from the guest cache. It's already in the host cache as we don't have a zero copy API right now. I'm thinking of the

Re: [PATCH] Fix KVM/IA-64 build issue in latest kvm.git.

2008-08-19 Thread Avi Kivity
Zhang, Xiantao wrote: OK, also fine to me! Attached the updated patch. Applied, thanks (modified to static inline to avoid warnings). -- 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

[PATCH] Work around dhclient brokenness (v2)

2008-08-19 Thread Anthony Liguori
With the latest GSO/csum offload patches, any guest using an unpatched version of dhclient (any Ubuntu guest, for instance), will no longer be able to get a DHCP address. dhclient is actually at fault here. It uses AF_PACKET to receive DHCP responses but does not check auxdata to see if the

Re: [PATCH] Work around dhclient brokenness (v2)

2008-08-19 Thread Avi Kivity
Anthony Liguori wrote: With the latest GSO/csum offload patches, any guest using an unpatched version of dhclient (any Ubuntu guest, for instance), will no longer be able to get a DHCP address. dhclient is actually at fault here. It uses AF_PACKET to receive DHCP responses but does not check

[no subject]

2008-08-19 Thread Mehul Chadha
subscribe kvm -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html

[PATCH 1/4] Extend virtio config routines to support ballooning

2008-08-19 Thread Anthony Liguori
This patch updates the virtio device methods to provide hooks for setting and getting the config. This is needed for ballooning since the balloon driver uses config changes to signal changes in the balloon amount. We also add a method to signal that we have changed the config. Signed-off-by:

[PATCH 2/4] libkvm: add kvm_has_mmu_notifiers

2008-08-19 Thread Anthony Liguori
This patch adds a kvm_has_mmu_notifiers routine to libkvm. This allows userspace to query the existence of mmu notifiers which is important for ballooning since madvise() is not safe from userspace without it. Signed-off-by: Anthony Liguori [EMAIL PROTECTED] diff --git a/libkvm/libkvm.c

[PATCH 3/4] add ballooning infrastructure to QEMU

2008-08-19 Thread Anthony Liguori
This patch adds a ballooning infrastructure to QEMU. This includes a pair of monitor commands, balloon and info balloon, to balloon a guest and to query the guest's balloon status. Signed-off-by: Anthony Liguori [EMAIL PROTECTED] diff --git a/qemu/balloon.h b/qemu/balloon.h new file mode 100644

[PATCH 4/4] Add virtio balloon driver

2008-08-19 Thread Anthony Liguori
This patch adds the virtio balloon driver. It doesn't actually reduce the RSS size when using KVM (although it does when using -no-kvm). This is because even with MMU notifiers, we're holding a reference to each page in the shadow page table. Once we switch to not taking a reference for pages

Re: [PATCH] Work around dhclient brokenness

2008-08-19 Thread Chris Wedgwood
On Tue, Aug 19, 2008 at 07:10:44PM +1000, Rusty Russell wrote: We need both. CSUM2 is the new virtio-level feature. Perhaps that's what I'm misisng. How is this different to CSUM? -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a message to [EMAIL PROTECTED]

Re: serial/ rs232 and qemu /kvm?

2008-08-19 Thread Glauber Costa
On Tue, Aug 19, 2008 at 11:24 AM, Marc Weber [EMAIL PROTECTED] wrote: First of all, is this the mailinglist to ask this question? Or should I ask it on the qemu lists? I'd like to run WinXP/ Vista within kvm and do microcontroller programming. My host is linux of course. I had some success

Re: Migrating Vm's from one machine to another...and back

2008-08-19 Thread Jean-Pierre Dion
Hi Chris, thank you for your advice. I tried but did not succeed yet. I experienced some issues with tcp mode. I will retry when I am back from vacation next week. I will tell you. jean-pierre This message was sent using IMP,

Re: serial/ rs232 and qemu /kvm?

2008-08-19 Thread Michael Malone
I have been trying to use kvm to do some microcontroller programming, mostly with success - until I want to send an ascii NULL down the port. (I don't know what's going on there, but if you have any ideas, that would be fantastic)Our communication protocol is very touchy about speeds, so the

Re: serial/ rs232 and qemu /kvm?

2008-08-19 Thread Charles Duffy
Michael Malone wrote: If you're trying to use virt-manager, then don't. Virt-manager stops you from having access to a bunch of the underlying features of kvm/qemu such as serial ports. I'm told they're working on it, but it's only useful for a basic setup at the moment. Serial ports *are*

Re: serial/ rs232 and qemu /kvm?

2008-08-19 Thread Michael Malone
Charles Duffy wrote: Michael Malone wrote: If you're trying to use virt-manager, then don't. Virt-manager stops you from having access to a bunch of the underlying features of kvm/qemu such as serial ports. I'm told they're working on it, but it's only useful for a basic setup at the

[PATCH] Use .fixup instead of .text.fixup on __kvm_handle_fault_on_reboot

2008-08-19 Thread Eduardo Habkost
[oops. sent it to the old kvm-devel list. sending to the right list, now] vmlinux.lds expects the fixup code to be on a section named .fixup. The .text.fixup section is not mentioned on vmlinux.lds, and is included on the resulting vmlinux (just after .text) only because of ld heuristics on

Re: [PATCH] kvm: bios: end AP boot code execution in rombios

2008-08-19 Thread Sebastian Herbszt
Avi Kivity wrote: .code16 smp_ap_boot_code_start: + cli Redundant (but no harm done). I added it so it's explicit this code is run with IF=0. Kind of serves a documentation purpose so we don't have to look up whether the cpu starts with IF=0 or not. - Sebastian -- To unsubscribe

Re: [patch 0/2] do not run halted vcpu's

2008-08-19 Thread Marcelo Tosatti
On Sun, Aug 17, 2008 at 10:41:07AM +0300, Avi Kivity wrote: Avi Kivity wrote: Marcelo Tosatti wrote: KVM: x86: do not execute halted vcpus Alright, need_resched was actually checked in vcpu_enter_guest, so this checks signal_pending too: Offline or uninitialized vcpu's can be executed if

[RFC][PATCH]Problems with hpet on kvm

2008-08-19 Thread Beth Kon
I've been playing with my hpet patch on kvm and seeing some strange behavior. The patch I've been using is attached below. /usr/local/bin/qemu-system-x86_64 -boot cd -hda /home/beth/images/ubuntu_server_8.04_10G.img -m 1024 -net nic,model=e1000 -net user -smp 2 -vnc :1 With the above command

Re: [PATCH] Work around dhclient brokenness

2008-08-19 Thread Anthony Liguori
Rusty Russell wrote: On Tuesday 19 August 2008 15:17:08 Herbert Xu wrote: On Mon, Aug 18, 2008 at 10:13:55PM -0700, Chris Wedgwood wrote: CSUM2 sounds so ugly though. Features seem to get added and never removed how about if this had a documented short lifetime (if it really must

Re: madvise() not triggering page discard with MMU-notifiers

2008-08-19 Thread Marcelo Tosatti
Hi Anthony, On Mon, Aug 18, 2008 at 05:04:25PM -0500, Anthony Liguori wrote: Attached is an updated migration patch. It does not appear, however, that madvise() is triggering discarding of pages even with an MMU-notifier enabled kernel. I take it that this is because we're still

Re: [PATCH] x86 emulator: Simplify emulating Grp4/Grp5 instructions.

2008-08-19 Thread Mohammed Gamal
On Tue, Aug 19, 2008 at 1:17 AM, Mohammed Gamal [EMAIL PROTECTED] wrote: emulate_grp45() always returns 0. Therefore there is no need to check its return value. Signed-off-by: Mohammed Gamal [EMAIL PROTECTED] --- arch/x86/kvm/x86_emulate.c |4 +--- 1 files changed, 1 insertions(+), 3

[PATCH] x86 emulator: Add call near absolute (opcode 0xff rm/2)

2008-08-19 Thread Mohammed Gamal
This adds the near call with absolute address instruction. Signed-off-by: Mohammed Gamal [EMAIL PROTECTED] --- arch/x86/kvm/x86_emulate.c | 55 +-- 1 files changed, 37 insertions(+), 18 deletions(-) diff --git a/arch/x86/kvm/x86_emulate.c

Re: [patch 0/2] do not run halted vcpu's

2008-08-19 Thread Avi Kivity
Marcelo Tosatti wrote: On Sun, Aug 17, 2008 at 10:41:07AM +0300, Avi Kivity wrote: Avi Kivity wrote: Marcelo Tosatti wrote: KVM: x86: do not execute halted vcpus Alright, need_resched was actually checked in vcpu_enter_guest, so this checks signal_pending too: Offline or

Re: [PATCH 4/4] kvmppc: convert wrteei to wrtee as kvm guest optimization

2008-08-19 Thread Arnd Bergmann
On Tuesday 19 August 2008, [EMAIL PROTECTED] wrote: Dependent on the already existing CONFIG_KVM_GUEST config option this patch changes wrteei to wrtee allowing the hypervisor to rewrite those to nontrapping instructions. Maybe we should split the kvm guest otpimizations in two parts one for

Re: [PATCH 1/4] kvmppc: read device tree hypervisor node infrastructure

2008-08-19 Thread Josh Boyer
On Tue, 2008-08-19 at 07:52 -0400, Josh Boyer wrote: On Tue, 2008-08-19 at 12:36 +0200, [EMAIL PROTECTED] wrote: diff --git a/arch/powerpc/kernel/kvm.c b/arch/powerpc/kernel/kvm.c new file mode 100644 --- /dev/null +++ b/arch/powerpc/kernel/kvm.c @@ -0,0 +1,30 @@ +#include