Re: [kvm-devel] [patch 3/5] KVM: add kvm_follow_page()

2007-12-23 Thread Avi Kivity
Avi Kivity wrote: Avi Kivity wrote: Exactly. But it is better to be explicit about it and pass the page directly like you did before. I hate to make you go back-and-fourth, but I did not understand the issue completely before. btw, the call to gfn_to_page() can happen

Re: [kvm-devel] [patch 3/5] KVM: add kvm_follow_page()

2007-12-23 Thread Avi Kivity
Andrew Morton wrote: On Sun, 23 Dec 2007 10:59:22 +0200 Avi Kivity [EMAIL PROTECTED] wrote: Avi Kivity wrote: Avi Kivity wrote: Exactly. But it is better to be explicit about it and pass the page directly like you did before. I hate to make you go back-and-fourth

Re: [kvm-devel] [Virtio-for-kvm] [PATCH 0/7] userspace virtio

2007-12-23 Thread Avi Kivity
Dor Laor wrote: This patchset updates kvm repository with Anthony's virtio implementation along with rx performance improvements and guest reset handling. The original code was sent to qemu devel list 2 weeks ago. It contains support for network block devices. Using the performance

Re: [kvm-devel] [Virtio-for-kvm] [PATCH 7/7] userspace virtio

2007-12-23 Thread Avi Kivity
Dor Laor wrote: From f244bcad756c4f761627557bb7f315b1d8f22fb2 Mon Sep 17 00:00:00 2001 From: Dor Laor [EMAIL PROTECTED] Date: Thu, 20 Dec 2007 13:26:30 +0200 Subject: [PATCH] [VIRTIO-NET] Rx performance improvement The current performance are not good enough, the problem lies in qemu tap

Re: [kvm-devel] [patch 3/5] KVM: add kvm_follow_page()

2007-12-23 Thread Avi Kivity
Andrew Morton wrote: On Sun, 23 Dec 2007 12:35:30 +0200 Avi Kivity [EMAIL PROTECTED] wrote: Andrew Morton wrote: On Sun, 23 Dec 2007 10:59:22 +0200 Avi Kivity [EMAIL PROTECTED] wrote: Avi Kivity wrote: Avi Kivity wrote: Exactly

[kvm-devel] [PATCH 01/50] KVM: x86 emulator: Add vmmcall/vmcall to x86_emulate (v3)

