Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Eric Northup
On Tue, Feb 17, 2015 at 4:32 AM, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Feb 17, 2015 at 11:59:48AM +0100, Paolo Bonzini wrote: On 17/02/2015 10:02, Michael S. Tsirkin wrote: Increasing VHOST_MEMORY_MAX_NREGIONS from 65 to 509 to match KVM_USER_MEM_SLOTS fixes issue for

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Michael S. Tsirkin
On Tue, Feb 17, 2015 at 04:53:45PM -0800, Eric Northup wrote: On Tue, Feb 17, 2015 at 4:32 AM, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Feb 17, 2015 at 11:59:48AM +0100, Paolo Bonzini wrote: On 17/02/2015 10:02, Michael S. Tsirkin wrote: Increasing VHOST_MEMORY_MAX_NREGIONS

H_CLEAR_REF and H_CLEAR_MOD

2015-02-17 Thread Nathan Whitehorn
It seems like KVM doesn't implement the H_CLEAR_REF and H_CLEAR_MOD hypervisor calls, which are absolutely critical for memory management in the FreeBSD kernel (and are marked mandatory in the PAPR manual). It seems some patches have been contributed already in

[PULL] virtio-next

2015-02-17 Thread Rusty Russell
The following changes since commit b97f880c8342fd6e49a02c9ef7507a678722b2b3: Merge branch 'for-3.19-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata (2015-01-21 07:54:16 +1200) are available in the git repository at:

[RFC PATCH v2 02/15] cpu-model: Introduce option --probe to switch into probe mode

2015-02-17 Thread Michael Mueller
The option --probe allows to switch into probe mode also for machines different from none. If one or more accelerators are specified these accelerators are used to provide probable properties. If no accelerator is given a list of accellerators that support probing is used. Signed-off-by: Michael

[RFC PATCH v2 09/15] cpu-model/s390: Add KVM VM attribute interface routines

2015-02-17 Thread Michael Mueller
The patch implements routines to set and retrieve processor configuration data and to retrieve machine configuration data. The machine related data is used together with the cpu model facility lists to determine the list of supported cpu models of this host. The above mentioned routines have QEMU

[RFC PATCH v2 14/15] cpu-model/s390: Add cpu model selection routine

2015-02-17 Thread Michael Mueller
This patch basically implements the routine: - s390_select_cpu_model() It tests if the the cpu classes have been initialized and the requested cpu model is either a valid model or a valid alias. If these conditions are met, the associated cpu model properties (cpu identifier, ibc value, cpu

[RFC PATCH v2 04/15] cpu-model/s390: Introduce S390 CPU models

2015-02-17 Thread Michael Mueller
This patch implements the static part of the s390 cpu class definitions. It defines s390 cpu models by means of virtual cpu ids (enum) which contain information on the cpu generation, the machine class, the GA number and the machine type. The cpu id is used to instantiate a cpu class per cpu

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Igor Mammedov
On Tue, 17 Feb 2015 14:29:31 +0100 Michael S. Tsirkin m...@redhat.com wrote: On Tue, Feb 17, 2015 at 02:11:37PM +0100, Paolo Bonzini wrote: On 17/02/2015 13:32, Michael S. Tsirkin wrote: On Tue, Feb 17, 2015 at 11:59:48AM +0100, Paolo Bonzini wrote: On 17/02/2015 10:02,

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Paolo Bonzini
On 17/02/2015 16:02, Igor Mammedov wrote: Not if there are about 6 regions, I think. When memslots where increased to 509 and look up of them was replaced on binary search results were on par with linear search for a default 13 memslots VM. Adding LRU You mean MRU. :) cache helped

[RFC PATCH v2 07/15] cpu-model/s390: Add cpu model alias definition routines

2015-02-17 Thread Michael Mueller
This patch implements the infrastructure to dynamically add cpu model aliases. Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com --- target-s390x/cpu-models.c | 77 +++ target-s390x/cpu-models.h

[RFC PATCH v2 11/15] cpu-model/s390: Add QMP command query-cpu-model

