Re: KSM For All Via LD_PRELOAD?

2010-06-10 Thread Dor Laor
On 06/09/2010 01:31 PM, Gordan Bobic wrote: On 06/09/2010 09:56 AM, Paolo Bonzini wrote: Or is this too crazy an idea? It should work. Note that the the malloced memory should be aligned in order to get better sharing. Within glibc malloc large blocks are mmaped, so they are automatically

Re: KSM For All Via LD_PRELOAD?

2010-06-10 Thread Jes Sorensen
On 06/08/10 20:43, Gordan Bobic wrote: Is this plausible? I'm trying to work out if it's even worth considering this approach to enable all memory used by in a system to be open to KSM page merging, rather than only memory used by specific programs aware of it (e.g. kvm/qemu). Something

Re: KSM For All Via LD_PRELOAD?

2010-06-10 Thread Gordan Bobic
On 06/10/2010 08:33 AM, Dor Laor wrote: On 06/09/2010 01:31 PM, Gordan Bobic wrote: On 06/09/2010 09:56 AM, Paolo Bonzini wrote: Or is this too crazy an idea? It should work. Note that the the malloced memory should be aligned in order to get better sharing. Within glibc malloc large

Re: [PATCH v8 1/2] KVM: VMX: Enable XSAVE/XRSTOR for guest

2010-06-10 Thread Avi Kivity
On 06/10/2010 06:27 AM, Sheng Yang wrote: From: Dexuan Cuidexuan@intel.com This patch enable guest to use XSAVE/XRSTOR instructions. We assume that host_xcr0 would use all possible bits that OS supported. And we loaded xcr0 in the same way we handled fpu - do it as late as we can.

Re: KSM For All Via LD_PRELOAD?

2010-06-10 Thread Gordan Bobic
On 06/10/2010 08:44 AM, Jes Sorensen wrote: On 06/08/10 20:43, Gordan Bobic wrote: Is this plausible? I'm trying to work out if it's even worth considering this approach to enable all memory used by in a system to be open to KSM page merging, rather than only memory used by specific programs

Re: [PATCH 2/2] KVM: x86: XSAVE/XRSTOR live migration support

2010-06-10 Thread Avi Kivity
On 06/10/2010 06:27 AM, Sheng Yang wrote: This patch enable save/restore of xsave state. Signed-off-by: Sheng Yangsh...@linux.intel.com --- Documentation/kvm/api.txt | 76 ++ arch/x86/include/asm/kvm.h | 24 ++ arch/x86/kvm/x86.c | 110

Re: [RFC][PATCH 1/3] Introduce a workqueue to deliver PIT timer interrupts.

2010-06-10 Thread Avi Kivity
On 06/10/2010 12:17 AM, Zachary Amsden wrote: On 06/09/2010 03:23 AM, Marcelo Tosatti wrote: On Tue, Jun 08, 2010 at 04:36:16PM -1000, Zachary Amsden wrote: +pt-timer.function = pit_timer_fn; I am happy to see this. I thought kvm_timer_fn was a step backwards; it was too general of a

[GIT PULL] KVM updates for 2.6.35-rc2

2010-06-10 Thread Avi Kivity
Linus, please pull from git://git.kernel.org/pub/scm/virt/kvm/kvm.git kvm-updates/2.6.35 to receive a bunch of KVM fixes for 2.6.35-rc2, including a workaround for a cpu erratum that can allow a guest to crash the host. Avi Kivity (1): KVM: MMU: Remove user access when allowing

Re: [RFC/T/D][PATCH 2/2] Linux/Guest cooperative unmapped page cache control

2010-06-10 Thread Avi Kivity
On 06/08/2010 06:51 PM, Balbir Singh wrote: Balloon unmapped page cache pages first From: Balbir Singhbal...@linux.vnet.ibm.com This patch builds on the ballooning infrastructure by ballooning unmapped page cache pages first. It looks for low hanging fruit first and tries to reclaim clean

Re: [Qemu-devel] Re: KVM call minutes for June 8

2010-06-10 Thread Kevin Wolf
Am 09.06.2010 18:22, schrieb Anthony Liguori: On 06/09/2010 10:31 AM, Daniel P. Berrange wrote: However, libvirt was counting on this feature and on the snapshot commands to switch from the text Monitor. We have two options: 1. Ask them to wait one more release (not so good for us) 2.

