[PATCH/RFC] s390: Provide a configuration and control device

2014-04-01 Thread Christian Borntraeger
We want to configure several things in KVM that go beyond what ENABLE_CAP (we need payload) or ONE_REG (we need it for the VM and we need to do more complex actions) can provide. Instead of adding several s390 specific ioctls, lets provide a configuration and control device that encapsulates

Re: [PATCH/RFC] KVM: s390: Add S390 configuration and control kvm device

2014-04-01 Thread Christian Borntraeger
On 01/04/14 16:58, Alexander Graf wrote: On 04/01/2014 04:47 PM, Christian Borntraeger wrote: From: Ekaterina Tumanova tuman...@linux.vnet.ibm.com Add KVM_DEV_TYPE_S390_CONFIG kvm device that contains configuration and control attributes of particular vm. The device is created

Re: [PATCH/RFC] s390x/kvm: implement and use QEMU config device for s390

2014-04-01 Thread Christian Borntraeger
On 01/04/14 17:38, Paolo Bonzini wrote: Il 01/04/2014 16:47, Christian Borntraeger ha scritto: From: Ekaterina Tumanova tuman...@linux.vnet.ibm.com The following patch adds Qemu CONFIG device, which interacts with kvm CONFIG device by calling KVM_CREATE_DEVICE (to create the device in kernel

Re: [PATCH/RFC] KVM: s390: Add S390 configuration and control kvm device

2014-04-01 Thread Christian Borntraeger
On 01/04/14 17:12, Alexander Graf wrote: On 04/01/2014 05:04 PM, Christian Borntraeger wrote: On 01/04/14 16:58, Alexander Graf wrote: On 04/01/2014 04:47 PM, Christian Borntraeger wrote: From: Ekaterina Tumanova tuman...@linux.vnet.ibm.com Add KVM_DEV_TYPE_S390_CONFIG kvm device

Re: [PATCH/RFC] s390: Provide a configuration and control device

2014-04-01 Thread Christian Borntraeger
On 01/04/14 16:59, Alexander Graf wrote: On 04/01/2014 04:47 PM, Christian Borntraeger wrote: We want to configure several things in KVM that go beyond what ENABLE_CAP (we need payload) or ONE_REG (we need it for the VM and we need to do more complex actions) can provide. Instead of adding

Re: [PATCH/RFC] KVM: s390: Add S390 configuration and control kvm device

2014-04-01 Thread Christian Borntraeger
On 01/04/14 21:36, Alexander Graf wrote: [...] Speaking of which, why don't we just forward STSI to user space with an ENABLE_CAP and handle all of this there? It's not performance critical at all, right? No, performance is not critical. The thing is, that we definitely need the kernel to

Re: [Qemu-devel] KVM call agenda for 2014-04-01

2014-03-31 Thread Christian Borntraeger
On 31/03/14 12:51, Andreas Färber wrote: Hi, Am 31.03.2014 12:40, schrieb Juan Quintela: Please, send any topic that you are interested in covering. I would like to discuss the state of the QEMU release process, please: * -rc1 has not been tagged. * Who besides Anthony could upload a

Re: [PATCH v2] perf/tool: Fix usage of trace events with '-' in trace system name.

2014-03-27 Thread Christian Borntraeger
-by: Christian Borntraeger borntrae...@de.ibm.com When doing a V2, you should remove my Signed-off-by. ;-) But at least we can now add my Acked-by: Christian Borntraeger borntrae...@de.ibm.com Ingo, Peter, Paul, If you agree with this solution, I would like to have this in the next merge

Re: [PATCH v3 0/5] qemu: irqfds for s390x

2014-03-27 Thread Christian Borntraeger
s390x-irqfd has been updated accordingly. The whole series looks good to me. Acked-by: Christian Borntraeger borntrae...@de.ibm.com Tested-by: Christian Borntraeger borntrae...@de.ibm.com Paolo, since we also touch KVM code, and the necessary counter part in in Linux kvm/next we could push

Re: [RFC]Two ideas to optimize updating irq routing table

2014-03-26 Thread Christian Borntraeger
grace period is no better than RCU. Really? This is not what Christian Borntraeger claimed at http://permalink.gmane.org/gmane.comp.emulators.kvm.devel/118083 -- in fact, Andrew Theurer is currently testing a variant of that patch and I was going to post it for 3.16. Have you tried

Re: [RFC]Two ideas to optimize updating irq routing table

2014-03-26 Thread Christian Borntraeger
On 26/03/14 09:22, Gonglei (Arei) wrote: Without patches, ping time can jump from 0.3ms to 2ms-30ms. With synchronize_srcu patch, ping time is worse. With synchronize_srcu_expedited patch, ping time is overall good, though sometimes ping time jump to 1ms-3ms. Just to understand whats

[PULL 0/4] KVM: s390: last fixes for next merge window