2015-02-17 Thread Michael Mueller
This patch implements a new QMP request named 'query-cpu-model'. It returns the cpu model of cpu 0 and its backing accelerator. request: {execute : query-cpu-model } answer: {return : {name: 2827-ga2, accelerator: kvm }} Alias names are resolved to their respective machine type and GA names

[RFC PATCH v2 10/15] cpu-model/s390: Add cpu class initialization routines

2015-02-17 Thread Michael Mueller
This patch provides routines to dynamically update the previously defined S390 cpu classes in the current host context. The main function performing this process is s390_setup_cpu_classes(). It takes the current host context as parameter to setup the classes accordingly. It basically performs the

[RFC PATCH v2 12/15] cpu-model/s390: Extend QMP command query-cpu-definitions

2015-02-17 Thread Michael Mueller
This patch implements the QMP command 'query-cpu-definitions' in the S390 context. The command returns a in terms of machine release date descending sorted list of cpu model names in the current host context. A consumer may successfully request each listed cpu model as long for a given accelerator

[RFC PATCH v2 01/15] cpu-model: Introduce probe mode for machine none

2015-02-17 Thread Michael Mueller
QEMU now switches into probe mode when the selected machine is none and no specific accelerator(s) has been requested (i.e.: -machine none). In probe mode a by ARCH_CONFIG defines predefined list of accelerators run their init() methods. Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com ---

[RFC PATCH v2 00/15] QEMU: s390: cpu model implementation

2015-02-17 Thread Michael Mueller
This patch set in combination with its kernel kvm patch set proposes an implementation of S390 cpu models. The origin of this item is to provide a means for management interfaces like libvirt to draw decisions if life guest migration to a target hypervisor is reasonable. A migration constraint is

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Michael S. Tsirkin
On Tue, Feb 17, 2015 at 02:11:37PM +0100, Paolo Bonzini wrote: On 17/02/2015 13:32, Michael S. Tsirkin wrote: On Tue, Feb 17, 2015 at 11:59:48AM +0100, Paolo Bonzini wrote: On 17/02/2015 10:02, Michael S. Tsirkin wrote: Increasing VHOST_MEMORY_MAX_NREGIONS from 65 to 509 to match

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Paolo Bonzini
On 17/02/2015 14:29, Michael S. Tsirkin wrote: On Tue, Feb 17, 2015 at 02:11:37PM +0100, Paolo Bonzini wrote: On 17/02/2015 13:32, Michael S. Tsirkin wrote: On Tue, Feb 17, 2015 at 11:59:48AM +0100, Paolo Bonzini wrote: On 17/02/2015 10:02, Michael S. Tsirkin wrote: Increasing

[RFC PATCH v2 03/15] cpu-model: Introduce stub routine cpu_desc_avail

2015-02-17 Thread Michael Mueller
This patch introduces the function cpu_desc_avail() which returns by default true if not architecture specific implemented. Its intention is to indicate if the cpu model description is available for display by list_cpus(). This change allows cpu model descriptions to become dynamically created by

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Igor Mammedov
On Tue, 17 Feb 2015 13:32:12 +0100 Michael S. Tsirkin m...@redhat.com wrote: On Tue, Feb 17, 2015 at 11:59:48AM +0100, Paolo Bonzini wrote: On 17/02/2015 10:02, Michael S. Tsirkin wrote: Increasing VHOST_MEMORY_MAX_NREGIONS from 65 to 509 to match KVM_USER_MEM_SLOTS fixes issue

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Paolo Bonzini
On 17/02/2015 15:44, Igor Mammedov wrote: As alternative: we can filter out hotplugged memory and vhost will continue to work with only initial memory. So question is id we have to tell vhost about hotplugged memory? Yes, I think so. Paolo -- To unsubscribe from this list: send the line

[RFC PATCH v2 06/15] cpu-model/s390: Define cpu model specific facility lists

2015-02-17 Thread Michael Mueller
This patch defines S390 cpu facilities and their presence at the different cpu model levels. Beside defining a base which facilities have to be requested per cpu model, these sets are associated to the defined cpu classes and used to calculate the list of supported cpu models in context of the

[RFC PATCH v2 05/15] cpu-model/s390: Introduce S390 CPU facilities