Re: [PATCH 1/2] test: Add IDT framework

2010-06-10 Thread Avi Kivity
On 06/10/2010 06:31 AM, Sheng Yang wrote: + +#define EXCEPTION_REGION_BEGIN(r, lb) \ +asm volatile(pushq $lb\n\t \ + mov $2, %0\n\t \ + : =r(r)) +#define EXCEPTION_REGION_END(r, lb) \ +asm volatile(popq %%rdx\n\t \ +mov $0, %0\n\t \ +

Re: [RFC] para virt interface of perf to support kvm guest os statistics collection in guest os

2010-06-10 Thread Peter Zijlstra
On Thu, 2010-06-10 at 10:21 +0800, Zhang, Yanmin wrote: . The ABI mostly includes the definition of struct perf_event_attr, guest_perf_counter, and hypercalls. Note that perf_event_attr isn't guaranteed to be stable between kernels, it can grow. -- To unsubscribe from this list: send the line

KVM_EXIT_HALT and KVM_CREATE_IRQCHIP

2010-06-10 Thread Pekka Enberg
Hi! How is the guest supposed to halt the hypervisor if KVM_CREATE_IRQCHIP is being used? The kvm_emulate_halt() function seems to handle the halt event completely if irqchip_in_kernel() returns true and thus never exits to the hypervisor. I see there's a KVM_GET_MP_STATE ioctl that can be

Re: [PATCH 1/2] test: Add IDT framework

2010-06-10 Thread Sheng Yang
On Thursday 10 June 2010 17:49:16 Avi Kivity wrote: On 06/10/2010 06:31 AM, Sheng Yang wrote: + +#define EXCEPTION_REGION_BEGIN(r, lb) \ +asm volatile(pushq $lb\n\t \ + mov $2, %0\n\t \ + : =r(r)) +#define EXCEPTION_REGION_END(r, lb) \ +asm

Re: KVM_EXIT_HALT and KVM_CREATE_IRQCHIP

2010-06-10 Thread Avi Kivity
On 06/10/2010 12:52 PM, Pekka Enberg wrote: How is the guest supposed to halt the hypervisor if KVM_CREATE_IRQCHIP is being used? The kvm_emulate_halt() function seems to handle the halt event completely if irqchip_in_kernel() returns true and thus never exits to the hypervisor. The

Re: KVM_EXIT_HALT and KVM_CREATE_IRQCHIP

2010-06-10 Thread Pekka Enberg
Hi Avi, On 06/10/2010 12:52 PM, Pekka Enberg wrote: How is the guest supposed to halt the hypervisor if KVM_CREATE_IRQCHIP is being used? The kvm_emulate_halt() function seems to handle the halt event completely if irqchip_in_kernel() returns true and thus never exits to the hypervisor. On

Re: KVM_EXIT_HALT and KVM_CREATE_IRQCHIP

2010-06-10 Thread Avi Kivity
On 06/10/2010 01:15 PM, Pekka Enberg wrote: On 06/10/2010 12:52 PM, Pekka Enberg wrote: I see there's a KVM_GET_MP_STATE ioctl that can be used to check if state is KVM_MP_STATE_HALTED but as we never exit to the hypervisor, how is this supposed to work? Am I missing something obvious here?

Re: [PATCH 1/2] test: Add IDT framework

2010-06-10 Thread Avi Kivity
On 06/10/2010 12:55 PM, Sheng Yang wrote: On Thursday 10 June 2010 17:49:16 Avi Kivity wrote: On 06/10/2010 06:31 AM, Sheng Yang wrote: + +#define EXCEPTION_REGION_BEGIN(r, lb) \ +asm volatile(pushq $lb\n\t \ + mov $2, %0\n\t \ + : =r(r)) +#define

[PATCH] [19/23] KVM: Fix unused but set warnings

2010-06-10 Thread Andi Kleen
No real bugs in this one, the real bug I found is in a separate patch. Cc: a...@redhat.com Cc: kvm@vger.kernel.org Signed-off-by: Andi Kleen a...@linux.intel.com --- arch/x86/kvm/paging_tmpl.h |1 + arch/x86/kvm/vmx.c |3 +-- virt/kvm/assigned-dev.c|2 -- 3 files