2007-12-23 Thread Avi Kivity
From: Anthony Liguori [EMAIL PROTECTED] Add vmmcall/vmcall to x86_emulate. Future patch will implement functionality for these instructions. Signed-off-by: Anthony Liguori [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/x86_emulate.c | 23

[kvm-devel] [PATCH 00/50] KVM patch queue review for 2.6.25 merge window (part I)

2007-12-23 Thread Avi Kivity
Following is the first part of the 2.6.25 merge window submission. Since there are 238 patches in the queue (and a few more expected), they'll be sent in five batches of around 50 each. - This SF.net email is sponsored by:

[kvm-devel] [PATCH 02/50] KVM: Refactor hypercall infrastructure (v3)

2007-12-23 Thread Avi Kivity
. [avi: fix #ud injection on vmx] Signed-off-by: Anthony Liguori [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm.h |8 +- drivers/kvm/kvm_main.c| 156 +--- drivers/kvm/svm.c | 19 +- drivers

[kvm-devel] [PATCH 06/50] KVM: emulate_instruction() calls now x86_decode_insn() and x86_emulate_insn()

2007-12-23 Thread Avi Kivity
From: Laurent Vivier [EMAIL PROTECTED] emulate_instruction() calls now x86_decode_insn() and x86_emulate_insn(). x86_emulate_insn() is x86_emulate_memop() without the decoding part. Signed-off-by: Laurent Vivier [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm

[kvm-devel] [PATCH 11/50] KVM: MMU: Ignore reserved bits in cr3 in non-pae mode

2007-12-23 Thread Avi Kivity
an iso. Signed-off-by: Ryan Harper [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm_main.c | 11 --- 1 files changed, 4 insertions(+), 7 deletions(-) diff --git a/drivers/kvm/kvm_main.c b/drivers/kvm/kvm_main.c index da057cf..b10fd7e 100644

[kvm-devel] [PATCH 10/50] KVM: MMU: Make flooding detection work when guest page faults are bypassed

2007-12-23 Thread Avi Kivity
When we allow guest page faults to reach the guests directly, we lose the fault tracking which allows us to detect demand paging. So we provide an alternate mechnism by clearing the accessed bit when we set a pte, and checking it later to see if the guest actually used it. Signed-off-by: Avi

[kvm-devel] [PATCH 07/50] KVM: Call x86_decode_insn() only when needed

2007-12-23 Thread Avi Kivity
-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm.h |8 - drivers/kvm/kvm_main.c| 77 +--- drivers/kvm/svm.c |9 +++-- drivers/kvm/vmx.c |9 +++-- drivers/kvm/x86_emulate.c | 24 -- 5 files

[kvm-devel] [PATCH 08/50] KVM: VMX: Further reduce efer reloads

2007-12-23 Thread Avi Kivity
mode. This is because the syscall instruction is not available in 32-bit mode on Intel processors, so the SCE bit is effectively meaningless. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/vmx.c | 61 1 files changed, 37

[kvm-devel] [PATCH 09/50] KVM: Allow not-present guest page faults to bypass kvm

2007-12-23 Thread Avi Kivity
hardware, as AMD lacks a way to discriminate among page faults based on error code. It is also a little risky since it uses reserved bits which might become unreserved in the future, so a module parameter is provided to disable it. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm

[kvm-devel] [PATCH 05/50] KVM: x86 emulator: move all decoding process to function x86_decode_insn()

2007-12-23 Thread Avi Kivity
From: Laurent Vivier [EMAIL PROTECTED] Split the decoding process into a new function x86_decode_insn(). Signed-off-by: Laurent Vivier [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/x86_emulate.c | 77 +++-- 1 files

[kvm-devel] [PATCH 15/50] KVM: x86_emulator: no writeback for bt

2007-12-23 Thread Avi Kivity
From: Qing He [EMAIL PROTECTED] Signed-off-by: Qing He [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/x86_emulate.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/drivers/kvm/x86_emulate.c b/drivers/kvm/x86_emulate.c index 8b0186f..fe50317

[kvm-devel] [PATCH 17/50] KVM: x86 emulator: Any legacy prefix after a REX prefix nullifies its effect

2007-12-23 Thread Avi Kivity
[EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/x86_emulate.c | 24 +++- 1 files changed, 15 insertions(+), 9 deletions(-) diff --git a/drivers/kvm/x86_emulate.c b/drivers/kvm/x86_emulate.c index fe50317..e6b213b 100644 --- a/drivers/kvm

[kvm-devel] [PATCH 21/50] KVM: Add general accessors to read and write guest memory

2007-12-23 Thread Avi Kivity
From: Izik Eidus [EMAIL PROTECTED](none) Signed-off-by: Izik Eidus [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm.h |9 +++ drivers/kvm/kvm_main.c | 160 +++- drivers/kvm/vmx.c | 43 ++--- 3

[kvm-devel] [PATCH 16/50] KVM: Purify x86_decode_insn() error case management

2007-12-23 Thread Avi Kivity
From: Laurent Vivier [EMAIL PROTECTED] The only valid case is on protected page access, other cases are errors. Signed-off-by: Laurent Vivier [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm_main.c | 10 +++--- 1 files changed, 7 insertions(+), 3 deletions

[kvm-devel] [PATCH 13/50] KVM: x86 emulator: remove _eflags and use directly ctxt-eflags.

2007-12-23 Thread Avi Kivity
From: Laurent Vivier [EMAIL PROTECTED] Remove _eflags and use directly ctxt-eflags. Caching eflags is not needed as it is restored to vcpu by kvm_main.c:emulate_instruction() from ctxt-eflags only if emulation doesn't fail. Signed-off-by: Laurent Vivier [EMAIL PROTECTED] Signed-off-by: Avi

[kvm-devel] [PATCH 19/50] KVM: VMX: Simplify vcpu_clear()

2007-12-23 Thread Avi Kivity
Now that smp_call_function_single() knows how to call a function on the current cpu, there's no need to check explicitly. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/vmx.c |6 +- 1 files changed, 1 insertions(+), 5 deletions(-) diff --git a/drivers/kvm/vmx.c b/drivers

[kvm-devel] [PATCH 04/50] KVM: x86 emulator: move all x86_emulate_memop() to a structure

2007-12-23 Thread Avi Kivity
; }; Signed-off-by: Laurent Vivier [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/x86_emulate.c | 919 - drivers/kvm/x86_emulate.h | 34 ++ 2 files changed, 518 insertions(+), 435 deletions(-) diff --git

[kvm-devel] [PATCH 14/50] KVM: x86 emulator: Remove no_wb, use dst.type = OP_NONE instead

2007-12-23 Thread Avi Kivity
From: Laurent Vivier [EMAIL PROTECTED] Remove no_wb, use dst.type = OP_NONE instead, idea stollen from xen-3.1 Signed-off-by: Laurent Vivier [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/x86_emulate.c | 76 ++-- drivers

[kvm-devel] [PATCH 12/50] KVM: x86 emulator: split some decoding into functions for readability

2007-12-23 Thread Avi Kivity
From: Laurent Vivier [EMAIL PROTECTED] To improve readability, move push, writeback, and grp 1a/2/3/4/5/9 emulation parts into functions. Signed-off-by: Laurent Vivier [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/x86_emulate.c | 451

[kvm-devel] [PATCH 25/50] KVM: Remove gratuitous casts from lapic.c

2007-12-23 Thread Avi Kivity
From: Rusty Russell [EMAIL PROTECTED] Since vcpu-apic is of the correct type, there's not need to cast. Signed-off-by: Rusty Russell [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/lapic.c | 10 +- 1 files changed, 5 insertions(+), 5 deletions(-) diff

[kvm-devel] [PATCH 31/50] KVM: Move guest pte dirty bit management to the guest pagetable walker

2007-12-23 Thread Avi Kivity
This is more consistent with the accessed bit management, and makes the dirty bit available earlier for other purposes. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/mmu.c |5 + drivers/kvm/paging_tmpl.h | 31 --- 2 files changed, 13

[kvm-devel] [PATCH 23/50] KVM: Add kvm_free_lapic() to pair with kvm_create_lapic()

2007-12-23 Thread Avi Kivity
kvm_vcpu_init. 2) Don't set apic-regs_page to zero before freeing apic. Signed-off-by: Rusty Russell [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/irq.h |2 +- drivers/kvm/kvm_main.c |4 +--- drivers/kvm/lapic.c| 19 +-- 3 files

[kvm-devel] [PATCH 24/50] KVM: Hoist kvm_create_lapic() into kvm_vcpu_init()

2007-12-23 Thread Avi Kivity
-off-by: Rusty Russell [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm_main.c | 10 +- drivers/kvm/svm.c |6 -- drivers/kvm/vmx.c |6 -- 3 files changed, 9 insertions(+), 13 deletions(-) diff --git a/drivers/kvm/kvm_main.c b

[kvm-devel] [PATCH 38/50] KVM: apic round robin cleanup

2007-12-23 Thread Avi Kivity
-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/lapic.c | 13 +++-- 1 files changed, 3 insertions(+), 10 deletions(-) diff --git a/drivers/kvm/lapic.c b/drivers/kvm/lapic.c index e15b42e..8840f9d 100644 --- a/drivers/kvm/lapic.c +++ b/drivers/kvm/lapic.c @@ -395,10 +395,9 @@ static

[kvm-devel] [PATCH 40/50] KVM: Move apic timer interrupt backlog processing to common code

2007-12-23 Thread Avi Kivity
Beside the obvious goodness of making code more common, this prevents a livelock with the next patch which moves interrupt injection out of the critical section. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm_main.c |2 ++ drivers/kvm/svm.c |1 - drivers/kvm/vmx.c

[kvm-devel] [PATCH 29/50] KVM: MMU: Clean up MMU functions to take struct kvm when appropriate

2007-12-23 Thread Avi Kivity
need to be called on all VCPUs. Signed-off-by: Anthony Liguori [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/mmu.c | 18 +- drivers/kvm/paging_tmpl.h |4 ++-- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/drivers/kvm

[kvm-devel] [PATCH 36/50] KVM: MMU: When updating the dirty bit, inform the mmu about it

2007-12-23 Thread Avi Kivity
Since the mmu uses different shadow pages for dirty large pages and clean large pages, this allows the mmu to drop ptes that are now invalid. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/paging_tmpl.h |5 + 1 files changed, 5 insertions(+), 0 deletions(-) diff --git

[kvm-devel] [PATCH 35/50] KVM: MMU: Move dirty bit updates to a separate function

2007-12-23 Thread Avi Kivity
Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/paging_tmpl.h | 23 +++ 1 files changed, 15 insertions(+), 8 deletions(-) diff --git a/drivers/kvm/paging_tmpl.h b/drivers/kvm/paging_tmpl.h index 4538b15..a0f84a5 100644 --- a/drivers/kvm/paging_tmpl.h +++ b

[kvm-devel] [PATCH 33/50] KVM: MMU: Disable write access on clean large pages

2007-12-23 Thread Avi Kivity
By forcing clean huge pages to be read-only, we have separate roles for the shadow of a clean large page and the shadow of a dirty large page. This is necessary because different ptes will be instantiated for the two cases, even for read faults. Signed-off-by: Avi Kivity [EMAIL PROTECTED

[kvm-devel] [PATCH 32/50] KVM: MMU: Fix nx access bit for huge pages

2007-12-23 Thread Avi Kivity
We must set the bit before the shift, otherwise the wrong bit gets set. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/paging_tmpl.h |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/kvm/paging_tmpl.h b/drivers/kvm/paging_tmpl.h index da36e48..e07cb2e

[kvm-devel] [PATCH 34/50] KVM: MMU: Instantiate real-mode shadows as user writable shadows

2007-12-23 Thread Avi Kivity
This is consistent with real-mode permissions. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/mmu.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/kvm/mmu.c b/drivers/kvm/mmu.c index e6616a6..f52604a 100644 --- a/drivers/kvm/mmu.c +++ b/drivers/kvm

[kvm-devel] [PATCH 41/50] KVM: Rename KVM_TLB_FLUSH to KVM_REQ_TLB_FLUSH

2007-12-23 Thread Avi Kivity
We now have a new namespace, KVM_REQ_*, for bits in vcpu-requests. Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm.h |2 +- drivers/kvm/kvm_main.c |4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/kvm/kvm.h b/drivers/kvm/kvm.h index

[kvm-devel] [PATCH 42/50] KVM: x86 emulator: Implement emulation of instruction: inc dec

2007-12-23 Thread Avi Kivity
From: Nitin A Kamble [EMAIL PROTECTED] Instructions: inc r16/r32 (opcode 0x40-0x47) dec r16/r32 (opcode 0x48-0x4f) Signed-off-by: Nitin A Kamble [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/x86_emulate.c | 20 ++-- 1 files

[kvm-devel] [PATCH 39/50] KVM: Add some \n in ioapic_debug()

2007-12-23 Thread Avi Kivity
From: Laurent Vivier [EMAIL PROTECTED] Add new-line at end of debug strings. Signed-off-by: Laurent Vivier [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/ioapic.c | 25 ++--- 1 files changed, 14 insertions(+), 11 deletions(-) diff --git

[kvm-devel] [PATCH 22/50] KVM: Allow dynamic allocation of the mmu shadow cache size

2007-12-23 Thread Avi Kivity
From: Izik Eidus [EMAIL PROTECTED] The user is now able to set how many mmu pages will be allocated to the guest. Signed-off-by: Izik Eidus [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm.h |7 ++- drivers/kvm/kvm_main.c | 47

[kvm-devel] [PATCH 20/50] KVM: Remove the usage of page-private field by rmap

2007-12-23 Thread Avi Kivity
the gfn of each gpte in the shadow pages, since the memory slot is addressed by gfn, instead of hfn like struct page. Signed-off-by: Izik Eidus [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm.h |6 ++- drivers/kvm/kvm_main.c| 11 +++- drivers/kvm

[kvm-devel] [PATCH 37/50] KVM: Portability: split kvm_vcpu_ioctl

2007-12-23 Thread Avi Kivity
PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm.h |9 ++ drivers/kvm/kvm_main.c | 200 ++-- drivers/kvm/x86.c | 219 3 files changed, 234 insertions(+), 194 deletions

[kvm-devel] [PATCH 26/50] KVM: CodingStyle cleanup

2007-12-23 Thread Avi Kivity
From: Mike Day [EMAIL PROTECTED] Signed-off-by: Mike D. Day [EMAIL PROTECTED] Signed-off-by: Avi Kivity [EMAIL PROTECTED] --- drivers/kvm/kvm.h | 32 +- drivers/kvm/kvm_main.c| 58 ++ drivers/kvm/lapic.c |3 +- drivers/kvm

Re: [kvm-devel] external module sched_in event

2007-12-23 Thread Avi Kivity
Andrea Arcangeli wrote: On Sat, Dec 22, 2007 at 09:13:44PM +0200, Avi Kivity wrote: Unfortunately, this fails badly on Intel i386: Hmm ok there's a definitive bug that I forgot a int1 kernel-kernel switch on x86 has no special debug stack like on x86-64. This will have a better

Re: [kvm-devel] [PATCH 27/50] KVM: Support assigning userspace memory to the guest

2007-12-23 Thread Avi Kivity
Avi Kivity wrote: From: Izik Eidus [EMAIL PROTECTED] Instead of having the kernel allocate memory to the guest, let userspace allocate it and pass the address to the kernel. This is required for s390 support, but also enables features like memory sharing and using hugetlbfs backed memory

Re: [kvm-devel] [patch 3/5] KVM: add kvm_follow_page()

2007-12-23 Thread Avi Kivity
Marcelo Tosatti wrote: On Sun, Dec 23, 2007 at 10:41:07AM +0200, Avi Kivity wrote: Avi Kivity wrote: Exactly. But it is better to be explicit about it and pass the page directly like you did before. I hate to make you go back-and-fourth, but I did not understand the issue

Re: [kvm-devel] [patch 3/5] KVM: add kvm_follow_page()

2007-12-23 Thread Avi Kivity
Marcelo Tosatti wrote: It can acquire the pagetablelock in the callback handler. But then, vm_normal_page() must also be exported. Are you guys OK with this ? Seems to me that requires fairly detailed mucking in mm details, just to get at a page. I believe that a new

Re: [kvm-devel] Find timing info between two VM exits

2007-12-23 Thread Avi Kivity
avadh patel wrote: Hi All, I was looking into the source code of kvm and modified qemu and trying to find the time spent between two VM-exit in kvm. Is there a way to find this from user-space qemu, without modifying the kernel module or libkvm? What do you mean exactly? Average time

Re: [kvm-devel] external module sched_in event

2007-12-22 Thread Avi Kivity
Andrea Arcangeli wrote: [snip] So in short with the below fix applied, after a write_tsc(0,0), the UP guest never return any error anymore. Previously it would return frequent errors because sched_in wasn't properly invoked by svm.c and it would crash at boot every single time after a

Re: [kvm-devel] [patch 3/5] KVM: add kvm_follow_page()

2007-12-22 Thread Avi Kivity
Marcelo Tosatti wrote: In preparation for a mmu spinlock, avoid schedules in mmu_set_spte() by using follow_page() instead of get_user_pages(). The fault handling work by get_user_pages() now happens outside the lock. Signed-off-by: Marcelo Tosatti [EMAIL PROTECTED] Index:

Re: [kvm-devel] [patch 4/5] KVM: export follow_page()

2007-12-22 Thread Avi Kivity
Marcelo Tosatti wrote: follow_page() is required by KVM to find the struct page which maps to a given address in spinlock protected code. Signed-off-by: Marcelo Tosatti [EMAIL PROTECTED] Index: kvm.quilt/mm/memory.c === ---

Re: [kvm-devel] [patch 0/5] KVM shadow scalability enhancements

2007-12-22 Thread Avi Kivity
Marcelo Tosatti wrote: The following patchset increases KVM shadow scalability by allowing concurrent guest walking, allocation and instruction emulation. Thanks; the split patchset it _much_ easier to review, and hopefully to bisect in case the review misses something. I believe we can

Re: [kvm-devel] [PATCH 0/9] qemu: missing definitions from qemu-cvs merge

2007-12-22 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: The following patch series fixes compilation warnings from kvm 57 triggered by 25a2e04e5689af63d104de2dea755f30bf643afd : PATCH 1/9 : fix definition for vmchannel_init in qemu/vl.c PATCH 2/9 : fix definition for migrate_incoming in qemu/vl.c PATCH 3/9

Re: [kvm-devel] [PATCH] kvm/qemu: Fix ia64 build broken.

2007-12-22 Thread Avi Kivity
Zhang, Xiantao wrote: Hi, Avi Due to last merge with Qemu upstream, some interfaces are changed, and leads to build fail , this patch fixed them. Xiantao From: Zhang Xiantao [EMAIL PROTECTED] Date: Fri, 21 Dec 2007 22:47:52 +0800 Subject: [PATCH] kvm: qemu : Fix ia64 build on latest

Re: [kvm-devel] mailman setup for kvm-devel (was Re: external module sched_in event)

2007-12-22 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: On Fri, Dec 21, 2007 at 07:22:57PM +0100, Andrea Arcangeli wrote: On Fri, Dec 21, 2007 at 07:52:52PM +0200, Izik Eidus wrote: oh, it was sent to the list, dont trust (in case you did) the source forge site for the mails But this time I

Re: [kvm-devel] [PATCH] external module: remove tmp directory once done with sync

2007-12-22 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: This patch complements 684c6426c5d58f01f45cd45420df96c837d0feb4 by deleting the tmp directory once the merge is completed so that it doesn't get included by mistake in the release package Applied, thanks. -- Do not meddle in the internals of kernels,

Re: [kvm-devel] external module sched_in event

2007-12-22 Thread Avi Kivity
Izik Eidus wrote: This fixes my longstanding KVM instability and -smp 2 now works flawlessy with svm too! -smp 2 -snapshot crashes in qemu userland but that's not kernel related, must be some thread mutex lock recursion or lock inversion in the qcow cow code. Removing -snapshot make -smp 2

Re: [kvm-devel] [PATCH] kvm/qemu: Fix ia64 build broken.

2007-12-22 Thread Avi Kivity
Amit Shah wrote: On Friday 21 December 2007 20:28:23 Zhang, Xiantao wrote: Hi, Avi Due to last merge with Qemu upstream, some interfaces are changed, and leads to build fail , this patch fixed them. Xiantao I've not checked the patch yet; but a curiosity question: Do you also

Re: [kvm-devel] [patch 3/5] KVM: add kvm_follow_page()

2007-12-22 Thread Avi Kivity
Marcelo Tosatti wrote: Hi Avi, Andrew, please see the comments on the need for a atomic get_user_pages() below. On Sat, Dec 22, 2007 at 09:42:27PM +0200, Avi Kivity wrote: Marcelo Tosatti wrote: In preparation for a mmu spinlock, avoid schedules in mmu_set_spte() by using

Re: [kvm-devel] [PATCH] kvm: external module: Remove 'include/asm' before execute 'ln'

2007-12-20 Thread Avi Kivity
Yang, Sheng wrote: From 33d84813131809e962a4cd8cae9b66a9062fa8db Mon Sep 17 00:00:00 2001 From: Sheng Yang [EMAIL PROTECTED] Date: Thu, 20 Dec 2007 14:22:18 +0800 Subject: [PATCH] kvm: external module: Remove 'include/asm' before execute 'ln' We use 'ln -sf' to refresh the symbolic now.

Re: [kvm-devel] remove redundant VM Exit for non-aligned guest pte write or part of pte write.

2007-12-20 Thread Avi Kivity
Dong, Eddie wrote: I observed 1-2 seconds faster in Windows XPSP2 ACPI bootup with total of 23 seconds. I can;t say it is exactly caused by this patch, but anyway it simplifies the logic and code w/o any additional complexity. thx,eddie Patch looks good, but will delay so that the

Re: [kvm-devel] [Qemu-devel] [PATCH 2/2] Option ROM for booting from SCSI/PV disks

2007-12-20 Thread Avi Kivity
Anthony Liguori wrote: Hi, The attached patch is an option ROM that allows x86 guests to boot from any block device supported by QEMU (and the guest kernel). It works by hijacking the BIOS int13 function and then uses a very simply protocol to communicate all block requests to QEMU. This

Re: [kvm-devel] [PATCH] kvm/qemu : Enable coms init, since rtc added back

2007-12-20 Thread Avi Kivity
Zhang, Xiantao wrote: From: Zhang Xiantao [EMAIL PROTECTED] Date: Thu, 20 Dec 2007 19:30:56 +0800 Subject: [PATCH] kvm: qemu: Enable cmos, since rtc has been added back. Enable cmos, since code is mature and rtc added back Applied this and the next patch; thanks. -- error compiling

Re: [kvm-devel] [PATCH] align gdbstub with QEMU

2007-12-20 Thread Avi Kivity
Jan Kiszka wrote: The qemu update did take place for -57, but a bit too mechanically. Please merge this patch to finally fix the gdbstub. Thanks, applied. -- error compiling committee.c: too many arguments to function

Re: [kvm-devel] [PATCH] Export three symbols for kvm use.

2007-12-20 Thread Avi Kivity
Christoph Hellwig wrote: On Thu, Dec 20, 2007 at 01:57:01PM +0800, Zhang, Xiantao wrote: Hi Tony, In order to build kvm source successfully, we need to export three symbols for kvm use. Please review. Maybe Avi can check-in to kvm.git upstream first. Thanks Xiantao From: Zhang

Re: [kvm-devel] Guest kernel hangs in smp kvm for older kernels prior to tsc sync cleanup

2007-12-19 Thread Avi Kivity
Avi Kivity wrote: Ingo Molnar wrote: While the change mentions that it fixes a time warp bug, it also says it should be rare. So clearly kvm smp tsc handing is buggy. Ingo/Thomas, (or anybody else), do you have any insight as to what kvm can be doing wrong to trigger this behavior

Re: [kvm-devel] Guest kernel hangs in smp kvm for older kernels prior to tsc sync cleanup

2007-12-19 Thread Avi Kivity
Avi Kivity wrote: Testing shows wrmsr and rdtsc function normally. I'll try pinning the vcpus to cpus and see if that helps. It does. -- error compiling committee.c: too many arguments to function - SF.Net email

Re: [kvm-devel] Guest kernel hangs in smp kvm for older kernels prior to tsc sync cleanup

2007-12-19 Thread Avi Kivity
Ingo Molnar wrote: * Avi Kivity [EMAIL PROTECTED] wrote: Avi Kivity wrote: Testing shows wrmsr and rdtsc function normally. I'll try pinning the vcpus to cpus and see if that helps. It does. do we let the guest read the physical CPU's TSC? That would be trouble

Re: [kvm-devel] [PATCH] x86_64: fix problems due to use of outb to port 80 on some AMD64x2 laptops, etc.

2007-12-19 Thread Avi Kivity
David P. Reed wrote: Avi Kivity wrote: kvm will forward a virtual machine's writes to port 0x80 to the real port. The reason is that the write is much faster than exiting and emulating it; the difference is measurable when compiling kernels. Now if the cause is simply writing to port 0x80

Re: [kvm-devel] [PATCH] [RESEND] libkvm: NULL pointer dereference in kvm_destroy_phys_mem as used in kvm-56

2007-12-19 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: so just to be clear on this?, would you rather have these changes in a patch series, or as unrelated patches with the second one fixing a formatting issue that the first one triggered? Oh, I misunderstood. The changes are related and should be in one

Re: [kvm-devel] Guest kernel hangs in smp kvm for older kernels prior to tsc sync cleanup

2007-12-19 Thread Avi Kivity
Ingo Molnar wrote: try this test perhaps in an SMP guest: http://people.redhat.com/mingo/time-warp-test/time-warp-test.c you can ignore TSC warps - but no GTOD or CLOCK warps should occur. On a broken guest kernel, I see gtod and clock warps. On a good guest kernel, I do not,

Re: [kvm-devel] Guest kernel hangs in smp kvm for older kernels prior to tsc sync cleanup

2007-12-19 Thread Avi Kivity
Glauber de Oliveira Costa wrote: Changes in rate does not sound good. It's possibly what's screwing up my paravirt clock implementation in smp. You should renew the timebase on vcpu migration, and hook cpufreq so that changes in frequency are reflected in the timebase. Since the host

Re: [kvm-devel] [PATCH] external module: remove dependency on asm/io_apic.h

2007-12-19 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: Complements f2601fd2874b94d14dfcb21a3e1b84d7f3262b17 which made obsolete the use of io_apic provided defines that were not being included for x86 when the host kernel didn't have IO_APIC support. Reverts : 5d6ea6b370ff9aae1dd7671b71e89351749fbeee

Re: [kvm-devel] [PATCH][UPDATE] kvm-userspace: simplify mmio callback

2007-12-19 Thread Avi Kivity
Christian Ehrhardt wrote: Subject: [PATCH][UPDATE] kvm-userspace: simplify mmio callback From: Christian Ehrhardt [EMAIL PROTECTED] Merging the read[bwlq]/write[bwlq] callback callback pointers to mmio_read/write functions simplifies the callback interface. On the qemu side it now uses the

Re: [kvm-devel] [ANNOUNCE] kvm-57 release

2007-12-19 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: On Tue, Dec 18, 2007 at 06:15:07PM +0200, Avi Kivity wrote: The major focus for this release is a qemu-cvs merge, which brings many new features, some introduced by kvm developers. but didn't include my changes to the IDE emulation to allow

Re: [kvm-devel] Guest kernel hangs in smp kvm for older kernelsprior to tsc sync cleanup

2007-12-19 Thread Avi Kivity
Dor Laor wrote: vmx (and svm) allow us to add an offset to the physical tsc. We set it on startup to -tsc (so that an rdtsc on boot would return 0), and massage it on vcpu migration so that guest rdtsc is monotonic. The net effect is that tsc on a vcpu can experience large

Re: [kvm-devel] [PATCH 0/2] qemu: IDE/ATAPI emulation fixes

2007-12-19 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: The following patch series implements fixes to the IDE/ATAPI emulation in qemu which affects access to the CD-ROM device preventing installation of OpenSolaris guests because of an incorrect implementation of the MMC6 GET_CONFIGURATION command when it was

Re: [kvm-devel] [RFC] concurrent guest walker and instruction emulation

2007-12-19 Thread Avi Kivity
Marcelo Tosatti wrote: Updated patch, now feature complete. Changes from last version: - Use __gfn_to_page in cmpxchg_pte() to avoid potential deadlock - Add kvm_read_guest_inatomic() and use it in fetch() - Make prefetch_page() use copy_from_user_inatomic() - Pass grabbed page down to

Re: [kvm-devel] merge kvm_flush_remote_tlbs when modifing shadow pte

2007-12-18 Thread Avi Kivity
Dong, Eddie wrote: Dong, Eddie wrote: host side TLB flush can be merged together if multiple spte need to be write-protected. Signed-off-by: Yaozu (Eddie) Dong [EMAIL PROTECTED] diff --git a/drivers/kvm/mmu.c b/drivers/kvm/mmu.c index 92ac0d1..749db46 100644 --- a/drivers/kvm/mmu.c

Re: [kvm-devel] [RFC] concurrent guest walker and instruction emulation

2007-12-18 Thread Avi Kivity
Marcelo Tosatti wrote: Hi, The following is an improvement on top of an earlier patch by Izik. It increases pagefault scalability for SMP guests by allowing concurrent guest walking, allocation and instruction emulation on the fault path. The test being used is pft, which starts a number

[kvm-devel] [ANNOUNCE] kvm-57 release

2007-12-18 Thread Avi Kivity
The major focus for this release is a qemu-cvs merge, which brings many new features, some introduced by kvm developers. Examples are improved usb support and the new -drive qemu option. While we've tested this carefully, this is a big merge so please handle this release with care and

Re: [kvm-devel] KVM Test result, kernel 5ca24d9.., userspace 120e0c8..

2007-12-18 Thread Avi Kivity
Zhao, Yunfeng wrote: Save/restore still passes on IA32e host but fails on IA32 host. This is now fixed. -- error compiling committee.c: too many arguments to function - SF.Net email is sponsored by: Check out the

Re: [kvm-devel] [PATCH] [RESEND] libkvm: NULL pointer dereference in kvm_destroy_phys_mem as used in kvm-56

2007-12-18 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: The following patch eliminates the uninitialized mem pointer, using instead the corresponding entry from the slots array to fix : libkvm.c:580: warning: 'mem' is used uninitialized in this function Also changes the formatting type for phys_addr to long to

Re: [kvm-devel] PATCH vmx.c: add printk_ratelimit in vmx_intr_assist

2007-12-18 Thread Avi Kivity
Ryan Harper wrote: * Ryan Harper [EMAIL PROTECTED] [2007-12-14 09:36]: * Avi Kivity [EMAIL PROTECTED] [2007-12-14 08:49]: Ryan Harper wrote: Add printk_ratelimit check in front of printk. This prevents spamming of the message during 32-bit ubuntu 6.06server install

Re: [kvm-devel] [RFC] external module: compatibility with older kernels (SMP and non SMP)

2007-12-18 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: The following patch (which is composed of 3 different patches from a series) has been validated to solve compilation issues observed with kvm-56 in x86 with kernels older than 2.6.21 and are posted here for testing and debate. The main points accomplished (in

Re: [kvm-devel] [PATCH][UPDATE] kvm-userspace: sync icache for more architectures

2007-12-18 Thread Avi Kivity
Christian Ehrhardt wrote: Subject: [PATCH][UPDATE] kvm-userspace: sync icache for more architectures From: Christian Ehrhardt [EMAIL PROTECTED] A ia64 patch introduced kvm_sync_icache within a ifdef __ia64__, but the concept of split caches is not bound to ia64. This patch replaces the the

[kvm-devel] Guest kernel hangs in smp kvm for older kernels prior to tsc sync cleanup

2007-12-18 Thread Avi Kivity
Booting RHEL 5 i386 in kvm with -no-kvm-irqchip -smp 4 will hang in udev. I bisected this to a change in the _guest_ kernel: commit 95492e4646e5de8b43d9a7908d6177fb737b61f0 Author: Ingo Molnar [EMAIL PROTECTED] Date: Fri Feb 16 01:27:34 2007 -0800 [PATCH] x86: rewrite SMP TSC sync

Re: [kvm-devel] KVM Test result, kernel 5ca24d9.., userspace 120e0c8..

2007-12-18 Thread Avi Kivity
Zhao, Yunfeng wrote: Retested it on KVM-57. It has been fixed already. Actually, the fix is post kvm-57. What kvm-userspace.git commit did you test? -- error compiling committee.c: too many arguments to function -

Re: [kvm-devel] Guest kernel hangs in smp kvm for older kernels prior to tsc sync cleanup

2007-12-18 Thread Avi Kivity
Ingo Molnar wrote: While the change mentions that it fixes a time warp bug, it also says it should be rare. So clearly kvm smp tsc handing is buggy. Ingo/Thomas, (or anybody else), do you have any insight as to what kvm can be doing wrong to trigger this behavior? hm. Those time

Re: [kvm-devel] [PATCH] [0/3] Make ioapic.c independent of x86 header files V2

2007-12-17 Thread Avi Kivity
Zhang, Xiantao wrote: According to Avi's comments, Updated the patches. [1/3] Create ioapic.h and lapic.h to hold their declarations. [2/3] Moving ioapic{.h,.c} back to common directory. [3/3] Moving out kvm_vcpu_kick from irq.c Applied all, thanks. -- error compiling committee.c:

Re: [kvm-devel] [PATCH] No reason to disallow (phys_ram_alloc_offset + size) = phys_ram_size in qemu_ram_alloc

2007-12-17 Thread Avi Kivity
Zhang, Xiantao wrote: From: Zhang Xiantao [EMAIL PROTECTED] Date: Mon, 17 Dec 2007 16:43:24 +0800 Subject: [PATCH] kvm: qemu: No reason to disallow (phys_ram_alloc_offset + size) = phys_ram_size No reason to disallow (phys_ram_alloc_offset + size) = phys_ram_size. Applied, thanks. --

Re: [kvm-devel] [PATCH] Make ioapic structure in irqchip seen by ia64

2007-12-17 Thread Avi Kivity
Zhang, Xiantao wrote: From: [EMAIL PROTECTED] [EMAIL PROTECTED] Date: Mon, 17 Dec 2007 20:27:27 +0800 Subject: [PATCH] kvm: make ioapic structure in irqchip seen by ia64 IA64 also needs to see ioapic structure in irqchip. Patch doesn't apply due to whitespace corruption. -- error

Re: [kvm-devel] [PATCH] Make ioapic structure in irqchip seen by ia64

2007-12-17 Thread Avi Kivity
Zhang, Xiantao wrote: Attached. From: [EMAIL PROTECTED] [EMAIL PROTECTED] Date: Mon, 17 Dec 2007 20:27:27 +0800 Subject: [PATCH] kvm: make ioapic structure in irqchip seen by ia64 IA64 also needs to see ioapic structure in irqchip. Applied, thanks. -- error compiling committee.c: too

Re: [kvm-devel] merge kvm_flush_remote_tlbs when modifing shadow pte

2007-12-17 Thread Avi Kivity
Dong, Eddie wrote: host side TLB flush can be merged together if multiple spte need to be write-protected. Signed-off-by: Yaozu (Eddie) Dong [EMAIL PROTECTED] diff --git a/drivers/kvm/mmu.c b/drivers/kvm/mmu.c index 92ac0d1..749db46 100644 --- a/drivers/kvm/mmu.c +++ b/drivers/kvm/mmu.c

Re: [kvm-devel] question on #UD emulation

2007-12-16 Thread Avi Kivity
Dong, Eddie wrote: Avi/Anthony: Following commit added #UD trap in KVM and do emulation in KVM. It is good to avoid the mis hypercall instruction issue, but I am not sure if it will have any serious side effect. I am blind to AMD instruction, I assume, for example, AMD 3D now

Re: [kvm-devel] [ANNOUNCE] kvm-56 release

2007-12-16 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: On Thu, Dec 13, 2007 at 03:32:46PM +0200, Avi Kivity wrote: Notes: If you use the modules bundled with kvm-56, you can use any version of Linux from 2.6.9 upwards. the external module (once patched) will only be able to build against 2.6.17

Re: [kvm-devel] [PATCH] external module: include apicdef.h for kernel 2.6.21

2007-12-16 Thread Avi Kivity
Carlo Marcelo Arenas Belon wrote: The following patch fixes building the kvm module for kernels older than 2.6.21 and which were missing an include to asm/apicdef.h in asm/io_apic.h resulting in the following error : include/asm/io_apic.h:61: error: 'MAX_IO_APICS' undeclared here (not

Re: [kvm-devel] question on #UD emulation

2007-12-16 Thread Avi Kivity
Dong, Eddie wrote: A little bit suspicion for the usage model too :( The CPUID feature list can't be changed dynamically, so I doutb if a real user will give up performance at beginning when he/she starts the guest for maybe future migration cross host platform. A VT or SVM enabled machine

Re: [kvm-devel] question on #UD emulation

2007-12-16 Thread Avi Kivity
Dong, Eddie wrote: Since we don't emulate 3Dnow instructions, a #UD will be injected instead. OK, how many architecture specific instructiosn are emulated now? Just vmcall/vmmcall (which is emulated once, then patched). Or what is planed to be implemented? If no, then

Re: [kvm-devel] [PATCH] Make ioapic.c independent of x86 header files

2007-12-16 Thread Avi Kivity
Zhang, Xiantao wrote: From: Zhang Xiantao [EMAIL PROTECTED] Date: Sun, 16 Dec 2007 23:41:50 +0800 Subject: [PATCH] kvm: Split irq.h into two parts, and make ioapic independent of X86 header files. This patch splits irq.h into two parts, and make ioapic independent of X86 header files.

<    9   10   11   12   13   14   15   16   17   18   >