2015-02-17 Thread Michael Mueller
The patch introduces S390 CPU facilities bit numbers and names as well as the architectural facility size limit in bytes. Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com --- target-s390x/cpu-facilities.h | 76 +++ 1 file changed, 76 insertions(+)

[RFC PATCH v2 15/15] cpu-model/s390: Enable S390 cpu model

2015-02-17 Thread Michael Mueller
This patch enables QEMU to instantiate S390 CPUs with cpu model types. Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com --- hw/s390x/s390-virtio.c | 6 ++ target-s390x/helper.c | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/hw/s390x/s390-virtio.c

[RFC PATCH v2 13/15] cpu-model/s390: Add processor property routines

2015-02-17 Thread Michael Mueller
This patch implements the functions: - s390_get_proceccor_props() - s390_set_proceccor_props() They can be used to request or retrieve processor related information from an accelerator. That information comprises the cpu identifier, the ICB value and the facility lists. Signed-off-by: Michael

[RFC PATCH v2 08/15] cpu-model/s390: Update linux-headers/asm-s390/kvm.h

2015-02-17 Thread Michael Mueller
Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com --- linux-headers/asm-s390/kvm.h | 20 1 file changed, 20 insertions(+) diff --git a/linux-headers/asm-s390/kvm.h b/linux-headers/asm-s390/kvm.h index d36b2fa..e38c942 100644 --- a/linux-headers/asm-s390/kvm.h +++

Re: [nVMX] With 3.20.0-0.rc0.git5.1 on L0, booting L2 guest results in L1 *rebooting*