[PATCH] [11/23] KVM: Fix KVM_SET_SIGNAL_MASK

2010-06-10 Thread Andi Kleen
Real bug fix. When the user passed in a NULL mask pass this on from the ioctl handler. Found by gcc 4.6's new warnings. Cc: a...@redhat.com Cc: kvm@vger.kernel.org Signed-off-by: Andi Kleen a...@linux.intel.com --- virt/kvm/kvm_main.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

Re: [RFC PATCH 2/2] kvm, x86: use ro page and don't copy shared page

2010-06-10 Thread Lai Jiangshan
Avi Kivity wrote: I have found out what have happen, current code has 2 serious bugs! I will sent patches to fix these bugs tomorrow(because my box is broken). And I will sent this use ro page and don't copy shared page pathset next week. Thanks a lot. Lai -- To unsubscribe from this list:

Re: KSM For All Via LD_PRELOAD?

2010-06-10 Thread Jes Sorensen
On 06/10/10 11:09, Gordan Bobic wrote: On 06/10/2010 08:44 AM, Jes Sorensen wrote: Not sure if it is worth it, but you might want to look at ElectricFence which does malloc wrapping in a somewhat similar way. It might save you some code :) I'll look into it, but I don't see this requiring

Re: [Qemu-devel] Re: KVM call minutes for June 8

2010-06-10 Thread Anthony Liguori
On 06/10/2010 04:43 AM, Kevin Wolf wrote: Huh, why this? Seems I still haven't understood all of qcow2 then... I always thought that there's just a specific offset where VM state starts, but no explicit end. A live snapshot can last for a very long time. What happens if you need to

Re: [Qemu-devel] Re: KVM call minutes for June 8

2010-06-10 Thread Kevin Wolf
Am 10.06.2010 14:53, schrieb Anthony Liguori: On 06/10/2010 04:43 AM, Kevin Wolf wrote: Huh, why this? Seems I still haven't understood all of qcow2 then... I always thought that there's just a specific offset where VM state starts, but no explicit end. A live snapshot can last for a

[PATCH v2] test: Add IDT framework

2010-06-10 Thread Avi Kivity
Signed-off-by: Sheng Yang sh...@linux.intel.com Signed-off-by: Avi Kivity a...@redhat.com --- kvm/test/config-x86-common.mak |2 + kvm/test/config-x86_64.mak |2 +- kvm/test/flat.lds |7 ++- kvm/test/lib/x86/idt.h | 19 + kvm/test/x86/idt.c |

Re: [PATCH 1/2] test: Add IDT framework

2010-06-10 Thread Avi Kivity
On 06/10/2010 01:55 PM, Avi Kivity wrote: Something like =m(blah) can cause access to %rsp, usually when compiling without frame pointers. I suggest using a special data section like the kernel. Kind of more complex... Makes it more fun. I'll have a go. Posted. Currently fails due to

[PATCH 1/3] KVM: Fix mov cr0 #GP at wrong instruction

2010-06-10 Thread Avi Kivity
On Intel, we call skip_emulated_instruction() even if we injected a #GP, resulting in the #GP pointing at the wrong address. Fix by injecting the exception and skipping the instruction at the same place, so we can do just one or the other. Signed-off-by: Avi Kivity a...@redhat.com ---

[PATCH 2/3] KVM: Fix mov cr4 #GP at wrong instruction

2010-06-10 Thread Avi Kivity
On Intel, we call skip_emulated_instruction() even if we injected a #GP, resulting in the #GP pointing at the wrong address. Fix by injecting the exception and skipping the instruction at the same place, so we can do just one or the other. Signed-off-by: Avi Kivity a...@redhat.com ---

[PATCH 0/3] Fix #GP at wrong rip for mov cr instructions

2010-06-10 Thread Avi Kivity
Three mov cr instructions fail in a similar way when they fault: the fault rip points at the next instead of faulting instructions. This patch set fixes the problem. Avi Kivity (3): KVM: Fix mov cr0 #GP at wrong instruction KVM: Fix mov cr4 #GP at wrong instruction KVM: Fix mov cr3 #GP at

[PATCH 3/3] KVM: Fix mov cr3 #GP at wrong instruction