2014-03-25 Thread Christian Borntraeger
workloads Christian Borntraeger (1): KVM: s390: randomize sca address Jens Freimann (2): KVM: s390: fix calculation of idle_mask array size KVM: s390: clear local interrupts at cpu initial reset Thomas Huth (1

[PULL 1/4] KVM: s390: randomize sca address

2014-03-25 Thread Christian Borntraeger
We allocate a page for the 2k sca, so lets use the space to improve hit rate of some internal cpu caches. No need to change the freeing of the page, as this will shift away the page offset bits anyway. Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com Reviewed-by: David Hildenbrand d

[PULL 4/4] KVM: s390: clear local interrupts at cpu initial reset

2014-03-25 Thread Christian Borntraeger
From: Jens Freimann jf...@linux.vnet.ibm.com Empty list of local interrupts when vcpu goes through initial reset to provide a clean state Signed-off-by: Jens Freimann jf...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/interrupt.c | 14

[PULL 2/4] KVM: s390: fix calculation of idle_mask array size

2014-03-25 Thread Christian Borntraeger
(long) which returnes the size in bytes, but BITS_TO_LONGS Signed-off-by: Jens Freimann jf...@linux.vnet.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/kvm_host.h | 3 +-- 1 file changed, 1 insertion

[PULL 3/4] KVM: s390: Fix possible memory leak in SIGP functions

2014-03-25 Thread Christian Borntraeger
. Signed-off-by: Thomas Huth th...@linux.vnet.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/sigp.c | 14 ++ 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/arch/s390/kvm/sigp.c b

Re: [PULL 1/4] KVM: s390: randomize sca address

2014-03-25 Thread Christian Borntraeger
On 25/03/14 14:53, Paolo Bonzini wrote: Il 25/03/2014 14:35, Christian Borntraeger ha scritto: We allocate a page for the 2k sca, so lets use the space to improve hit rate of some internal cpu caches. No need to change the freeing of the page, as this will shift away the page offset bits

Re: [PULL 4/4] KVM: s390: clear local interrupts at cpu initial reset

2014-03-25 Thread Christian Borntraeger
On 25/03/14 14:56, Paolo Bonzini wrote: Il 25/03/2014 14:35, Christian Borntraeger ha scritto: +spin_lock_bh(li-lock); +list_for_each_entry_safe(inti, n, li-list, list) { +list_del(inti-list); +kfree(inti); +} +atomic_set(li-active, 0); +spin_unlock_bh

Re: [PULL 3/4] KVM: s390: Fix possible memory leak in SIGP functions

2014-03-25 Thread Christian Borntraeger
On 25/03/14 15:02, Paolo Bonzini wrote: Il 25/03/2014 14:35, Christian Borntraeger ha scritto: From: Thomas Huth th...@linux.vnet.ibm.com When kvm_get_vcpu() returned NULL for the destination CPU in __sigp_emergency() or __sigp_external_call(), the memory for the inti structure

Re: Preparing kvm/next for first pull request of 3.15 merge window

2014-03-25 Thread Christian Borntraeger
On 25/03/14 18:29, Paolo Bonzini wrote: Hi all, I've pushed the last set of updates to kvm/next for the 3.15 merge window. I don't expect any other changes for either x86 or s390 (thanks Christian!). The pull request is already pretty beefy. I would like to know from ARM and PPC

Re: Preparing kvm/next for first pull request of 3.15 merge window

2014-03-25 Thread Christian Borntraeger
On 25/03/14 18:29, Paolo Bonzini wrote: Hi all, I've pushed the last set of updates to kvm/next for the 3.15 merge window. I don't expect any other changes for either x86 or s390 (thanks Christian!). The pull request is already pretty beefy. I would like to know from ARM and PPC

Re: [PATCH v3 0/4] KVM: irqfds for s390

2014-03-24 Thread Christian Borntraeger
On 21/03/14 13:52, Cornelia Huck wrote: Hi, here's the next iteration of my patchset introducing irqfds for s390. Changes from v2: - rebased against current kvm/queue - kvm common code lock fix is already in queue - move some changes that belonged in patch 2 from patch 3 - add a limit

[PATCH] perf/tool: Fix usage of trace events with '-' in trace system name.

2014-03-24 Thread Christian Borntraeger
: 'kvm-s390:*' This patch adds an extra rule to event_legacy_tracepoint which handles those cases. Without the patch, perf will not accept such tracepoints in the -e option. Signed-off-by: Alexander Yarygin yary...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com

Re: [PATCH v2 2/5] KVM: Add per-vm capability enablement.

2014-03-21 Thread Christian Borntraeger
-by: Cornelia Huck cornelia.h...@de.ibm.com Acked-by: Christian Borntraeger borntrae...@de.ibm.com --- Documentation/virtual/kvm/api.txt |6 -- arch/s390/kvm/kvm-s390.c | 24 include/uapi/linux/kvm.h |5 + 3 files changed, 33 insertions(+), 2

Re: [PATCH v2 3/5] KVM: s390: adapter interrupt sources

2014-03-21 Thread Christian Borntraeger
fails. Otherwise looks good. Acked-by: Christian Borntraeger borntrae...@de.ibm.com -- 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: [PATCH v2 4/5] KVM: s390: irq routing for adapter interrupts.

2014-03-21 Thread Christian Borntraeger
be merged into the previous patch? Otherwise: Acked-by: Christian Borntraeger borntrae...@de.ibm.com @@ -1272,3 +1278,123 @@ struct kvm_device_ops kvm_flic_ops = { .create = flic_create, .destroy = flic_destroy, }; + +static unsigned long get_ind_bit(__u64 addr, unsigned long

[PULL 2/2] KVM: s390: Optimize ucontrol path

2014-03-17 Thread Christian Borntraeger
in the kernel and dont return to userspace, even if in ucontrol mode. Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com CC: sta...@vger.kernel.org --- arch/s390/kvm/kvm-s390.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

[PULL 1/2] KVM: s390: Removing untriggerable BUG_ONs

2014-03-17 Thread Christian Borntraeger
the vcpu creation code already checks against KVM_MAX_VCPUS. Signed-off-by: Dominik Dingel din...@linux.vnet.ibm.com Acked-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/interrupt.c | 2 -- arch/s390/kvm/kvm-s390.c | 2

[PULL 0/2] KVM: s390: last patches for next

2014-03-17 Thread Christian Borntraeger
exits - get rid of BUG_ONs in hot inner loops Christian Borntraeger (1): KVM: s390: Optimize ucontrol path Dominik Dingel (1): KVM: s390: Removing untriggerable BUG_ONs arch/s390/kvm/interrupt.c | 2 -- arch/s390/kvm

Re: [PATCH v2 1/5] KVM: eventfd: Fix lock order inversion.

2014-03-17 Thread Christian Borntraeger
in kvm_irqfd_assign(). Signed-off-by: Cornelia Huck cornelia.h...@de.ibm.com Do you still have the lockdep message somewhere? Looking at the patch and the description this makes sense. Even without irqfd for s390: Reviewed-by: Christian Borntraeger borntrae...@de.ibm.com Paolo, maybe this patch can go

Re: [PATCH v2 2/5] KVM: Add per-vm capability enablement.

2014-03-17 Thread Christian Borntraeger
-by: Cornelia Huck cornelia.h...@de.ibm.com Reviewed-by: Christian Borntraeger borntrae...@de.ibm.com --- Documentation/virtual/kvm/api.txt |6 -- arch/s390/kvm/kvm-s390.c | 24 include/uapi/linux/kvm.h |5 + 3 files changed, 33 insertions

Re: [Qemu-devel] [PATCH 1/6] s390x/virtio-ccw: Adapter interrupt support.

2014-03-04 Thread Christian Borntraeger
On 04/03/14 10:05, Cornelia Huck wrote: On Tue, 25 Feb 2014 18:25:15 +0100 Cornelia Huck cornelia.h...@de.ibm.com wrote: Handle the new CCW_CMD_SET_IND_ADAPTER command enabling adapter interrupts on guest request. When active, host-guest notifications will be handled via global_indicator -

[PULL 0/8] KVM: s390,virtio-ccw: Features, cleanups and fixes

2014-03-04 Thread Christian Borntraeger
for KVM: s390: - It contains the guest kernel part for adapter interrupt support for virtio-ccw, no irqfd yet - cleanups, getting rid of some interrupt data structure - ONEREG access to GBEA and PP - Fixes for virtio-ccw, sigp Christian

[PULL 2/8] KVM: s390: expose gbea register to userspace

2014-03-04 Thread Christian Borntraeger
For migration/reset we want to expose the guest breaking event address register to userspace. Lets use ONE_REG for that purpose. Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com Reviewed-by: Jason J. Herne jjhe...@linux.vnet.ibm.com --- arch/s390/include/uapi/asm/kvm.h | 1 + arch

[PULL 5/8] KVM: s390: get rid of local_int array

2014-03-04 Thread Christian Borntraeger
-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/kvm_host.h | 1 - arch/s390/kvm/interrupt.c| 6 +- arch/s390/kvm/kvm-s390.c | 5 +- arch/s390/kvm/sigp.c | 124 --- 4 files changed, 56 insertions(+), 80 deletions

[PULL 8/8] virtio-ccw: virtio-ccw adapter interrupt support.

2014-03-04 Thread Christian Borntraeger
-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/irq.h | 1 + arch/s390/kernel/irq.c| 1 + drivers/s390/kvm/virtio_ccw.c | 278 -- 3 files changed, 270 insertions(+), 10 deletions(-) diff --git a/arch/s390/include/asm/irq.h b

[PULL 7/8] s390/airq: add support for irq ranges

2014-03-04 Thread Christian Borntraeger
From: Martin Schwidefsky schwidef...@de.ibm.com Add airq_iv_alloc and airq_iv_free to allocate and free consecutive ranges of irqs from the interrupt vector. Signed-off-by: Martin Schwidefsky schwidef...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390

[PULL 1/8] KVM: s390: Provide access to program parameter

2014-03-04 Thread Christian Borntraeger
commit d208c79d63e06457eef077af770d23dc4cde4d43 (KVM: s390: Enable the LPP facility for guests) enabled the LPP instruction for guests. We should expose the program parameter as a pseudo register for migration/reset etc. Lets also reset this value on initial CPU reset. Signed-off-by: Christian

[PULL 3/8] KVM: s390: Simplify online vcpus counting for stsi

2014-03-04 Thread Christian Borntraeger
From: Jens Freimann jf...@linux.vnet.ibm.com We don't need to loop over all cpus to get the number of vcpus. Let's use the available counter online_vcpus instead. Signed-off-by: Jens Freimann jf...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm

[PULL 4/8] KVM: s390: Fixed CC of SIGP SET_PREFIX handler

2014-03-04 Thread Christian Borntraeger
rid of the floating interrupt lock here by using kvm_get_vcpu() to get the local_int struct of the destination CPU. Signed-off-by: Thomas Huth th...@linux.vnet.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm

[PULL 6/8] virtio_ccw: fix vcdev pointer handling issues

2014-03-04 Thread Christian Borntraeger
the ccw_device lock) prior to freeing the vcdev pointer memory removes a critical path. Signed-off-by: Heinz Graalfs graa...@linux.vnet.ibm.com Acked-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- drivers/s390/kvm/virtio_ccw.c | 35

Re: macvtap performance regression (bisected) between 3.13 and 3.14-rc1

2014-03-03 Thread Christian Borntraeger
On 01/03/14 20:27, Vlad Yasevich wrote: On 03/01/2014 06:15 AM, Christian Borntraeger wrote: On 28/02/14 23:14, Vlad Yasevich wrote: On 02/27/2014 03:52 PM, Christian Borntraeger wrote: Vlad, commit 6acf54f1cf0a6747bac9fea26f34cfc5a9029523 macvtap: Add support of packet capture

Re: macvtap performance regression (bisected) between 3.13 and 3.14-rc1

2014-03-03 Thread Christian Borntraeger
On 02/03/14 02:21, Vlad Yasevich wrote: On 03/01/2014 02:27 PM, Vlad Yasevich wrote: On 03/01/2014 06:15 AM, Christian Borntraeger wrote: On 28/02/14 23:14, Vlad Yasevich wrote: On 02/27/2014 03:52 PM, Christian Borntraeger wrote: Vlad, commit 6acf54f1cf0a6747bac9fea26f34cfc5a9029523

Re: [PATCH 2/7] KVM: s390: virtio-ccw adapter interrupt support.

2014-03-03 Thread Christian Borntraeger
On 25/02/14 18:24, Cornelia Huck wrote: Implement the new CCW_CMD_SET_IND_ADAPTER command and try to enable adapter interrupts for every device on the first startup. If the host does not support adapter interrupts, fall back to normal I/O interrupts. virtio-ccw adapter interrupts use the

Re: macvtap performance regression (bisected) between 3.13 and 3.14-rc1

2014-03-01 Thread Christian Borntraeger
On 28/02/14 23:14, Vlad Yasevich wrote: On 02/27/2014 03:52 PM, Christian Borntraeger wrote: Vlad, commit 6acf54f1cf0a6747bac9fea26f34cfc5a9029523 macvtap: Add support of packet capture on macvtap device. causes a performance regression for iperf traffic between two KVM guests on my

macvtap performance regression (bisected) between 3.13 and 3.14-rc1

2014-02-27 Thread Christian Borntraeger
Vlad, commit 6acf54f1cf0a6747bac9fea26f34cfc5a9029523 macvtap: Add support of packet capture on macvtap device. causes a performance regression for iperf traffic between two KVM guests on my s390 system. Both guests are connected via two macvtaps on the same OSA network card. Before that

Re: [PATCH 4/6] s390x: Add I/O adapter registration.

2014-02-26 Thread Christian Borntraeger
On 25/02/14 18:25, Cornelia Huck wrote: +int kvm_s390_io_adapter_map(uint32_t id, uint64_t map_addr, bool do_map) +{ +struct kvm_s390_io_adapter_req req = { +.id = id, +.type = do_map ? KVM_S390_IO_ADAPTER_MAP : KVM_S390_IO_ADAPTER_UNMAP, +.addr = map_addr, +

[PATCH 0/3] Improved yield performance

2014-02-26 Thread Christian Borntraeger
Paolo, here is the reworked yield heuristics series against kvm/queue with your suggested changes. Attached is a minimized testcase that reproduces the performance win (runtime 0:50 instead of 1:00). The constants and the setup seem a bit artificial but these seem to reproduce the problem on my

[PATCH 2/3] KVM: add kvm_arch_vcpu_runnable() test to kvm_vcpu_on_spin() loop

2014-02-26 Thread Christian Borntraeger
From: Michael Mueller m...@linux.vnet.ibm.com Use the arch specific function kvm_arch_vcpu_runnable() to add a further criterium to identify a suitable vcpu to yield to during undirected yield processing. Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com Reviewed-by: Christian Borntraeger

[PATCH 1/3] KVM: s390: implementation of kvm_arch_vcpu_runnable()

2014-02-26 Thread Christian Borntraeger
From: Michael Mueller m...@linux.vnet.ibm.com A vcpu is defined to be runnable if an interrupt is pending. Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com Reviewed-by: Christian Borntraeger borntrae...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390

[PATCH 3/3] KVM/s390: Set preempted flag during vcpu wakeup and interrupt delivery

2014-02-26 Thread Christian Borntraeger
Reviewed-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/interrupt.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/s390/kvm/interrupt.c b/arch/s390/kvm/interrupt.c index 1848080..fff070b 100644 --- a/arch/s390/kvm/interrupt.c +++ b/arch/s390/kvm/interrupt.c

[PATCHv2] kvm/irqchip: Speed up KVM_SET_GSI_ROUTING

2014-02-24 Thread Christian Borntraeger
having multiple CPUs. This is caused by the synchronize_rcu and the HZ=100 of s390. By changing the code to use a private srcu we can speed things up. This patch reduces the boot time till mounting root from 8 to 2 seconds on my s390 guest with 100 disks. Signed-off-by: Christian Borntraeger

Re: [PATCH/RFC 2/3] s390/kvm: Platform specific kvm_arch_vcpu_dont_yield

2014-02-14 Thread Christian Borntraeger
On 14/02/14 00:32, Paolo Bonzini wrote: Il 13/02/2014 23:54, Christian Borntraeger ha scritto: We had several variants but in the end we tried to come up with a patch that does not influence other architectures. Your proposal would certainly be fine for s390, but what impact does it have

Re: [PATCH/RFC 2/3] s390/kvm: Platform specific kvm_arch_vcpu_dont_yield

2014-02-13 Thread Christian Borntraeger
On 13/02/14 23:37, Paolo Bonzini wrote: Il 11/02/2014 12:45, Christian Borntraeger ha scritto: From: Michael Mueller m...@linux.vnet.ibm.com Commit s390/kvm: Use common waitqueue caused a performance regression on s390. It turned out that a yield candidate was missed by just a simple test

[PATCH/RFC 1/3] kvm: Introduction of kvm_arch_vcpu_dont_yield()

2014-02-11 Thread Christian Borntraeger
-off-by: Michael Mueller m...@linux.vnet.ibm.com Reviewed-by: Christian Borntraeger borntrae...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- include/linux/kvm_host.h | 9 + virt/kvm/Kconfig | 3 +++ virt/kvm/kvm_main.c | 2 +- 3 files changed, 13

[PATCH/RFC 3/3] s390/kvm: Set preempted flag during vcpu wakeup and interrupt delivery

2014-02-11 Thread Christian Borntraeger
and code analysis to solve this issue was provided by Mao Chuan Li and his team in Beijing. Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com Reviewed-by: Christian Borntraeger borntrae...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/interrupt.c | 3

[PATCH/RFC 2/3] s390/kvm: Platform specific kvm_arch_vcpu_dont_yield

2014-02-11 Thread Christian Borntraeger
-by: Christian Borntraeger borntrae...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/Kconfig| 1 + arch/s390/kvm/kvm-s390.c | 7 +++ 2 files changed, 8 insertions(+) diff --git a/arch/s390/kvm/Kconfig b/arch/s390/kvm/Kconfig index c8bacbc..e44adef

[PATCH/RFC 0/3] KVM: yield heuristic improvements

2014-02-11 Thread Christian Borntraeger
Paolo, Gleb, here are 3 patches that improve the s390 guest performance on contended systems. Basic idea is to also allow yielding to CPUs which still sleep but are runnable. The patch set should be no-ops for !s390. Michael Mueller (3): kvm: Introduction of kvm_arch_vcpu_dont_yield()

Re: [PULL 5/8] KVM: async_pf: Provide additional direct page notification

2014-01-31 Thread Christian Borntraeger
On 31/01/14 12:38, Paolo Bonzini wrote: Il 30/01/2014 13:53, Christian Borntraeger ha scritto: +static inline void kvm_async_page_present_async(struct kvm_vcpu *vcpu, +struct kvm_async_pf *work) +{ +#ifndef CONFIG_KVM_ASYNC_PF_SYNC +kvm_arch_async_page_present

[PATCH] KVM: async_pf: Add missing call for async page present

2014-01-31 Thread Christian Borntraeger
From: Dominik Dingel din...@linux.vnet.ibm.com Commit KVM: async_pf: Provide additional direct page notification missed the call from kvm_check_async_pf_completion to the new introduced function. Reported-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Dominik Dingel

[PATCH] Fixup for patch 5

2014-01-31 Thread Christian Borntraeger
This fixup fixes patch 5 and makes it equivalent to the code that went through testing. Looks like the change from patch 5 does not cause real problems. x86 will simply inject the completion via kvm_arch_async_page_present in kvm_check_async_pf_completion. s390 will inject twice (sync in execute

[PULL 5/8] KVM: async_pf: Provide additional direct page notification

2014-01-30 Thread Christian Borntraeger
-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/x86/kvm/mmu.c | 2 +- include/linux/kvm_host.h | 2 +- virt/kvm/Kconfig | 4 virt/kvm/async_pf.c | 20 ++-- 4 files changed, 24 insertions(+), 4 deletions(-) diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm

[PULL 4/8] KVM: s390: Add FAULT_FLAG_RETRY_NOWAIT for guest fault

2014-01-30 Thread Christian Borntraeger
...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/pgtable.h | 2 ++ arch/s390/include/asm/processor.h | 1 + arch/s390/kvm/kvm-s390.c | 23 +-- arch/s390/mm/fault.c | 26 ++ 4 files

[PULL 0/8] KVM: s390: floating interrupt controller and asyncpf

2014-01-30 Thread Christian Borntraeger
Paolo, Gleb, The following changes since commit c760f5e29d92adf5184589f1e616a4be146fb57c: Merge tag 'kvm-s390-20140117' of git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into kvm-queue (2014-01-23 11:38:13 +0100) are available in the git repository at:

[PULL 1/8] KVM: s390: add and extend interrupt information data structs

2014-01-30 Thread Christian Borntraeger
...@linux.vnet.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/kvm_host.h | 34 +- include/uapi/linux/kvm.h | 63 2 files changed

[PULL 6/8] KVM: async_pf: Allow to wait for outstanding work

2014-01-30 Thread Christian Borntraeger
From: Dominik Dingel din...@linux.vnet.ibm.com On s390 we are not able to cancel work. Instead we will flush the work and wait for completion. Signed-off-by: Dominik Dingel din...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- virt/kvm/async_pf.c | 5

[PULL 3/8] KVM: s390: limit floating irqs

2014-01-30 Thread Christian Borntraeger
adapter interrupts, as well as up to ASYNC_PF_PER_VCPU*KVM_MAX_VCPUS pfault done interrupts. There are also sclp and machine checks. This gives us (4*65536+8+64*64+1+1) = 266250 interrupts. Suggested-by: Christian Borntraeger borntrae...@de.ibm.com Signed-off-by: Jens Freimann jf

[PULL 8/8] KVM: async_pf: Exploit one reg interface for pfault

2014-01-30 Thread Christian Borntraeger
...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/uapi/asm/kvm.h | 3 +++ arch/s390/kvm/kvm-s390.c | 24 2 files changed, 27 insertions(+) diff --git a/arch/s390/include/uapi/asm/kvm.h b/arch/s390/include/uapi

[PULL 7/8] KVM: async_pf: Async page fault support on s390

2014-01-30 Thread Christian Borntraeger
by the guest to enable async page faults. The async page faults will use an already existing guest interface for this purpose, as described in CP Programming Services (SC24-6084). Signed-off-by: Dominik Dingel din...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com

[PULL 2/8] KVM: s390: add floating irq controller

2014-01-30 Thread Christian Borntraeger
-by: Jens Freimann jf...@linux.vnet.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- Documentation/virtual/kvm/devices/s390_flic.txt | 36 +++ arch/s390/include/asm/kvm_host.h| 1 + arch/s390/include/uapi/asm

[PULL 1/1] KVM: s390: Fix memory access error detection

2014-01-20 Thread Christian Borntraeger
into the guest. This leads to hang situations with the old virtio transport that checks for descriptor memory after guest memory. Instead of bailing out this code now goes wild... Lets re-add the check. Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/kvm-s390.c |4 1 file

[PULL 0/1] KVM: s390: urgent fix for kvm/next

2014-01-20 Thread Christian Borntraeger
Paolo, here is a fix for a regression that is in current kvm/next, which is targetted for 3.14. Please apply Christian Borntraeger (1): KVM: s390: Fix memory access error detection arch/s390/kvm/kvm-s390.c |4 1 file changed, 4 insertions(+) -- 1.7.9.5 The following changes since

Re: [PATCHv2/RFC] kvm/irqchip: Speed up KVM_SET_GSI_ROUTING

2014-01-17 Thread Christian Borntraeger
On 16/01/14 19:56, Michael S. Tsirkin wrote: On Thu, Jan 16, 2014 at 02:07:19PM +0100, Paolo Bonzini wrote: Il 16/01/2014 14:06, Christian Borntraeger ha scritto: Will you edit the patch description or shall I resend the patch? I can edit the commit message. Paolo I think we really need

[PULL 1/3] KVM: s390: enable Transactional Execution

2014-01-17 Thread Christian Borntraeger
occurred and the ITDB has a valid format. Signed-off-by: Michael Mueller m...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/kvm_host.h | 15 ++- arch/s390/kvm/intercept.c| 11 +++ arch/s390/kvm/kvm-s390.c

[PULL 0/3] KVM: s390: patches for kvm-next

2014-01-17 Thread Christian Borntraeger
Paolo, the following changes since commit 26a865f4aa8e66a6d94958de7656f7f1b03c6c56: KVM: VMX: fix use after free of vmx-loaded_vmcs (2014-01-08 19:14:08 -0200) are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux.git tags/kvm-s390-20140117

[PULL 3/3] KVM: s390: virtio-ccw: Handle command rejects.

2014-01-17 Thread Christian Borntraeger
...@linux.vnet.ibm.com Signed-off-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- drivers/s390/kvm/virtio_ccw.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/drivers/s390/kvm/virtio_ccw.c b/drivers/s390/kvm

[PULL 2/3] KVM: s390: Enable the LPP facility for guests

2014-01-17 Thread Christian Borntraeger
-by: Michael Mueller m...@linux.vnet.ibm.com Acked-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/kvm-s390.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c

Re: [PATCHv3] kvm/irqchip: Speed up KVM_SET_GSI_ROUTING

2014-01-17 Thread Christian Borntraeger
by Michael S. Tsirkin Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- virt/kvm/irqchip.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/virt/kvm/irqchip.c b/virt/kvm/irqchip.c index 20dc9e4..dbcfde7 100644 --- a/virt/kvm/irqchip.c +++ b/virt/kvm/irqchip.c

[PATCH] kvm/irqchip: Speed up KVM_SET_GSI_ROUTING

2014-01-16 Thread Christian Borntraeger
the boot time till mounting root from 8 to 2 seconds on my s390 guest with 100 disks. Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- include/linux/kvm_host.h | 1 + virt/kvm/irqchip.c | 5 ++--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/include/linux

[PATCHv2/RFC] kvm/irqchip: Speed up KVM_SET_GSI_ROUTING

2014-01-16 Thread Christian Borntraeger
for the unconverted use of hlist_for_each_entry_rcu, hlist_add_head_rcu, hlist_del_init_rcu is necessary, though. They look fine to me since they are protected by outer functions. In addition, we should also discuss if a global srcu (for all guests) is fine. Signed-off-by: Christian Borntraeger

Re: [PATCHv2/RFC] kvm/irqchip: Speed up KVM_SET_GSI_ROUTING

2014-01-16 Thread Christian Borntraeger
On 16/01/14 13:59, Paolo Bonzini wrote: Il 16/01/2014 13:44, Christian Borntraeger ha scritto: I converted most of the rcu routines to srcu. Review for the unconverted use of hlist_for_each_entry_rcu, hlist_add_head_rcu, hlist_del_init_rcu is necessary, though. They look fine to me since

[PATCHv3] kvm/irqchip: Speed up KVM_SET_GSI_ROUTING

2014-01-16 Thread Christian Borntraeger
On 16/01/14 19:55, Michael S. Tsirkin wrote: On Thu, Jan 16, 2014 at 01:44:20PM +0100, Christian Borntraeger wrote: [...] I converted most of the rcu routines to srcu. Review for the unconverted [...] That's nice but did you try to measure the overhead on some interrupt-intensive workloads

RFC: KVM _CREATE_DEVICE considered harmful?

2013-10-16 Thread Christian Borntraeger
Folks, from time to time I update valgrind or qemu to work reasonably well with KVM. Now, newer KVMs have the ability to create subdevices of a KVM guest (e.g. an in kernel kvm interrupt controller) with the following ioctl: #define KVM_CREATE_DEVICE _IOWR(KVMIO, 0xe0, struct

Re: RFC: KVM _CREATE_DEVICE considered harmful?

2013-10-16 Thread Christian Borntraeger
dropping valgrind devel since its subscribers only... On 16/10/13 15:06, Paolo Bonzini wrote: Il 16/10/2013 14:59, Christian Borntraeger ha scritto: Now, newer KVMs have the ability to create subdevices of a KVM guest (e.g. an in kernel kvm interrupt controller) with the following ioctl

Re: RFC: KVM _CREATE_DEVICE considered harmful?

2013-10-16 Thread Christian Borntraeger
On 16/10/13 17:44, Gleb Natapov wrote: On Wed, Oct 16, 2013 at 02:59:47PM +0200, Christian Borntraeger wrote: Folks, from time to time I update valgrind or qemu to work reasonably well with KVM. Now, newer KVMs have the ability to create subdevices of a KVM guest (e.g. an in kernel kvm

Re: [Patchv5 2/7] KVM: s390: add floating irq controller

2013-10-14 Thread Christian Borntraeger
On 13/10/13 10:39, Gleb Natapov wrote: On Tue, Oct 08, 2013 at 04:54:55PM +0200, Christian Borntraeger wrote: From: Jens Freimann jf...@linux.vnet.ibm.com This patch adds a floating irq controller as a kvm_device. It will be necessary for migration of floating interrupts as well

[Patchv5 1/7] KVM: s390: add and extend interrupt information data structs

2013-10-08 Thread Christian Borntraeger
...@linux.vnet.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/kvm_host.h | 34 +- include/uapi/linux/kvm.h | 63 2 files changed

[Patchv5 6/7] KVM: async_pf: Async page fault support on s390

2013-10-08 Thread Christian Borntraeger
-6084). Signed-off-by: Dominik Dingel din...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/kvm_host.h | 22 +++ arch/s390/include/uapi/asm/kvm.h | 9 +++-- arch/s390/kvm/Kconfig| 2 + arch/s390/kvm/Makefile

[Patchv5 7/7] KVM: async_pf: Exploit one reg interface for pfault

2013-10-08 Thread Christian Borntraeger
...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/uapi/asm/kvm.h | 3 +++ arch/s390/kvm/kvm-s390.c | 24 2 files changed, 27 insertions(+) diff --git a/arch/s390/include/uapi/asm/kvm.h b/arch/s390/include/uapi

[PATCHv5 0/7] aync page fault support for s390 (plus flic)

2013-10-08 Thread Christian Borntraeger
Gleb, Paolo, here is a set of patches containing the floating interrupt controller and the async page fault patches on top of them. (It took a bit longer than expected) Several changes since v4 of the async patches mostly to make life migration possible: - Please have a look at patch 5. This

[Patchv5 4/7] KVM: async_pf: Provide additional direct page notification

2013-10-08 Thread Christian Borntraeger
-by: Dominik Dingel din...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/x86/kvm/mmu.c | 2 +- include/linux/kvm_host.h | 2 +- virt/kvm/Kconfig | 4 virt/kvm/async_pf.c | 22 +++--- 4 files changed, 25 insertions(+), 5

[Patchv5 2/7] KVM: s390: add floating irq controller

2013-10-08 Thread Christian Borntraeger
-by: Jens Freimann jf...@linux.vnet.ibm.com Reviewed-by: Cornelia Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- Documentation/virtual/kvm/devices/s390_flic.txt | 36 +++ arch/s390/include/asm/kvm_host.h| 1 + arch/s390/include/uapi/asm

[Patchv5 5/7] KVM: async_pf: Allow to wait for outstanding work

2013-10-08 Thread Christian Borntraeger
From: Dominik Dingel din...@linux.vnet.ibm.com kvm_clear_async_pf_completion get an additional flag to either cancel outstanding work or wait for oustanding work to be finished, x86 currentlx cancels all work. Signed-off-by: Dominik Dingel din...@linux.vnet.ibm.com Signed-off-by: Christian

[Patchv5 3/7] KVM: s390: Add FAULT_FLAG_RETRY_NOWAIT for guest fault

2013-10-08 Thread Christian Borntraeger
Dingel din...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/pgtable.h | 2 ++ arch/s390/include/asm/processor.h | 1 + arch/s390/kvm/kvm-s390.c | 28 +++- arch/s390/mm/fault.c | 26

Re: [PATCH v2 0/2] KVM: s390: add floating irq controller

2013-10-07 Thread Christian Borntraeger
On 05/10/13 01:54, Alexander Graf wrote: On 06.09.2013, at 15:30, Christian Borntraeger wrote: On 06/09/13 14:19, Jens Freimann wrote: This series adds a kvm_device that acts as a irq controller for floating interrupts. As a first step it implements functionality to retrieve and inject

[PATCH 1/8] KVM: s390: Remove dead rerun vcpu code

2013-09-12 Thread Christian Borntraeger
by this patch. Signed-off-by: Thomas Huth th...@linux.vnet.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/include/asm/kvm_host.h | 1 - arch/s390/kvm/intercept.c| 6 -- arch/s390/kvm/kvm-s390.c | 4 arch/s390/kvm/kvm-s390.h | 3 +-- 4

[PATCH 3/8] KVM: s390: Push run loop into __vcpu_run

2013-09-12 Thread Christian Borntraeger
Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/kvm-s390.c | 49 1 file changed, 25 insertions(+), 24 deletions(-) diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c index 69c7592..8eec7ab 100644

[PATCH 5/8] KVM: s390: Allow NULL parameter for kvm_s390_get_regs_rre

2013-09-12 Thread Christian Borntraeger
Huck cornelia.h...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/kvm-s390.h | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/arch/s390/kvm/kvm-s390.h b/arch/s390/kvm/kvm-s390.h index a307a85..b44912a 100644 --- a/arch/s390/kvm/kvm

[PATCH 0/8] KVM: s390: fixes and cleanup

2013-09-12 Thread Christian Borntraeger
Paolo, Gleb, here is a bunch of patch for kvm on s390. The first 4 patches restructure the code to protect most of vcpu_run with the kvm-srcu lock. The old code was structured in way that adding the lock was more complicated than necessary, therefore, the rework. The last 4 patches deal with

[PATCH 7/8] KVM: s390: Implement TEST BLOCK

2013-09-12 Thread Christian Borntraeger
...@de.ibm.com Signed-off-by: Christian Borntraeger borntrae...@de.ibm.com --- arch/s390/kvm/priv.c | 28 1 file changed, 28 insertions(+) diff --git a/arch/s390/kvm/priv.c b/arch/s390/kvm/priv.c index 59200ee..6f95994 100644 --- a/arch/s390/kvm/priv.c +++ b/arch/s390/kvm

<    3   4   5   6   7   8   9   10   11   >