Re: [PATCH v5 00/13] KVM/ARM Implementation

2012-01-12 Thread Peter Maydell
On 12 January 2012 03:29, Christoffer Dall c.d...@virtualopensystems.com wrote: On Jan 11, 2012, at 8:48 AM, Peter Maydell wrote: (It would be quite useful to be able to boot a reasonably modern [read, ARMv7, Thumb2, VFPv3] guest userspace; does anybody plan to work on this part soon?) We

Re: [Qemu-devel] State of KVM bits in linux-headers

2012-01-12 Thread Avi Kivity
On 01/11/2012 11:48 PM, Alexander Graf wrote: Strictly from a QEMU perspective, we can't depend on APIs that aren't committed upstream yet. We can't release any qemu that depends on something not upstream. The question again is: When do we consider something upstream? This far from a

Re: [PATCH] KVM: PPC: refer to paravirt docs in header file

2012-01-12 Thread Avi Kivity
On 01/12/2012 01:39 AM, Alexander Graf wrote: On 12.01.2012, at 00:37, Scott Wood wrote: Instead of keeping separate copies of struct kvm_vcpu_arch_shared (one in the code, one in the docs) that inevitably fail to be kept in sync (already sr[] is missing from the doc version), just point

Re: [PATCH 1/2] KVM: Exception during emulation decode should propagate