2010-06-10 Thread Avi Kivity
On Intel, we call skip_emulated_instruction() even if we injected a #GP, resulting in the #GP pointing at the wrong address. Fix by injecting the exception and skipping the instruction at the same place, so we can do just one or the other. Signed-off-by: Avi Kivity a...@redhat.com ---

Re: [Qemu-devel] Re: KVM call minutes for June 8

2010-06-10 Thread Avi Kivity
On 06/10/2010 04:08 PM, Kevin Wolf wrote: It's just not seen by the guest because it's saved at a high offset that is after the end of the real disk content, but otherwise it should behave the same as guest data. That's very unfriendly towards extending the guest-visible portion of the

Re: [PATCH] [11/23] KVM: Fix KVM_SET_SIGNAL_MASK

2010-06-10 Thread Avi Kivity
On 06/10/2010 02:10 PM, Andi Kleen wrote: Real bug fix. When the user passed in a NULL mask pass this on from the ioctl handler. Found by gcc 4.6's new warnings. Applied, thanks. -- error compiling committee.c: too many arguments to function -- To unsubscribe from this list: send the

Re: [Qemu-devel] Re: KVM call minutes for June 8

2010-06-10 Thread Kevin Wolf
Am 10.06.2010 16:11, schrieb Avi Kivity: On 06/10/2010 04:08 PM, Kevin Wolf wrote: It's just not seen by the guest because it's saved at a high offset that is after the end of the real disk content, but otherwise it should behave the same as guest data. That's very unfriendly towards

Re: [PATCHv2] virtio-net: stop vhost backend on vmstop

2010-06-10 Thread Michael S. Tsirkin
On Fri, Jun 04, 2010 at 02:03:16PM -0300, Marcelo Tosatti wrote: On Wed, Jun 02, 2010 at 09:01:52PM +0300, Michael S. Tsirkin wrote: vhost net currently keeps running after vmstop, which causes trouble as qemy does not check for dirty pages anymore. The fix is to simply keep vm and vhost

Re: [RFC/T/D][PATCH 2/2] Linux/Guest cooperative unmapped page cache control

2010-06-10 Thread Balbir Singh
* Avi Kivity a...@redhat.com [2010-06-10 12:43:11]: On 06/08/2010 06:51 PM, Balbir Singh wrote: Balloon unmapped page cache pages first From: Balbir Singhbal...@linux.vnet.ibm.com This patch builds on the ballooning infrastructure by ballooning unmapped page cache pages first. It looks

Re: [Qemu-devel] Re: KVM call minutes for June 8

2010-06-10 Thread Anthony Liguori
On 06/10/2010 08:08 AM, Kevin Wolf wrote: Am 10.06.2010 14:53, schrieb Anthony Liguori: On 06/10/2010 04:43 AM, Kevin Wolf wrote: Huh, why this? Seems I still haven't understood all of qcow2 then... I always thought that there's just a specific offset where VM state starts, but no

Re: [PATCHv2] virtio-net: stop vhost backend on vmstop

2010-06-10 Thread Anthony Liguori
On 06/10/2010 09:19 AM, Michael S. Tsirkin wrote: On Fri, Jun 04, 2010 at 02:03:16PM -0300, Marcelo Tosatti wrote: On Wed, Jun 02, 2010 at 09:01:52PM +0300, Michael S. Tsirkin wrote: vhost net currently keeps running after vmstop, which causes trouble as qemy does not check for dirty

Re: [Qemu-devel] [RFC PATCH 3/6] RAMBlock: Add a name field

2010-06-10 Thread Alex Williamson
On Thu, 2010-06-10 at 10:23 +0200, Gerd Hoffmann wrote: I may have been a bit misleading here. What we really want to do is use the same matching algorithm as is used by the rest of the device state. Currently this is a vmstate name and [arbitrary] numeric id. I don't remember whether

Re: [PATCH] [19/23] KVM: Fix unused but set warnings

2010-06-10 Thread Avi Kivity
On 06/10/2010 02:10 PM, Andi Kleen wrote: No real bugs in this one, the real bug I found is in a separate patch. Index: linux-2.6.35-rc2-gcc/arch/x86/kvm/vmx.c === --- linux-2.6.35-rc2-gcc.orig/arch/x86/kvm/vmx.c +++

RE: [RFC] Moving the kvm ioapic, pic, and pit back to userspace