2015-02-17 Thread Bandan Das
Kashyap Chamarthy kcham...@redhat.com writes: .. Does enable_apicv make a difference? Actually, I did perform a test (on Paolo's suggestion on IRC) with enable_apicv=0 on physical host, and it didn't make any difference: $ cat /proc/cmdline

Re: [nVMX] With 3.20.0-0.rc0.git5.1 on L0, booting L2 guest results in L1 *rebooting*

2015-02-17 Thread Jan Kiszka
On 2015-02-17 19:00, Bandan Das wrote: Kashyap Chamarthy kcham...@redhat.com writes: .. Does enable_apicv make a difference? Actually, I did perform a test (on Paolo's suggestion on IRC) with enable_apicv=0 on physical host, and it didn't make any difference: $ cat /proc/cmdline

Re: [Qemu-devel] [RFC PATCH v2 12/15] cpu-model/s390: Extend QMP command query-cpu-definitions

2015-02-17 Thread Eric Blake
On 02/17/2015 07:24 AM, Michael Mueller wrote: This patch implements the QMP command 'query-cpu-definitions' in the S390 context. The command returns a in terms of machine release date descending sorted list of cpu model names in the current host context. returns a list of cpu model names

Re: [PATCH V5] x86 spinlock: Fix memory corruption on completing completions

2015-02-17 Thread Sasha Levin
On 02/15/2015 01:01 AM, Raghavendra K T wrote: On 02/15/2015 11:25 AM, Raghavendra K T wrote: Paravirt spinlock clears slowpath flag after doing unlock. As explained by Linus currently it does: prev = *lock; add_smp(lock-tickets.head, TICKET_LOCK_INC);

Re: [patch -rt 1/2] KVM: use simple waitqueue for vcpu-wq

2015-02-17 Thread Sebastian Andrzej Siewior
* Peter Zijlstra | 2015-01-21 16:07:16 [+0100]: On Tue, Jan 20, 2015 at 01:16:13PM -0500, Steven Rostedt wrote: I'm actually wondering if we should just nuke the _interruptible() version of swait. As it should only be all interruptible or all not interruptible, that the swait_wake() should

Re: [Qemu-devel] [RFC PATCH v2 11/15] cpu-model/s390: Add QMP command query-cpu-model

2015-02-17 Thread Eric Blake
On 02/17/2015 07:24 AM, Michael Mueller wrote: This patch implements a new QMP request named 'query-cpu-model'. It returns the cpu model of cpu 0 and its backing accelerator. request: {execute : query-cpu-model } answer: {return : {name: 2827-ga2, accelerator: kvm }} Alias names

Re: [Qemu-devel] [RFC PATCH v2 02/15] cpu-model: Introduce option --probe to switch into probe mode

2015-02-17 Thread Eric Blake
On 02/17/2015 07:24 AM, Michael Mueller wrote: The option --probe allows to switch into probe mode also for machines different from none. If one or more accelerators are specified these accelerators are used to provide probable properties. If no accelerator is given a list of accellerators

Re: KVM call for agenda for 2015-02-17

2015-02-17 Thread Juan Quintela
Juan Quintela quint...@redhat.com wrote: Hi Please, send any topic that you are interested in covering. As there are no agenda, call got cancelled. Have a good day, Juan. Call details: By popular demand, a google calendar public entry with it

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Paolo Bonzini
On 17/02/2015 10:02, Michael S. Tsirkin wrote: Increasing VHOST_MEMORY_MAX_NREGIONS from 65 to 509 to match KVM_USER_MEM_SLOTS fixes issue for vhost-net. Signed-off-by: Igor Mammedov imamm...@redhat.com This scares me a bit: each region is 32byte, we are talking a 16K allocation that

Re: [nVMX] With 3.20.0-0.rc0.git5.1 on L0, booting L2 guest results in L1 *rebooting*

2015-02-17 Thread Kashyap Chamarthy
On Tue, Feb 17, 2015 at 07:02:14AM +0100, Jan Kiszka wrote: On 2015-02-16 21:40, Kashyap Chamarthy wrote: I can observe this only one of the Intel Xeon machines (which has 48 CPUs and 1TB memory), but very reliably reproducible. Reproducer: - Just ensure physical host (L0) and

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Michael S. Tsirkin
On Fri, Feb 13, 2015 at 03:49:59PM +, Igor Mammedov wrote: since commit 1d4e7e3 kvm: x86: increase user memory slots to 509 it became possible to use a bigger amount of memory slots, which is used by memory hotplug for registering hotplugged memory. However QEMU aborts if it's used

Re: nSVM: Booting L2 results in L1 hang and a skip_emulated_instruction

2015-02-17 Thread Kashyap Chamarthy
On Thu, Feb 12, 2015 at 07:12:06AM +0100, Jan Kiszka wrote: On 2015-02-11 19:12, Kashyap Chamarthy wrote: Hi, This was tested with kernel-3.19.0-1.fc22) and QEMU (qemu-2.2.0-5.fc22) on L0 L1. Description --- Inside L1, boot a nested KVM guest (L2) . Instead of a

Re: [Xen-devel] [PATCH V5] x86 spinlock: Fix memory corruption on completing completions

2015-02-17 Thread Raghavendra K T
On 02/16/2015 10:17 PM, David Vrabel wrote: On 15/02/15 17:30, Raghavendra K T wrote: --- a/arch/x86/xen/spinlock.c +++ b/arch/x86/xen/spinlock.c @@ -41,7 +41,7 @@ static u8 zero_stats; static inline void check_zero(void) { u8 ret; - u8 old = ACCESS_ONCE(zero_stats); +

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Paolo Bonzini
On 17/02/2015 13:32, Michael S. Tsirkin wrote: On Tue, Feb 17, 2015 at 11:59:48AM +0100, Paolo Bonzini wrote: On 17/02/2015 10:02, Michael S. Tsirkin wrote: Increasing VHOST_MEMORY_MAX_NREGIONS from 65 to 509 to match KVM_USER_MEM_SLOTS fixes issue for vhost-net. Signed-off-by: Igor

Re: [PATCH] vhost: support upto 509 memory regions

2015-02-17 Thread Michael S. Tsirkin
On Tue, Feb 17, 2015 at 11:59:48AM +0100, Paolo Bonzini wrote: On 17/02/2015 10:02, Michael S. Tsirkin wrote: Increasing VHOST_MEMORY_MAX_NREGIONS from 65 to 509 to match KVM_USER_MEM_SLOTS fixes issue for vhost-net. Signed-off-by: Igor Mammedov imamm...@redhat.com This