2012-01-12 Thread Nadav Amit
On Jan 12, 2012, at 2:26 AM, Takuya Yoshikawa wrote: (2012/01/12 7:11), Takuya Yoshikawa wrote: On Wed, 11 Jan 2012 18:53:30 +0200 Nadav Amitna...@cs.technion.ac.il wrote: An exception might occur during decode (e.g., #PF during fetch). Currently, the exception is ignored and emulation

Re: [PATCH 1/2] KVM: Exception during emulation decode should propagate

2012-01-12 Thread Takuya Yoshikawa
(2012/01/12 18:07), Nadav Amit wrote: On Jan 12, 2012, at 2:26 AM, Takuya Yoshikawa wrote: (2012/01/12 7:11), Takuya Yoshikawa wrote: On Wed, 11 Jan 2012 18:53:30 +0200 Nadav Amitna...@cs.technion.ac.il wrote: An exception might occur during decode (e.g., #PF during fetch). Currently,

Re: Could anybody give some description about the implement of hyercall in kvm?

2012-01-12 Thread Stefan Hajnoczi
On Thu, Jan 12, 2012 at 4:38 AM, Liu ping fan kernelf...@gmail.com wrote: Could anybody give some description about the implement of hyercall in kvm? Or give some links about it? Try git grep hypercall arch/x86/kvm. Take a look at arch/x86/kvm/x86.c kvm_set_msr_common() and

Re: [PATCH 3/3] stop the periodic RTC update timer

2012-01-12 Thread Paolo Bonzini
On 01/12/2012 01:00 AM, Zhang, Yang Z wrote: Regarding the UIP bit, a guest could read it in a loop and wait for the value to change. But you can emulate it in cmos_ioport_read by reading the host time, that is, return 1 during 244us, 0 for remaining of the second, and have that in sync with

Re: [PATCH 3/3] stop the periodic RTC update timer

2012-01-12 Thread Paolo Bonzini
On 01/12/2012 01:51 AM, Zhang, Yang Z wrote: QEMU not being a simulator means that we always assume that the RTC is programmed for a 32768 Hz clock, for example, because any other setting would not make sense on a PC. We can use a 1-second (or higher, as in your patches) timer, rather than a

Re: [PATCH 3/3] stop the periodic RTC update timer

2012-01-12 Thread Marcelo Tosatti
On Thu, Jan 12, 2012 at 12:00:06AM +, Zhang, Yang Z wrote: -Original Message- From: Marcelo Tosatti [mailto:mtosa...@redhat.com] Regarding the UIP bit, a guest could read it in a loop and wait for the value to change. But you can emulate it in cmos_ioport_read by reading

Re: [PATCH 3/3] stop the periodic RTC update timer

2012-01-12 Thread Marcelo Tosatti
On Thu, Jan 12, 2012 at 07:59:06AM -0200, Marcelo Tosatti wrote: On Thu, Jan 12, 2012 at 12:00:06AM +, Zhang, Yang Z wrote: -Original Message- From: Marcelo Tosatti [mailto:mtosa...@redhat.com] Regarding the UIP bit, a guest could read it in a loop and wait for the

Re: [PATCH 2/2] KVM: Fix writeback on page boundary that propagate changes in spite of #PF

2012-01-12 Thread Gleb Natapov
On Wed, Jan 11, 2012 at 06:53:31PM +0200, Nadav Amit wrote: Consider the case in which an instruction emulation writeback is performed on a page boundary. In such case, if a #PF occurs on the second page, the write to the first page already occurred and cannot be retracted. Therefore,

RE: [PATCH 3/3] stop the periodic RTC update timer

2012-01-12 Thread Zhang, Yang Z
-Original Message- From: Marcelo Tosatti [mailto:mtosa...@redhat.com] Sent: Thursday, January 12, 2012 6:03 PM To: Zhang, Yang Z Cc: qemu-de...@nongnu.org; a...@redhat.com; aligu...@us.ibm.com; Zhang, Xiantao; Shan, Haitao; kvm@vger.kernel.org Subject: Re: [PATCH 3/3] stop the

Re: [PATCH 1/2] KVM: Exception during emulation decode should propagate

2012-01-12 Thread Avi Kivity
On 01/12/2012 11:07 AM, Nadav Amit wrote: When I cleaned up insn_fetch(), I thought that fetching the instruction which is being executed by the guest cannot cause #PF. The possibility that a meaningless userspace might similtaneously unmap the page, noted by Avi IIRC, was ignored

Re: [PATCH 2/2] KVM: Fix writeback on page boundary that propagate changes in spite of #PF

2012-01-12 Thread Avi Kivity
On 01/12/2012 12:12 PM, Gleb Natapov wrote: On Wed, Jan 11, 2012 at 06:53:31PM +0200, Nadav Amit wrote: Consider the case in which an instruction emulation writeback is performed on a page boundary. In such case, if a #PF occurs on the second page, the write to the first page already

Re: [PATCH 3/3] stop the periodic RTC update timer

2012-01-12 Thread Marcelo Tosatti
On Thu, Jan 12, 2012 at 10:26:17AM +0100, Paolo Bonzini wrote: On 01/12/2012 01:00 AM, Zhang, Yang Z wrote: Regarding the UIP bit, a guest could read it in a loop and wait for the value to change. But you can emulate it in cmos_ioport_read by reading the host time, that is, return 1 during

Re: [PATCH 2/2] KVM: Fix writeback on page boundary that propagate changes in spite of #PF

2012-01-12 Thread Gleb Natapov
On Thu, Jan 12, 2012 at 12:21:00PM +0200, Avi Kivity wrote: On 01/12/2012 12:12 PM, Gleb Natapov wrote: On Wed, Jan 11, 2012 at 06:53:31PM +0200, Nadav Amit wrote: Consider the case in which an instruction emulation writeback is performed on a page boundary. In such case, if a #PF

Re: RAM utilization issues

2012-01-12 Thread Avi Kivity
On 01/12/2012 11:27 AM, Jonathan Petersson wrote: Hi, Throughout the last few months we've been slowly migrating off our old VMware installation to KVM, most of it has been successful and people has been happy with the end-result. The new infrastructure obviously has a bit more of power

[PATCH 0/4] KVM updates for Linux 3.1.8

2012-01-12 Thread Avi Kivity
The following patches want to be applied to the 3.1 branch. All users must update. Alex Williamson (2): KVM: Remove ability to assign a device without iommu support KVM: Device assignment permission checks Avi Kivity (1): KVM guest: prevent tracing recursion with kvmclock Jan Kiszka (1):

[PATCH 1/4] KVM guest: prevent tracing recursion with kvmclock

2012-01-12 Thread Avi Kivity
Prevent tracing of preempt_disable() in get_cpu_var() in kvm_clock_read(). When CONFIG_DEBUG_PREEMPT is enabled, preempt_disable/enable() are traced and this causes the function_graph tracer to go into an infinite recursion. By open coding the preempt_disable() around the get_cpu_var(), we can use

[PATCH 2/4] KVM: x86: Prevent starting PIT timers in the absence of irqchip support

2012-01-12 Thread Avi Kivity
From: Jan Kiszka jan.kis...@siemens.com User space may create the PIT and forgets about setting up the irqchips. In that case, firing PIT IRQs will crash the host: BUG: unable to handle kernel NULL pointer dereference at 0128 IP: [a10f6280] kvm_set_irq+0x30/0x170 [kvm] ...

[PATCH 4/4] KVM: Device assignment permission checks

2012-01-12 Thread Avi Kivity
From: Alex Williamson alex.william...@redhat.com Only allow KVM device assignment to attach to devices which: - Are not bridges - Have BAR resources (assume others are special devices) - The user has permissions to use Assigning a bridge is a configuration error, it's not supported, and

[PATCH 3/4] KVM: Remove ability to assign a device without iommu support

2012-01-12 Thread Avi Kivity
From: Alex Williamson alex.william...@redhat.com This option has no users and it exposes a security hole that we can allow devices to be assigned without iommu protection. Make KVM_DEV_ASSIGN_ENABLE_IOMMU a mandatory option. Signed-off-by: Alex Williamson alex.william...@redhat.com

[PATCH] KVM: Move gfn_to_memslot() to kvm_host.h

2012-01-12 Thread Paul Mackerras
This moves __gfn_to_memslot() and search_memslots() from kvm_main.c to kvm_host.h to reduce the code duplication caused by the need for non-modular code in arch/powerpc/kvm/book3s_hv_rm_mmu.c to call gfn_to_memslot() in real mode. Rather than putting gfn_to_memslot() itself in a header, which

Re: [PATCH 3/3] stop the periodic RTC update timer

2012-01-12 Thread Paolo Bonzini
On 01/12/2012 11:20 AM, Marcelo Tosatti wrote: The point is not_correctness_. It is_atomicity_. Quoting you earlier This is incorrect, for two reasons. First, the UIP is in the spec, and we have to implement it. Second, reading the clock is not atomic, and waiting for UIP=0 gives you 220

Re: RAM utilization issues

2012-01-12 Thread Jonathan Petersson
On Thu, Jan 12, 2012 at 11:36 AM, Avi Kivity a...@redhat.com wrote: On 01/12/2012 11:27 AM, Jonathan Petersson wrote: Hi, Throughout the last few months we've been slowly migrating off our old VMware installation to KVM, most of it has been successful and people has been happy with the

Re: [PATCH 2/2] KVM: fix missing illegal instruction-trap in protected modes

2012-01-12 Thread Marcelo Tosatti
On Wed, Jan 11, 2012 at 11:19:50PM +0100, Stephan Bärwolf wrote: On 01/11/12 22:21, Marcelo Tosatti wrote: On Wed, Jan 11, 2012 at 09:01:10PM +0100, Stephan Bärwolf wrote: On 01/11/12 20:09, Marcelo Tosatti wrote: On Tue, Jan 10, 2012 at 03:26:49PM +0100, Stephan Bärwolf wrote: From

Re: RAM utilization issues

2012-01-12 Thread Avi Kivity
On 01/12/2012 12:47 PM, Jonathan Petersson wrote: What's the aggregate size of the guests (sum of all guest memory sizes)? How many guests? Are you in fact using the balloon? How? -- error compiling committee.c: too many arguments to function This is a sample from one of the

Re: kvm-s390: prep cleanup for sync registers patch series

2012-01-12 Thread Marcelo Tosatti
On Wed, Jan 11, 2012 at 11:19:31AM +0100, Christian Borntraeger wrote: Avi, Marcelo, here is a patch that reworks the setting of the prefix register. It is a prereq for the prefix patch in the following patch series about the sync registers in kvm_run. Applied, thanks. -- To unsubscribe

Re: kvm: provide synchronous registers in kvm_run

2012-01-12 Thread Alexander Graf
On 01/11/2012 11:20 AM, Christian Borntraeger wrote: Avi, Marcelo, here is the next version of the sync register patch series. A small hint for patch sets: $ git format-patch -n --cover-letter ... generates a / patch mail template that contains some summary about your set, like

Re: [PATCH v7] kvm: make vcpu life cycle separated from kvm instance

2012-01-12 Thread Avi Kivity
On 01/07/2012 04:55 AM, Liu Ping Fan wrote: From: Liu Ping Fan pingf...@linux.vnet.ibm.com Currently, vcpu will be destructed only after kvm instance is destroyed. This result to vcpu keep idle in kernel, but can not be freed when it is unplugged in guest. Change this to vcpu's destruction

Re: kvm: provide synchronous registers in kvm_run

2012-01-12 Thread Alexander Graf
On 01/11/2012 11:20 AM, Christian Borntraeger wrote: Avi, Marcelo, here is the next version of the sync register patch series. Whole set is: Acked-by: Alexander Graf ag...@suse.de Very cool interface addition! Alex -- To unsubscribe from this list: send the line unsubscribe kvm in the

Re: RAM utilization issues

2012-01-12 Thread Jonathan Petersson
It seams that our provider hasn't built a management engine for ballooning, however I found this project (https://github.com/aglitke/mom) which is compatible with libvirt however as the mangement-engine we use doesn't utilize libvirt it's not compatible, would you happen to know of a different

Re: RAM utilization issues

2012-01-12 Thread Avi Kivity
On 01/12/2012 02:56 PM, Jonathan Petersson wrote: It seams that our provider hasn't built a management engine for ballooning, however I found this project (https://github.com/aglitke/mom) which is compatible with libvirt however as the mangement-engine we use doesn't utilize libvirt it's not

Re: [PATCH 0/2][RFC] postcopy migration: Linux char device for postcopy

2012-01-12 Thread Avi Kivity
On 01/03/2012 04:25 PM, Andrea Arcangeli wrote: So the problem is if we do it in userland with the current functionality you'll run out of VMAs and slowdown performance too much. But all you need is the ability to map single pages in the address space. Would this also let

Re: [PATCH 0/2][RFC] postcopy migration: Linux char device for postcopy

2012-01-12 Thread Avi Kivity
On 01/04/2012 05:03 AM, Isaku Yamahata wrote: Yes, it's quite doable in user space(qemu) with a kernel-enhancement. And it would be easy to convert a separated daemon process into a thread in qemu. I think it should be done out side of qemu process for some reasons. (I just repeat same

Re: use of PMU in guest generates messages in host

2012-01-12 Thread David Ahern
On 01/11/2012 11:26 PM, Gleb Natapov wrote: On Wed, Jan 11, 2012 at 01:47:55PM -0700, David Ahern wrote: Using latest kernel tree (e343a895a9f342f239c5e3c5ffc6c0b1707e6244) which has KVM bits for using PMU in the guest. Host and guest are both running Fedora 16, 64-bit, with this kernel.

Re: [PATCH RFC 2/2] kvm: set affinity hint for assigned device msi

2012-01-12 Thread Avi Kivity
On 10/11/2011 08:38 PM, Michael S. Tsirkin wrote: To forward an interrupt to a vcpu that runs on a host cpu different from the current one, we need an ipi which likely will cost us as much as delivering the interrupt directly to that cpu would. Set irq affinity hint to point there, irq

Re: use of PMU in guest generates messages in host

2012-01-12 Thread Gleb Natapov
On Thu, Jan 12, 2012 at 07:02:12AM -0700, David Ahern wrote: On 01/11/2012 11:26 PM, Gleb Natapov wrote: On Wed, Jan 11, 2012 at 01:47:55PM -0700, David Ahern wrote: Using latest kernel tree (e343a895a9f342f239c5e3c5ffc6c0b1707e6244) which has KVM bits for using PMU in the guest. Host and

Re: [PATCH 21/21] postcopy: implement postcopy livemigration

2012-01-12 Thread Avi Kivity
On 01/04/2012 05:29 AM, Isaku Yamahata wrote: On Thu, Dec 29, 2011 at 06:06:10PM +0200, Avi Kivity wrote: On 12/29/2011 03:26 AM, Isaku Yamahata wrote: This patch implements postcopy livemigration. +/* RAM is allocated via umem for postcopy incoming mode */ +#define

Re: RFC: extend iommu_ops with domain attributes API

2012-01-12 Thread Joerg Roedel
On Tue, Jan 10, 2012 at 10:22:36AM -0600, Stuart Yoder wrote: As we work on mapping the Freescale IOMMU (called PAMU) into the existing Linux iommu infrastructure, one issue is that we have additional domain attributes that need to be set. This was discussed briefly a month ago or so and I

Re: RFC: iommu_ops -- limitation with current attach_dev() API

2012-01-12 Thread Joerg Roedel
On Tue, Jan 10, 2012 at 11:15:54AM -0600, Stuart Yoder wrote: We have devices that are capable of and need to access multiple domains.At the hardware level the device has multiple 'logical I/O device numbers' which is the index into our IOMMU tables. This means the device can target DMA

Re: [PATCH] KVM: Move gfn_to_memslot() to kvm_host.h

2012-01-12 Thread Alexander Graf
On 01/12/2012 11:41 AM, Paul Mackerras wrote: This moves __gfn_to_memslot() and search_memslots() from kvm_main.c to kvm_host.h to reduce the code duplication caused by the need for non-modular code in arch/powerpc/kvm/book3s_hv_rm_mmu.c to call gfn_to_memslot() in real mode. Rather than

[PATCH 0/2] KVM guest-kernel panics double fault

2012-01-12 Thread Stephan Bärwolf
From d62ca9897e9970d777aec1d399318b0df44489bd Mon Sep 17 00:00:00 2001 From: Stephan Baerwolf stephan.baerw...@tu-ilmenau.de Date: Thu, 12 Jan 2012 16:32:46 +0100 Subject: [PATCH 0/2] KVM guest-kernel panics double fault regarding: https://lkml.org/lkml/2011/12/28/170 On tested computers (Intel

[PATCH 1/2] KVM: extend struct x86_emulate_ops with get_cpuid

2012-01-12 Thread Stephan Bärwolf
From a8f796f81979094b81cb74535632786ce1ccf9bb Mon Sep 17 00:00:00 2001 From: Stephan Baerwolf stephan.baerw...@tu-ilmenau.de Date: Sun, 8 Jan 2012 23:25:59 + Subject: [PATCH 1/2] KVM: extend struct x86_emulate_ops with get_cpuid In order to be able to proceed checks on CPU-specific properties

[PATCH 2/2] KVM: fix missing illegal instruction-trap in protected modes

2012-01-12 Thread Stephan Bärwolf
From d62ca9897e9970d777aec1d399318b0df44489bd Mon Sep 17 00:00:00 2001 From: Stephan Baerwolf stephan.baerw...@tu-ilmenau.de Date: Sun, 8 Jan 2012 02:03:47 + Subject: [PATCH 2/2] KVM: fix missing illegal instruction-trap in protected modes On hosts without this patch, 32bit guests will crash

Re: [PATCH] KVM: Move gfn_to_memslot() to kvm_host.h

2012-01-12 Thread Avi Kivity
On 01/12/2012 12:41 PM, Paul Mackerras wrote: This moves __gfn_to_memslot() and search_memslots() from kvm_main.c to kvm_host.h to reduce the code duplication caused by the need for non-modular code in arch/powerpc/kvm/book3s_hv_rm_mmu.c to call gfn_to_memslot() in real mode. Rather than

[PATCH v2] KVM: Allow host IRQ sharing for assigned PCI 2.3 devices

2012-01-12 Thread Jan Kiszka
PCI 2.3 allows to generically disable IRQ sources at device level. This enables us to share legacy IRQs of such devices with other host devices when passing them to a guest. The new IRQ sharing feature introduced here is optional, user space has to request it explicitly. Moreover, user space can

Re: [PATCH] libvirt_vm.py: Set ignore_status to False in virsh_cmd().

2012-01-12 Thread Lucas Meneghel Rodrigues
On 01/11/2012 05:06 AM, tangchen wrote: utils.run()'s parameter ignore_status is set to True in virsh_cmd(). In this case we are not able to know whether the command succeeds. This patch sets it to False, and utils.run() will throw an exception when command fails. Problem with this is that

Re: [PATCH 0/2] KVM guest-kernel panics double fault

2012-01-12 Thread Jan Kiszka
On 2012-01-12 16:43, Stephan Bärwolf wrote: From d62ca9897e9970d777aec1d399318b0df44489bd Mon Sep 17 00:00:00 2001 From: Stephan Baerwolf stephan.baerw...@tu-ilmenau.de Date: Thu, 12 Jan 2012 16:32:46 +0100 Subject: [PATCH 0/2] KVM guest-kernel panics double fault regarding:

Re: [PATCH 0/4] KVM updates for Linux 3.1.8

2012-01-12 Thread Greg KH
On Thu, Jan 12, 2012 at 12:39:50PM +0200, Avi Kivity wrote: The following patches want to be applied to the 3.1 branch. All users must update. Do any of these also need to go to the 3.0 branch? thanks, greg k-h -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a

Re: [Android-virt] [PATCH v5 00/13] KVM/ARM Implementation

2012-01-12 Thread Christoffer Dall
On Thu, Jan 12, 2012 at 12:19 AM, Peter Maydell peter.mayd...@linaro.org wrote: On 12 January 2012 03:29, Christoffer Dall c.d...@virtualopensystems.com wrote: On Jan 11, 2012, at 8:48 AM, Peter Maydell wrote: (It would be quite useful to be able to boot a reasonably modern [read, ARMv7,

Re: [PATCH 0/4] KVM updates for Linux 3.1.8

2012-01-12 Thread Avi Kivity
On 01/12/2012 06:15 PM, Greg KH wrote: On Thu, Jan 12, 2012 at 12:39:50PM +0200, Avi Kivity wrote: The following patches want to be applied to the 3.1 branch. All users must update. Do any of these also need to go to the 3.0 branch? Yes. But for kvm we regression test stable patches, and

Re: [RFC PATCH 14/16] KVM: PPC: booke: category E.HV (GS-mode) support

2012-01-12 Thread Scott Wood
On Thu, Jan 12, 2012 at 05:44:26PM +1100, Benjamin Herrenschmidt wrote: On Tue, 2012-01-10 at 04:11 +0100, Alexander Graf wrote: This is what book3s does: case EMULATE_FAIL: printk(KERN_CRIT %s: emulation at %lx failed (%08x)\n,

Re: RFC: extend iommu_ops with domain attributes API

2012-01-12 Thread Scott Wood
On Thu, Jan 12, 2012 at 03:47:47PM +0100, Joerg Roedel wrote: On Tue, Jan 10, 2012 at 10:22:36AM -0600, Stuart Yoder wrote: A couple of the attributes I'm considering PAMU specific with a generic enable attribute: enum iommu_attr_type { IOMMU_ATTR_PAMU_GEOMETRY, // the

Re: use of PMU in guest generates messages in host

2012-01-12 Thread David Ahern
On 01/12/2012 07:14 AM, Gleb Natapov wrote: This is MSR_OFFCORE_RSP_0 MSR which is not (yet?) supported. What is your host cpu and qemu command line? Host CPU: Intel(R) Xeon(R) CPU E5540 @ 2.53GHz and '-cpu host' is used on the qemu command line. Use -cpu host,model=29 should

Re: [PATCH] KVM: Don't mistreat edge-triggered INIT IPI as INIT de-assert. (LAPIC)

2012-01-12 Thread Julian Stecklina
Am Freitag, den 23.12.2011, 08:40 -0200 schrieb Marcelo Tosatti: On Mon, Dec 19, 2011 at 02:14:27AM +0100, Julian Stecklina wrote: If the guest programs an IPI with level=0 (de-assert) and trig_mode=0 (edge), it is erroneously treated as INIT de-assert and ignored, but to quote the spec:

Re: RFC: extend iommu_ops with domain attributes API

2012-01-12 Thread Alex Williamson
On Tue, 2012-01-10 at 10:22 -0600, Stuart Yoder wrote: As we work on mapping the Freescale IOMMU (called PAMU) into the existing Linux iommu infrastructure, one issue is that we have additional domain attributes that need to be set. This was discussed briefly a month ago or so and I believe

Re: use of PMU in guest generates messages in host

2012-01-12 Thread Avi Kivity
On 01/12/2012 07:07 PM, David Ahern wrote: On 01/12/2012 07:14 AM, Gleb Natapov wrote: This is MSR_OFFCORE_RSP_0 MSR which is not (yet?) supported. What is your host cpu and qemu command line? Host CPU: Intel(R) Xeon(R) CPU E5540 @ 2.53GHz and '-cpu host' is used on the qemu

Re: RFC: iommu_ops -- limitation with current attach_dev() API

2012-01-12 Thread Scott Wood
On Thu, Jan 12, 2012 at 03:55:00PM +0100, Joerg Roedel wrote: On Tue, Jan 10, 2012 at 11:15:54AM -0600, Stuart Yoder wrote: We have devices that are capable of and need to access multiple domains.At the hardware level the device has multiple 'logical I/O device numbers' which is the

[PATCH] virt: Fix issue #90 - MonitorSocketError installing SLES

2012-01-12 Thread Lucas Meneghel Rodrigues
Sometimes, before a KVM VM shuts down cleanly, a Monitor connection reset error might happen, even though it's not a fatal condition for the test. So, let's handle better MonitorErrors happening during the unattended install loop. Signed-off-by: Lucas Meneghel Rodrigues l...@redhat.com ---

HV KVM fails on 970 due to HTAB allocation

2012-01-12 Thread Alexander Graf
Hi Paul, While trying to run HV KVM for something useful on 970, we stumbled over the following code path: /* Allocate guest's hashed page table */ hpt = __get_free_pages(GFP_KERNEL|__GFP_ZERO|__GFP_REPEAT|__GFP_NOWARN, HPT_ORDER - PAGE_SHIFT);

Re: [PATCH] vhost-net: add module alias (v2)

2012-01-12 Thread Thadeu Lima de Souza Cascardo
On Wed, Jan 11, 2012 at 09:16:53AM -0800, Stephen Hemminger wrote: By adding the correct module alias, programs won't have to explicitly call modprobe. Vhost-net will always be available if built into the kernel. It does require assigning a permanent minor number for depmod to work. Choose one

Re: [PATCH 0/5] VFIO core framework

2012-01-12 Thread Konrad Rzeszutek Wilk
On Tue, Jan 10, 2012 at 11:35:54AM -0700, Alex Williamson wrote: On Tue, 2012-01-10 at 11:26 -0500, Konrad Rzeszutek Wilk wrote: On Wed, Dec 21, 2011 at 02:42:02PM -0700, Alex Williamson wrote: This series includes the core framework for the VFIO driver. VFIO is a userspace driver

[PATCH] virt.tests: Fix issue #18 - set_link

2012-01-12 Thread Lucas Meneghel Rodrigues
With the recent introduction of an improved set_link interface (see 4ada095f8bd3a3435d6f51db0b4164c7d1122070 and a9ef23f9ed66ca5892f8a3c784b33093d6b5ced4), update the set_link test with it and resolve issue #18. Signed-off-by: Lucas Meneghel Rodrigues l...@redhat.com ---

Re: RFC: extend iommu_ops with domain attributes API

2012-01-12 Thread Stuart Yoder
On Thu, Jan 12, 2012 at 10:41 AM, Scott Wood scottw...@freescale.com wrote: On Thu, Jan 12, 2012 at 03:47:47PM +0100, Joerg Roedel wrote: On Tue, Jan 10, 2012 at 10:22:36AM -0600, Stuart Yoder wrote: A couple of the attributes I'm considering PAMU specific with a generic enable attribute:

Re: [PATCH 0/4] KVM updates for Linux 3.1.8

2012-01-12 Thread Greg KH
On Thu, Jan 12, 2012 at 06:25:43PM +0200, Avi Kivity wrote: On 01/12/2012 06:15 PM, Greg KH wrote: On Thu, Jan 12, 2012 at 12:39:50PM +0200, Avi Kivity wrote: The following patches want to be applied to the 3.1 branch. All users must update. Do any of these also need to go to the

[PATCHv3 0/2] kvm: set irq affinity for assigned devices

2012-01-12 Thread Michael S. Tsirkin
To forward an interrupt to a vcpu that runs on a host cpu different from the current one, we need an ipi which likely will cost us as much as delivering the interrupt directly to that cpu would. So it seems to make sense to set irq affinity hint to point there, irq balancer can then take this

[PATCHv3 2/2] kvm: set affinity hint for assigned device msi

2012-01-12 Thread Michael S. Tsirkin
To forward an interrupt to a vcpu that runs on a host cpu different from the current one, we need an ipi which likely will cost us as much as delivering the interrupt directly to that cpu would. Set irq affinity hint to point there, irq balancer can then take this into accound and balance

[PATCHv3 1/2] kvm: pass host irq number to set irq calls

2012-01-12 Thread Michael S. Tsirkin
Pass host irq number to functions that set guest irq. If unavailable, pass -1. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- arch/x86/kvm/i8254.c |4 ++-- arch/x86/kvm/lapic.c |2 +- arch/x86/kvm/x86.c |2 +- include/linux/kvm_host.h |7 ---

[PATCH] KVM: MMU: increment stats after event occurrence

2012-01-12 Thread Davidlohr Bueso
From: Davidlohr Bueso d...@gnu.org It makes more sense to actually increment statistics for tlb flushes and page table entry updates after such _events_ occur, instead of before. Signed-off-by: Davidlohr Bueso d...@gnu.org --- arch/x86/kvm/mmu.c |4 ++-- 1 files changed, 2 insertions(+), 2

Re: [PATCH 0/2][RFC] postcopy migration: Linux char device for postcopy

2012-01-12 Thread Benoit Hudzia
Hi, Sorry to jump to hijack the thread like that , however i would like to just to inform you that we recently achieve a milestone out of the research project I'm leading. We enhanced KVM in order to deliver post copy live migration using RDMA at kernel level. Few point on the architecture of

Re: [PATCH] KVM: MMU: increment stats after event occurrence

2012-01-12 Thread Takuya Yoshikawa
(2012/01/13 10:08), Davidlohr Bueso wrote: From: Davidlohr Buesod...@gnu.org It makes more sense to actually increment statistics for tlb flushes and page table entry updates after such _events_ occur, instead of before. Why? Takuya Signed-off-by: Davidlohr Buesod...@gnu.org ---

Re: [PATCH 0/2][RFC] postcopy migration: Linux char device for postcopy

2012-01-12 Thread Takuya Yoshikawa
(2012/01/13 10:09), Benoit Hudzia wrote: Hi, Sorry to jump to hijack the thread like that , however i would like to just to inform you that we recently achieve a milestone out of the research project I'm leading. We enhanced KVM in order to deliver post copy live migration using RDMA at

Re: [PATCH 0/2][RFC] postcopy migration: Linux char device for postcopy

2012-01-12 Thread Isaku Yamahata
Very interesting. We can cooperate for better (postcopy) live migration. The code doesn't seem available yet, I'm eager for it. On Fri, Jan 13, 2012 at 01:09:30AM +, Benoit Hudzia wrote: Hi, Sorry to jump to hijack the thread like that , however i would like to just to inform you that

Re: [PATCH 0/2][RFC] postcopy migration: Linux char device for postcopy

2012-01-12 Thread Andrea Arcangeli
On Thu, Jan 12, 2012 at 03:57:47PM +0200, Avi Kivity wrote: On 01/03/2012 04:25 PM, Andrea Arcangeli wrote: So the problem is if we do it in userland with the current functionality you'll run out of VMAs and slowdown performance too much. But all you need is the ability to

Re: [PATCH 0/2][RFC] postcopy migration: Linux char device for postcopy

2012-01-12 Thread Andrea Arcangeli
On Thu, Jan 12, 2012 at 03:59:59PM +0200, Avi Kivity wrote: On 01/04/2012 05:03 AM, Isaku Yamahata wrote: Yes, it's quite doable in user space(qemu) with a kernel-enhancement. And it would be easy to convert a separated daemon process into a thread in qemu. I think it should be done out

Re: [PATCH 0/2][RFC] postcopy migration: Linux char device for postcopy

2012-01-12 Thread Isaku Yamahata
One more question. Does your architecture/implementation (in theory) allow KVM memory features like swap, KSM, THP? On Fri, Jan 13, 2012 at 11:03:23AM +0900, Isaku Yamahata wrote: Very interesting. We can cooperate for better (postcopy) live migration. The code doesn't seem available yet, I'm

Re: [PATCH] vhost-net: add module alias (v2.1)

2012-01-12 Thread David Miller
From: Stephen Hemminger shemmin...@vyatta.com Date: Wed, 11 Jan 2012 21:30:38 -0800 Subject: vhost-net: add module alias (v2.1) By adding some module aliases, programs (or users) won't have to explicitly call modprobe. Vhost-net will always be available if built into the kernel. It does

Re: [PATCH] vhost-net: add module alias (v2.1)

2012-01-12 Thread Kay Sievers
On Fri, Jan 13, 2012 at 05:07, David Miller da...@davemloft.net wrote: From: Stephen Hemminger shemmin...@vyatta.com Date: Wed, 11 Jan 2012 21:30:38 -0800 Subject: vhost-net: add module alias (v2.1) By adding some module aliases, programs (or users) won't have to explicitly call modprobe.

Re: HV KVM fails on 970 due to HTAB allocation

2012-01-12 Thread Paul Mackerras
On Thu, Jan 12, 2012 at 07:16:51PM +0100, Alexander Graf wrote: While trying to run HV KVM for something useful on 970, we stumbled over the following code path: /* Allocate guest's hashed page table */ hpt = __get_free_pages(GFP_KERNEL|__GFP_ZERO|__GFP_REPEAT|__GFP_NOWARN,

[PATCH v3] KVM: Move gfn_to_memslot() to kvm_host.h

2012-01-12 Thread Paul Mackerras
This moves __gfn_to_memslot() and search_memslots() from kvm_main.c to kvm_host.h to reduce the code duplication caused by the need for non-modular code in arch/powerpc/kvm/book3s_hv_rm_mmu.c to call gfn_to_memslot() in real mode. Rather than putting gfn_to_memslot() itself in a header, which

RE: where should I report kvm kernel bug?

2012-01-12 Thread Ren, Yongjie
When someone comments in a bug in kernel.org's bugzilla, the bug reporter or the CC list can't receive an update email for that. For example, Gleb and Avi updated the following bug, but I (the reporter) didn't receive an email to notify about that.

Biweekly KVM Test report, kernel 188fc331... qemu 9501d0f1...

2012-01-12 Thread Ren, Yongjie
Hi All, This is KVM upstream test result against kvm.git 188fc33198ddb1469562d40de33bcc29e7e2ed5f based on kernel 3.2.0, and qemu-kvm.git 9501d0f1b6efc83f69d06b27a625bad71d30d58b. We found 2 new bugs and no bug got fixed during the past two weeks. New issues (2): 1. rhel5u5 guest panic when

Re: Could anybody give some description about the implement of hyercall in kvm?

2012-01-12 Thread Liu ping fan
On Thu, Jan 12, 2012 at 5:21 PM, Stefan Hajnoczi stefa...@gmail.com wrote: On Thu, Jan 12, 2012 at 4:38 AM, Liu ping fan kernelf...@gmail.com wrote: Could anybody give some description about the implement of hyercall in kvm? Or give some links about it? Try git grep hypercall arch/x86/kvm.

Re: [PATCH] KVM: PPC: refer to paravirt docs in header file

2012-01-12 Thread Avi Kivity
On 01/12/2012 01:39 AM, Alexander Graf wrote: On 12.01.2012, at 00:37, Scott Wood wrote: Instead of keeping separate copies of struct kvm_vcpu_arch_shared (one in the code, one in the docs) that inevitably fail to be kept in sync (already sr[] is missing from the doc version), just point

[PATCH] KVM: Move gfn_to_memslot() to kvm_host.h

2012-01-12 Thread Paul Mackerras
This moves __gfn_to_memslot() and search_memslots() from kvm_main.c to kvm_host.h to reduce the code duplication caused by the need for non-modular code in arch/powerpc/kvm/book3s_hv_rm_mmu.c to call gfn_to_memslot() in real mode. Rather than putting gfn_to_memslot() itself in a header, which

Re: [PATCH] KVM: Move gfn_to_memslot() to kvm_host.h

2012-01-12 Thread Alexander Graf
On 01/12/2012 11:41 AM, Paul Mackerras wrote: This moves __gfn_to_memslot() and search_memslots() from kvm_main.c to kvm_host.h to reduce the code duplication caused by the need for non-modular code in arch/powerpc/kvm/book3s_hv_rm_mmu.c to call gfn_to_memslot() in real mode. Rather than

Re: HV KVM fails on 970 due to HTAB allocation

2012-01-12 Thread Paul Mackerras
On Thu, Jan 12, 2012 at 07:16:51PM +0100, Alexander Graf wrote: While trying to run HV KVM for something useful on 970, we stumbled over the following code path: /* Allocate guest's hashed page table */ hpt = __get_free_pages(GFP_KERNEL|__GFP_ZERO|__GFP_REPEAT|__GFP_NOWARN,

[PATCH v3] KVM: Move gfn_to_memslot() to kvm_host.h

2012-01-12 Thread Paul Mackerras
This moves __gfn_to_memslot() and search_memslots() from kvm_main.c to kvm_host.h to reduce the code duplication caused by the need for non-modular code in arch/powerpc/kvm/book3s_hv_rm_mmu.c to call gfn_to_memslot() in real mode. Rather than putting gfn_to_memslot() itself in a header, which