2010-06-10 Thread Dong, Eddie
A VF interrupt usually happens in 4-8KHZ. How about the virtio? I assume virtio will be widely used together w/ leagcy guest with INTx mode. True, but in time it will be replaced by MSI. Note without vhost virtio is also in userspace, so there are lots of exits anyway for the status

Re: [Qemu-devel] [RFC PATCH 3/6] RAMBlock: Add a name field

2010-06-10 Thread Paul Brook
On Thu, 2010-06-10 at 10:23 +0200, Gerd Hoffmann wrote: I may have been a bit misleading here. What we really want to do is use the same matching algorithm as is used by the rest of the device state. Currently this is a vmstate name and [arbitrary] numeric id. I don't remember whether

Re: [Qemu-devel] [RFC PATCH 3/6] RAMBlock: Add a name field

2010-06-10 Thread Alex Williamson
On Wed, 2010-06-09 at 21:36 +0100, Paul Brook wrote: Not really. This identifier is device and bus independent, which is why I suggested passing the device to qemu_ram_alloc. This can then figure out how to the identify the device. It should probably do this the same way that we

Re: [Qemu-devel] [RFC PATCH 3/6] RAMBlock: Add a name field

2010-06-10 Thread Alex Williamson
On Thu, 2010-06-10 at 15:49 +0100, Paul Brook wrote: On Thu, 2010-06-10 at 10:23 +0200, Gerd Hoffmann wrote: I may have been a bit misleading here. What we really want to do is use the same matching algorithm as is used by the rest of the device state. Currently this is a vmstate

Re: [RFC][PATCH 1/3] Introduce a workqueue to deliver PIT timer interrupts.

2010-06-10 Thread Marcelo Tosatti
On Wed, Jun 09, 2010 at 11:17:41AM -1000, Zachary Amsden wrote: On 06/09/2010 03:23 AM, Marcelo Tosatti wrote: On Tue, Jun 08, 2010 at 04:36:16PM -1000, Zachary Amsden wrote: + pt-timer.function = pit_timer_fn; I am happy to see this. I thought kvm_timer_fn was a step backwards; it was

[PATCH] device-assignment: Don't deassign when the assignment fails

2010-06-10 Thread Alex Williamson
The last thing assign_device() does is call into KVM_ASSIGN_PCI_DEVICE. If that fails, the device is not assigned, so we shouldn't then try to deassign it. If you try to assign the same device multiple times, you can get into a nasty fail-succeed-fail-succeed loop. And we certainly shouldn't

Re: [GIT PULL] KVM updates for 2.6.35-rc2

2010-06-10 Thread Linus Torvalds
On Thu, Jun 10, 2010 at 2:31 AM, Avi Kivity a...@redhat.com wrote: Linus, please pull from  git://git.kernel.org/pub/scm/virt/kvm/kvm.git kvm-updates/2.6.35 to receive a bunch of KVM fixes for 2.6.35-rc2, including a workaround for a cpu erratum that can allow a guest to crash the host.

Re: [Qemu-devel] [RFC PATCH 3/6] RAMBlock: Add a name field

2010-06-10 Thread Chris Wright
* Alex Williamson (alex.william...@redhat.com) wrote: On Wed, 2010-06-09 at 13:18 +0100, Paul Brook wrote: to the identify the device. It should probably do this the same way that we identify the saved state for the device. Currently I think this is an arbitrary vmstate name/id, but I

Re: [Qemu-devel] [RFC PATCH 3/6] RAMBlock: Add a name field

2010-06-10 Thread Paul Brook
to the identify the device. It should probably do this the same way that we identify the saved state for the device. Currently I think this is an arbitrary vmstate name/id, but I expect this to change to a qdev address (e.g. /i440FX-pcihost/pci.0/_addr_04.0). Ok, that seems

Re: [PATCH V2] VFIO driver: Non-privileged user level PCI drivers

2010-06-10 Thread Konrad Rzeszutek Wilk
+EXPORT_SYMBOL(uiommu_fdget); EXPORT_SYMBOL_GPL .. snip +EXPORT_SYMBOL(uiommu_put); ditto. -- 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

Re: [GIT PULL] KVM updates for 2.6.35-rc2

2010-06-10 Thread Avi Kivity
On 06/10/2010 07:33 PM, Linus Torvalds wrote: On Thu, Jun 10, 2010 at 2:31 AM, Avi Kivitya...@redhat.com wrote: Linus, please pull from git://git.kernel.org/pub/scm/virt/kvm/kvm.git kvm-updates/2.6.35 to receive a bunch of KVM fixes for 2.6.35-rc2, including a workaround for a cpu

Re: [GIT PULL] KVM updates for 2.6.35-rc2

2010-06-10 Thread Linus Torvalds
On Thu, Jun 10, 2010 at 10:34 AM, Avi Kivity a...@redhat.com wrote: Ok.  I've dropped the SRAO patch; this still leaves ~100 changed lines, but they are almost all due to the erratum 383 workaround, which can result in a guest killing the host.  The rest of the patches are less critical, but

Re: [PATCH v8 1/2] KVM: VMX: Enable XSAVE/XRSTOR for guest

2010-06-10 Thread Marcelo Tosatti
On Thu, Jun 10, 2010 at 11:27:12AM +0800, Sheng Yang wrote: From: Dexuan Cui dexuan@intel.com This patch enable guest to use XSAVE/XRSTOR instructions. We assume that host_xcr0 would use all possible bits that OS supported. And we loaded xcr0 in the same way we handled fpu - do it as

Re: KVM SMP guests won't work (2.6.35-rc2+)

2010-06-10 Thread Avi Kivity
On 06/10/2010 09:28 PM, Stephen Hemminger wrote: With current 2.6.35-rc2 and following configuration, my build guest VM will not start (it was working previously). Error starting domain: monitor socket did not show up: Connection refused Surprisingly, other guests work fine. The one

Re: KVM SMP guests won't work (2.6.35-rc2+)

2010-06-10 Thread Stephen Hemminger
On Thu, 10 Jun 2010 21:44:07 +0300 Avi Kivity a...@redhat.com wrote: On 06/10/2010 09:28 PM, Stephen Hemminger wrote: With current 2.6.35-rc2 and following configuration, my build guest VM will not start (it was working previously). Error starting domain: monitor socket did not show

[PATCH 0/3]: Fixes to IRQ routing

2010-06-10 Thread Chris Lalancette
As we've discussed previously, here is a series of patches to fix some of the IRQ routing issues we have in KVM. With this series in place I was able to successfully kdump a RHEL-5 64-bit, and RHEL-6 32- and 64-bit guest on CPU's other than the BSP. RHEL-5 32-bit kdump still does not work; it

[PATCH 1/3] Introduce a workqueue to deliver PIT timer interrupts.

2010-06-10 Thread Chris Lalancette
We really want to kvm_set_irq during the hrtimer callback, but that is risky because that is during interrupt context. Instead, offload the work to a workqueue, which is a bit safer and should provide most of the same functionality. Signed-off-by: Chris Lalancette clala...@redhat.com ---

[PATCH 3/3] In DM_LOWEST, only deliver interrupts to vcpus with enabled LAPIC's

2010-06-10 Thread Chris Lalancette
Otherwise we might try to deliver a timer interrupt to a cpu that can't possibly handle it. Signed-off-by: Chris Lalancette clala...@redhat.com --- virt/kvm/irq_comm.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/virt/kvm/irq_comm.c b/virt/kvm/irq_comm.c index

[PATCH 2/3] Allow any LAPIC to accept PIC interrupts.

2010-06-10 Thread Chris Lalancette
If the guest wants to accept timer interrupts on a CPU other than the BSP, we need to remove this gate. Signed-off-by: Chris Lalancette clala...@redhat.com --- arch/x86/kvm/lapic.c | 12 +--- 1 files changed, 5 insertions(+), 7 deletions(-) diff --git a/arch/x86/kvm/lapic.c

[RFC v2] [PATCH 0/3] Monitor Support for 'simple' trace backend

2010-06-10 Thread Prerna Saxena
This is v2 of monitor commands based on Stefan's trace framework : ( http://lists.gnu.org/archive/html/qemu-devel/2010-05/msg02407.html ) This adds the following monitor commands for the 'simple' backend: - info trace: to view current contents of the trace buffer. - info tracepoints

[RFC v2] [PATCH 1/3] Export tdb_hash()

2010-06-10 Thread Prerna Saxena
For now, I simply export tdb_hash() from qdict.h for use by tracing framework. Luiz suggested renaming and exporting it from a location other than qdict.h . Would qemu-common.h be a better place? Signed-off-by: Prerna Saxena pre...@linux.vnet.ibm.com --- qdict.c |2 +- qdict.h |2 ++

Re: [RFC][PATCH 1/3] Introduce a workqueue to deliver PIT timer interrupts.

2010-06-10 Thread Zachary Amsden
On 06/09/2010 11:24 PM, Avi Kivity wrote: On 06/10/2010 12:17 AM, Zachary Amsden wrote: On 06/09/2010 03:23 AM, Marcelo Tosatti wrote: On Tue, Jun 08, 2010 at 04:36:16PM -1000, Zachary Amsden wrote: +pt-timer.function = pit_timer_fn; I am happy to see this. I thought kvm_timer_fn was a

[RFC v2] [PATCH 3/3] Toggle tracepoint state

2010-06-10 Thread Prerna Saxena
This patch adds support for dynamically enabling/disabling of tracepoints. Monitor commands added : 1) info tracepoints : to view all available tracepoints and their state. 2) tracepoint NAME on|off : to enable/disable data logging from a

[PATCH] device-assignment: Cleanup on exit

2010-06-10 Thread Alex Williamson
close() the resource fd when we're done with it. Unregister and munmap the anonymous memory for the MSIX table. Signed-off-by: Alex Williamson alex.william...@redhat.com --- hw/device-assignment.c | 21 + 1 files changed, 21 insertions(+), 0 deletions(-) diff --git

[RFC v2] [PATCH 2/3] Monitor command 'info trace'

2010-06-10 Thread Prerna Saxena
This introduces the monitor command 'info trace' to display current contents of trace buffer. Signed-off-by: Prerna Saxena pre...@linux.vnet.ibm.com --- configure |3 +++ monitor.c | 12 qemu-monitor.hx |4 simpletrace.c | 12 tracetool

Re: [RFC/T/D][PATCH 2/2] Linux/Guest cooperative unmapped page cache control

2010-06-10 Thread Dave Hansen
On Thu, 2010-06-10 at 19:55 +0530, Balbir Singh wrote: I'm not sure victimizing unmapped cache pages is a good idea. Shouldn't page selection use the LRU for recency information instead of the cost of guest reclaim? Dropping a frequently used unmapped cache page can be more expensive than

[ kvm-Bugs-2832416 ] Hot-added device is not visible in guest after migration

2010-06-10 Thread SourceForge.net
Bugs item #2832416, was opened at 2009-08-05 09:49 Message generated for change (Comment added) made by haoxudong You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=893831aid=2832416group_id=180599 Please note that this message will contain a full copy of the comment

Re: [RFC/T/D][PATCH 2/2] Linux/Guest cooperative unmapped page cache control

2010-06-10 Thread KAMEZAWA Hiroyuki
On Thu, 10 Jun 2010 17:07:32 -0700 Dave Hansen d...@linux.vnet.ibm.com wrote: On Thu, 2010-06-10 at 19:55 +0530, Balbir Singh wrote: I'm not sure victimizing unmapped cache pages is a good idea. Shouldn't page selection use the LRU for recency information instead of the cost of guest

Re: [PATCH V2] VFIO driver: Non-privileged user level PCI drivers

2010-06-10 Thread Tom Lyon
On Thursday 10 June 2010 10:27:36 am Konrad Rzeszutek Wilk wrote: +EXPORT_SYMBOL(uiommu_fdget); EXPORT_SYMBOL_GPL .. snip +EXPORT_SYMBOL(uiommu_put); ditto. Is there a definitive explanation somewhere of when to use each? -- To unsubscribe from this list: send the line unsubscribe

Re: [RFC] para virt interface of perf to support kvm guest os statistics collection in guest os

2010-06-10 Thread Zhang, Yanmin
On Thu, 2010-06-10 at 11:50 +0200, Peter Zijlstra wrote: On Thu, 2010-06-10 at 10:21 +0800, Zhang, Yanmin wrote: . The ABI mostly includes the definition of struct perf_event_attr, guest_perf_counter, and hypercalls. Note that perf_event_attr isn't guaranteed to be stable between

[PATCH RFC] KVM: busy-spin detector

2010-06-10 Thread Marcelo Tosatti
The following patch implements a simple busy-spin detector. It considers a vcpu as busy-spinning if there are two consecutive exits due to external interrupt on the same RIP, and sleeps for 100us in that case. It is very likely that if the vcpu is making progress it will either exit for other

Re: [PATCH V2] VFIO driver: Non-privileged user level PCI drivers

2010-06-10 Thread Greg KH
On Thu, Jun 10, 2010 at 06:58:37PM -0700, Tom Lyon wrote: On Thursday 10 June 2010 10:27:36 am Konrad Rzeszutek Wilk wrote: +EXPORT_SYMBOL(uiommu_fdget); EXPORT_SYMBOL_GPL .. snip +EXPORT_SYMBOL(uiommu_put); ditto. Is there a definitive explanation somewhere of when to use

[PATCH v3] KVM: x86: XSAVE/XRSTOR live migration support

2010-06-10 Thread Sheng Yang
This patch enable save/restore of xsave state. Signed-off-by: Sheng Yang sh...@linux.intel.com --- Documentation/kvm/api.txt| 74 + arch/x86/include/asm/kvm.h | 22 ++ arch/x86/include/asm/xsave.h |7 ++- arch/x86/kvm/x86.c | 145

[PATCH v3] qemu: kvm: Enable XSAVE live migration support

2010-06-10 Thread Sheng Yang
Signed-off-by: Sheng Yang sh...@linux.intel.com --- qemu-kvm-x86.c| 109 - qemu-kvm.c| 24 +++ qemu-kvm.h| 28 + target-i386/cpu.h |5 ++ target-i386/kvm.c |2 +

Re: [RFC/T/D][PATCH 2/2] Linux/Guest cooperative unmapped page cache control

2010-06-10 Thread Balbir Singh
* KAMEZAWA Hiroyuki kamezawa.hir...@jp.fujitsu.com [2010-06-11 10:54:41]: On Thu, 10 Jun 2010 17:07:32 -0700 Dave Hansen d...@linux.vnet.ibm.com wrote: On Thu, 2010-06-10 at 19:55 +0530, Balbir Singh wrote: I'm not sure victimizing unmapped cache pages is a good idea. Shouldn't page

Re: [RFC/T/D][PATCH 2/2] Linux/Guest cooperative unmapped page cache control

2010-06-10 Thread Balbir Singh
* Dave Hansen d...@linux.vnet.ibm.com [2010-06-10 17:07:32]: On Thu, 2010-06-10 at 19:55 +0530, Balbir Singh wrote: I'm not sure victimizing unmapped cache pages is a good idea. Shouldn't page selection use the LRU for recency information instead of the cost of guest reclaim? Dropping

Re: [RFC/T/D][PATCH 2/2] Linux/Guest cooperative unmapped page cache control

2010-06-10 Thread KAMEZAWA Hiroyuki
On Fri, 11 Jun 2010 10:16:32 +0530 Balbir Singh bal...@linux.vnet.ibm.com wrote: * KAMEZAWA Hiroyuki kamezawa.hir...@jp.fujitsu.com [2010-06-11 10:54:41]: On Thu, 10 Jun 2010 17:07:32 -0700 Dave Hansen d...@linux.vnet.ibm.com wrote: On Thu, 2010-06-10 at 19:55 +0530, Balbir Singh

Re: [RFC/T/D][PATCH 2/2] Linux/Guest cooperative unmapped page cache control

2010-06-10 Thread KAMEZAWA Hiroyuki
On Fri, 11 Jun 2010 14:05:53 +0900 KAMEZAWA Hiroyuki kamezawa.hir...@jp.fujitsu.com wrote: I can think of both way in kernel and in user approarh and they should be complement to each other. An example of kernel-based approach is. 1. add a shrinker callback(A) for balloon-driver-for-guest

Re: [PATCH v8 1/2] KVM: VMX: Enable XSAVE/XRSTOR for guest

2010-06-10 Thread Avi Kivity
On 06/10/2010 06:27 AM, Sheng Yang wrote: From: Dexuan Cuidexuan@intel.com This patch enable guest to use XSAVE/XRSTOR instructions. We assume that host_xcr0 would use all possible bits that OS supported. And we loaded xcr0 in the same way we handled fpu - do it as late as we can.