Re: [PATCH v6 01/15] ARM: Add page table and page defines needed by KVM

2013-01-24 Thread Christoffer Dall
On Thu, Jan 24, 2013 at 6:39 AM, Catalin Marinas catalin.mari...@arm.com wrote: Hi Christoffer, On Wed, Jan 16, 2013 at 05:57:26PM +, Christoffer Dall wrote: diff --git a/arch/arm/include/asm/pgtable-3level.h b/arch/arm/include/asm/pgtable-3level.h index a3f3792..6ef8afd 100644

Re: [PATCH v6 02/15] ARM: Section based HYP idmap

2013-01-24 Thread Christoffer Dall
On Thu, Jan 24, 2013 at 9:32 AM, Catalin Marinas catalin.mari...@arm.com wrote: On Wed, Jan 16, 2013 at 05:57:34PM +, Christoffer Dall wrote: --- a/arch/arm/mm/idmap.c +++ b/arch/arm/mm/idmap.c @@ -1,4 +1,6 @@ +#include linux/module.h Minor thing - do you need to include linux/module.h

Re: [PATCH v6 00/15] KVM/ARM Implementation

2013-01-24 Thread Christoffer Dall
On Thu, Jan 24, 2013 at 11:26 AM, Catalin Marinas catalin.mari...@arm.com wrote: Hi Christoffer, On Wed, Jan 16, 2013 at 05:57:19PM +, Christoffer Dall wrote: The following series implements KVM support for ARM processors, specifically on the Cortex A-15 platform. I went through the KVM

Re: [PATCH v6 04/15] KVM: ARM: Hypervisor initialization

2013-01-24 Thread Christoffer Dall
On Thu, Jan 24, 2013 at 10:45 AM, Catalin Marinas catalin.mari...@arm.com wrote: On Wed, Jan 16, 2013 at 05:57:48PM +, Christoffer Dall wrote: --- a/arch/arm/include/asm/pgtable-3level-hwdef.h +++ b/arch/arm/include/asm/pgtable-3level-hwdef.h @@ -32,6 +32,9 @@ #define PMD_TYPE_SECT

Re: [PATCH v6 02/15] ARM: Section based HYP idmap

2013-01-24 Thread Christoffer Dall
On Thu, Jan 24, 2013 at 12:05 PM, Catalin Marinas catalin.mari...@arm.com wrote: On Thu, Jan 24, 2013 at 04:36:09PM +, Christoffer Dall wrote: On Thu, Jan 24, 2013 at 9:32 AM, Catalin Marinas catalin.mari...@arm.com wrote: On Wed, Jan 16, 2013 at 05:57:34PM +, Christoffer Dall wrote

Re: [PATCH v6 01/15] ARM: Add page table and page defines needed by KVM

2013-01-24 Thread Christoffer Dall
On Thu, Jan 24, 2013 at 12:02 PM, Catalin Marinas catalin.mari...@arm.com wrote: On Thu, Jan 24, 2013 at 04:05:33PM +, Christoffer Dall wrote: On Thu, Jan 24, 2013 at 6:39 AM, Catalin Marinas catalin.mari...@arm.com wrote: On Wed, Jan 16, 2013 at 05:57:26PM +, Christoffer Dall wrote

Re: [PATCH v6 01/15] ARM: Add page table and page defines needed by KVM

2013-01-24 Thread Christoffer Dall
On Thu, Jan 24, 2013 at 12:13 PM, Catalin Marinas catalin.mari...@arm.com wrote: On Thu, Jan 24, 2013 at 05:04:32PM +, Christoffer Dall wrote: On Thu, Jan 24, 2013 at 12:02 PM, Catalin Marinas catalin.mari...@arm.com wrote: On Thu, Jan 24, 2013 at 04:05:33PM +, Christoffer Dall wrote

Re: randconfig errors

2013-02-15 Thread Christoffer Dall
On Fri, Feb 15, 2013 at 2:22 PM, Marc Zyngier marc.zyng...@arm.com wrote: On 15/02/13 19:16, Christoffer Dall wrote: On Fri, Feb 15, 2013 at 1:47 PM, Marc Zyngier marc.zyng...@arm.com wrote: On Fri, 15 Feb 2013 19:22:37 +0100, Marc Zyngier marc.zyng...@arm.com wrote: On Fri, 15 Feb 2013 11:25

Re: [RFC PATCH 1/6] kvm: add device control API

2013-02-18 Thread Christoffer Dall
On Mon, Feb 18, 2013 at 3:01 PM, Scott Wood scottw...@freescale.com wrote: On 02/18/2013 06:21:59 AM, Gleb Natapov wrote: Copying Christoffer since ARM has in kernel irq chip too. On Wed, Feb 13, 2013 at 11:49:15PM -0600, Scott Wood wrote: Currently, devices that are emulated inside KVM are

Re: [RFC PATCH 1/6] kvm: add device control API

2013-02-18 Thread Christoffer Dall
On Wed, Feb 13, 2013 at 9:49 PM, Scott Wood scottw...@freescale.com wrote: Currently, devices that are emulated inside KVM are configured in a hardcoded manner based on an assumption that any given architecture only has one way to do it. If there's any need to access device state, it is done

Re: [RFC PATCH 1/6] kvm: add device control API

2013-02-18 Thread Christoffer Dall
On Mon, Feb 18, 2013 at 4:53 PM, Scott Wood scottw...@freescale.com wrote: On 02/18/2013 06:44:20 PM, Christoffer Dall wrote: On Wed, Feb 13, 2013 at 9:49 PM, Scott Wood scottw...@freescale.com wrote: index 0350e0d..dbaf012 100644 --- a/include/linux/kvm_host.h +++ b/include/linux

Re: [RFC PATCH 1/6] kvm: add device control API

2013-02-19 Thread Christoffer Dall
On Tue, Feb 19, 2013 at 4:24 AM, Gleb Natapov g...@redhat.com wrote: On Mon, Feb 18, 2013 at 05:01:40PM -0600, Scott Wood wrote: On 02/18/2013 06:21:59 AM, Gleb Natapov wrote: Copying Christoffer since ARM has in kernel irq chip too. On Wed, Feb 13, 2013 at 11:49:15PM -0600, Scott Wood

Re: [RFC PATCH 1/6] kvm: add device control API

2013-02-19 Thread Christoffer Dall
On Tue, Feb 19, 2013 at 12:16 PM, Scott Wood scottw...@freescale.com wrote: On 02/18/2013 11:50:44 PM, Christoffer Dall wrote: On Mon, Feb 18, 2013 at 4:53 PM, Scott Wood scottw...@freescale.com wrote: On 02/18/2013 06:44:20 PM, Christoffer Dall wrote: On Wed, Feb 13, 2013 at 9:49 PM

Re: [PATCH v7 00/11] QEMU: Support KVM on ARM

2013-03-06 Thread Christoffer Dall
On Tue, Feb 26, 2013 at 05:40:10PM +, Peter Maydell wrote: KVM ARM support has just hit Linus' kernel tree, so we can finally commit this series to QEMU. Since all the patches got reviewed last time round this should be ready to commit. I plan to commit this via arm-devs.next. NB: the

Re: [kvmarm] [PATCH 00/29] ARM: KVM: pre-arm64 KVM/arm rework

2013-03-06 Thread Christoffer Dall
On Tue, Mar 05, 2013 at 02:42:54AM +, Marc Zyngier wrote: This patch series is reworking KVM/arm in order to prepare the code to be shared with the upcoming KVM/arm64. Nothing major here, just a lot of accessors, small cleanups and fixes to make the code useable on arm64. This code

[GIT PULL v2] KVM/ARM Fixes for 3.9-rc1

2013-03-06 Thread Christoffer Dall
to fetch changes up to f42798c6898bf1e536673e798d263e492355162f: ARM: KVM: Fix length of mmio access (2013-03-06 16:01:51 -0800) Christoffer Dall (1): KVM: ARM: Reintroduce trace_kvm_hvc Jonghwan Choi (1): KVM: ARM: Fix

Re: [PATCH] ARM: KVM: add support for minimal host vs guest profiling

2013-03-06 Thread Christoffer Dall
On Tue, Mar 05, 2013 at 03:18:00AM +, Marc Zyngier wrote: In order to be able to correctly profile what is happening on the host, we need to be able to identify when we're running on the guest, and log these events differently. Perf offers a simple way to register callbacks into KVM.

Re: [kvmarm] [GIT PULL v2] KVM/ARM Fixes for 3.9-rc1

2013-03-06 Thread Christoffer Dall
On Wed, Mar 6, 2013 at 7:54 PM, Marc Zyngier marc.zyng...@arm.com wrote: On Wed, 6 Mar 2013 16:31:48 -0800, Christoffer Dall cd...@cs.columbia.edu wrote: Hi Christoffer, Please pull these KVM/ARM fixes mostly centered around preparation for Marc's ARMv8 KVM work. Can we please hold

Re: [kvmarm] [GIT PULL v2] KVM/ARM Fixes for 3.9-rc1

2013-03-07 Thread Christoffer Dall
On Thu, Mar 7, 2013 at 10:40 AM, Gleb Natapov g...@redhat.com wrote: On Thu, Mar 07, 2013 at 07:57:23AM +0100, Marc Zyngier wrote: On Wed, 6 Mar 2013 20:40:00 -0800, Christoffer Dall cd...@cs.columbia.edu wrote: On Wed, Mar 6, 2013 at 7:54 PM, Marc Zyngier marc.zyng...@arm.com wrote

Re: [kvmarm] [GIT PULL v2] KVM/ARM Fixes for 3.9-rc1

2013-03-07 Thread Christoffer Dall
On Thu, Mar 7, 2013 at 11:09 AM, Marcelo Tosatti mtosa...@redhat.com wrote: On Thu, Mar 07, 2013 at 07:57:23AM +0100, Marc Zyngier wrote: On Wed, 6 Mar 2013 20:40:00 -0800, Christoffer Dall cd...@cs.columbia.edu wrote: On Wed, Mar 6, 2013 at 7:54 PM, Marc Zyngier marc.zyng...@arm.com wrote

Re: [kvmarm] [GIT PULL v2] KVM/ARM Fixes for 3.9-rc1

2013-03-08 Thread Christoffer Dall
On Thu, Mar 7, 2013 at 7:12 PM, Marc Zyngier marc.zyng...@arm.com wrote: On Thu, 7 Mar 2013 16:09:00 -0300, Marcelo Tosatti mtosa...@redhat.com wrote: On Thu, Mar 07, 2013 at 07:57:23AM +0100, Marc Zyngier wrote: On Wed, 6 Mar 2013 20:40:00 -0800, Christoffer Dall cd...@cs.columbia.edu wrote

Re: [kvmarm] [GIT PULL v2] KVM/ARM Fixes for 3.9-rc1

2013-03-11 Thread Christoffer Dall
On Mon, Mar 11, 2013 at 3:38 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 08/03/13 19:26, Christoffer Dall wrote: On Thu, Mar 7, 2013 at 7:12 PM, Marc Zyngier marc.zyng...@arm.com wrote: On Thu, 7 Mar 2013 16:09:00 -0300, Marcelo Tosatti mtosa...@redhat.com wrote: On Thu, Mar 07, 2013

Re: [kvmarm] [PATCH 3/3] ARM: EXYNOS5250: Register architected timers

2013-03-13 Thread Christoffer Dall
On Wed, Mar 13, 2013 at 5:59 PM, Alexander Graf ag...@suse.de wrote: When running on an exynos 5250 SoC, we don't initialize the architected timers. The chip however supports architected timers. When we don't initialize them, KVM will try to access them and run into NULL pointer dereferences

Another question

2013-03-26 Thread Christoffer Dall
Hi guys, I have an x86 question that I really hope you can help with: Running the kvm-unit-tests on x86, I see a quite large difference between I/O from the kernel, and I/O user (around 6,000 cycles) on two separate platforms. This is probably expected, but what is the explanation? If I

Re: [PATCH 1/7] ARM: KVM: simplify HYP mapping population

2013-04-03 Thread Christoffer Dall
On Tue, Apr 02, 2013 at 02:25:09PM +0100, Marc Zyngier wrote: The way we populate HYP mappings is a bit convoluted, to say the least. Passing a pointer around to keep track of the current PFN is quite odd, and we end-up having two different PTE accessors for no good reason. Simplify the

Re: [PATCH 2/7] ARM: KVM: fix HYP mapping limitations around zero

2013-04-03 Thread Christoffer Dall
On Tue, Apr 02, 2013 at 02:25:10PM +0100, Marc Zyngier wrote: The current code for creating HYP mapping doesn't like to wrap around zero, which prevents from mapping anything into the last page of the virtual address space. It doesn't take much effort to remove this limitation, making the

Re: [PATCH 3/7] ARM: KVM: move to a KVM provided HYP idmap

2013-04-03 Thread Christoffer Dall
On Tue, Apr 02, 2013 at 02:25:11PM +0100, Marc Zyngier wrote: After the HYP page table rework, it is pretty easy to let the KVM code provide its own idmap, rather than expecting the kernel to provide it. It takes actually less code to do so. Signed-off-by: Marc Zyngier marc.zyng...@arm.com

Re: [PATCH 4/7] ARM: KVM: enforce page alignment for identity mapped code

2013-04-03 Thread Christoffer Dall
On Wed, Apr 03, 2013 at 11:00:39AM +0100, Marc Zyngier wrote: On 03/04/13 10:50, Will Deacon wrote: On Tue, Apr 02, 2013 at 02:25:12PM +0100, Marc Zyngier wrote: We're about to move to a init procedure where we rely on the fact that the init code fits in a single page. Make sure we align

Re: [PATCH 5/7] ARM: KVM: parametrize HYP page table freeing

2013-04-03 Thread Christoffer Dall
(kvm_hyp_pgd_mutex); } @@ -741,7 +745,7 @@ int kvm_mmu_init(void) return 0; out: - kfree(hyp_pgd); + free_hyp_pgds(); return err; } -- 1.8.1.4 Acked-by: Christoffer Dall cd...@cs.columbia.edu -- To unsubscribe from this list: send the line unsubscribe

Re: [PATCH 6/7] ARM: KVM: switch to a dual-step HYP init code

2013-04-03 Thread Christoffer Dall
On Tue, Apr 02, 2013 at 02:25:14PM +0100, Marc Zyngier wrote: Our HYP init code suffers from two major design issues: - it cannot support CPU hotplug, as we tear down the idmap very early - it cannot perform a TLB invalidation when switching from init to runtime mappings, as pages are

Re: [PATCH 6/7] ARM: KVM: switch to a dual-step HYP init code

2013-04-03 Thread Christoffer Dall
On Wed, Apr 03, 2013 at 11:38:30AM +0100, Marc Zyngier wrote: On 03/04/13 11:07, Will Deacon wrote: On Tue, Apr 02, 2013 at 02:25:14PM +0100, Marc Zyngier wrote: Our HYP init code suffers from two major design issues: - it cannot support CPU hotplug, as we tear down the idmap very early -

Re: [PATCH 7/7] ARM: KVM: perform HYP initilization for hotplugged CPUs

2013-04-03 Thread Christoffer Dall
-by: Christoffer Dall cd...@cs.columbia.edu -- 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 0/7] ARM: KVM: Revamping the HYP init code for fun and profit

2013-04-03 Thread Christoffer Dall
On Tue, Apr 02, 2013 at 02:25:08PM +0100, Marc Zyngier wrote: Over the past few weeks, I've gradually realized how broken our HYP idmap code is. Badly broken. The main problem is about supporting CPU hotplug. Imagine a CPU being initialized normally, running VMs, and then being powered down.

Re: [PATCH 4/7] ARM: KVM: enforce page alignment for identity mapped code

2013-04-04 Thread Christoffer Dall
On Thu, Apr 4, 2013 at 3:47 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 04/04/13 00:15, Christoffer Dall wrote: On Wed, Apr 03, 2013 at 11:00:39AM +0100, Marc Zyngier wrote: On 03/04/13 10:50, Will Deacon wrote: On Tue, Apr 02, 2013 at 02:25:12PM +0100, Marc Zyngier wrote: We're about

Re: [PATCH RFC] kvm: add PV MMIO EVENTFD

2013-04-04 Thread Christoffer Dall
[...] to give us some idea how much performance we would gain from each approach? Thoughput should be completely unaffected anyway, since virtio just coalesces kicks internally. Latency is dominated by the scheduling latency. This means virtio-net is not the best benchmark. So

Re: [PATCH 5/7] kvm/arm: Fix missing include build error

2013-04-04 Thread Christoffer Dall
On Thu, Apr 4, 2013 at 4:33 PM, Geoff Levand ge...@infradead.org wrote: Include linux/cpu.h in kvm/arm.c. Fixes build errors like these with ARCH=arm64: arch/arm/kvm/arm.c: error: ‘CPU_STARTING_FROZEN’ undeclared Signed-off-by: Geoff Levand ge...@infradead.org --- arch/arm/kvm/arm.c |

Re: [PATCH 0/7] KVM minor fixups

2013-04-04 Thread Christoffer Dall
On Thu, Apr 4, 2013 at 4:33 PM, Geoff Levand ge...@infradead.org wrote: Hi Marcelo, These are a few fixups I found when running sparse and building Marc's 64 bit ARM tree. Please consider for 3.10. running sparse - what does this mean? -Christoffer -- To unsubscribe from this list: send the

Re: [PATCH 6/7] kvm/arm: Make force_vm_exit static

2013-04-04 Thread Christoffer Dall
On Thu, Apr 4, 2013 at 4:33 PM, Geoff Levand ge...@infradead.org wrote: The routine force_vm_exit() is not referenced outside kvm/arm.c, so make it have static linkage. Signed-off-by: Geoff Levand ge...@infradead.org --- arch/arm/include/asm/kvm_host.h |1 - arch/arm/kvm/arm.c

Re: [PATCH 7/7] kvm/arm: Remove unused kvm_arch_set_memory_region

2013-04-04 Thread Christoffer Dall
On Thu, Apr 4, 2013 at 4:33 PM, Geoff Levand ge...@infradead.org wrote: Remove the unused and empty routine kvm_arch_set_memory_region(). Signed-off-by: Geoff Levand ge...@infradead.org --- arch/arm/kvm/arm.c |8 1 file changed, 8 deletions(-) diff --git a/arch/arm/kvm/arm.c

Re: [PATCH 0/7] KVM minor fixups

2013-04-04 Thread Christoffer Dall
On Thu, Apr 4, 2013 at 4:57 PM, Geoff Levand ge...@infradead.org wrote: Hi Christoffer, On Thu, 2013-04-04 at 16:53 -0700, Christoffer Dall wrote: On Thu, Apr 4, 2013 at 4:33 PM, Geoff Levand ge...@infradead.org wrote: Hi Marcelo, These are a few fixups I found when running sparse

Re: [PATCH 5/7] kvm/arm: Fix missing include build error

2013-04-04 Thread Christoffer Dall
On Thu, Apr 4, 2013 at 5:04 PM, Geoff Levand ge...@infradead.org wrote: Hi Christoffer, On Thu, 2013-04-04 at 16:51 -0700, Christoffer Dall wrote: On Thu, Apr 4, 2013 at 4:33 PM, Geoff Levand ge...@infradead.org wrote: Include linux/cpu.h in kvm/arm.c. Fixes build errors like

Re: [PATCH RFC] kvm: add PV MMIO EVENTFD

2013-04-07 Thread Christoffer Dall
On Sun, Apr 7, 2013 at 12:41 AM, Michael S. Tsirkin m...@redhat.com wrote: On Thu, Apr 04, 2013 at 04:32:01PM -0700, Christoffer Dall wrote: [...] to give us some idea how much performance we would gain from each approach? Thoughput should be completely unaffected anyway, since

[GIT PULL] KVM/ARM Minor fixes for 3.9

2013-04-15 Thread Christoffer Dall
Hi Marcelo and Gleb, The following changes since commit 41ef2d5678d83af030125550329b6ae8b74618fa: Linux 3.9-rc7 (2013-04-14 17:45:16 -0700) are available in the git repository at: git://github.com/columbia/linux-kvm-arm.git kvm-arm-fixes-for-3.9 for you to fetch changes up to

Re: [PATCH] KVM: ARM: Fix kvm_vm_ioctl_irq_line

2013-04-16 Thread Christoffer Dall
= irq_level-irq; unsigned int irq_type, vcpu_idx, irq_num; -- 1.6.0.2 Acked-by: Christoffer Dall cd...@cs.columbia.edu -- 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

Re: [GIT PULL] KVM/ARM Minor fixes for 3.9

2013-04-16 Thread Christoffer Dall
On Tue, Apr 16, 2013 at 2:03 PM, Marcelo Tosatti mtosa...@redhat.com wrote: On Mon, Apr 15, 2013 at 01:52:15AM -0700, Christoffer Dall wrote: Hi Marcelo and Gleb, The following changes since commit 41ef2d5678d83af030125550329b6ae8b74618fa: Linux 3.9-rc7 (2013-04-14 17:45:16 -0700

[GIT PULL v2] KVM/ARM Minor fixes for 3.9

2013-04-16 Thread Christoffer Dall
The following changes since commit 31880c37c11e28cb81c70757e38392b42e695dc6: Linux 3.9-rc6 (2013-04-07 20:49:54 -0700) are available in the git repository at: git://github.com/columbia/linux-kvm-arm.git kvm-arm-fixes-3.9 for you to fetch changes up to

Re: [GIT PULL v2] KVM/ARM Minor fixes for 3.9

2013-04-17 Thread Christoffer Dall
On Wed, Apr 17, 2013 at 3:45 AM, Gleb Natapov g...@redhat.com wrote: Marcelo has sent pull request yesterday and Linus pulled it already. Sorry if I was not clear. Generally specking we should not wait so late into the release to send fixes to Linus, exceptions happen of course. I know, the

Re: [GIT PULL v2] KVM/ARM Minor fixes for 3.9

2013-04-17 Thread Christoffer Dall
On Wed, Apr 17, 2013 at 4:08 AM, Alexander Graf ag...@suse.de wrote: On 17.04.2013, at 13:05, Christoffer Dall wrote: On Wed, Apr 17, 2013 at 3:45 AM, Gleb Natapov g...@redhat.com wrote: Marcelo has sent pull request yesterday and Linus pulled it already. Sorry if I was not clear. Generally

[PATCH] ARM: KVM: fix unbalanced get_cpu() in access_dcsw

2013-04-17 Thread Christoffer Dall
-off-by: Marc Zyngier marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/kvm/coproc.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/kvm/coproc.c b/arch/arm/kvm/coproc.c index 4ea9a98..7bed755 100644 --- a/arch/arm/kvm

KVM/ARM in next

2013-04-20 Thread Christoffer Dall
Hi Stephen, I'm maintaining the KVM/ARM implementation, which was merged during the 3.9 merge window. I'd like for you to pull changes from my kvm-arm-next branch at git://github.com/columbia/linux-kvm-arm.git into linux-next. The merge procedure for this tree is typically through the kvm tree,

[PATCH] KVM: ARM: Fix API documentation for ONE_REG encoding

2013-04-22 Thread Christoffer Dall
Unless I'm mistaken, the size field was encoded 4 bits off and a wrong value was used for 64-bit FP registers. Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- Documentation/virtual/kvm/api.txt | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git

Re: [PATCH v3 03/32] arm64: KVM: HYP mode idmap support

2013-04-23 Thread Christoffer Dall
On Mon, Apr 8, 2013 at 9:17 AM, Marc Zyngier marc.zyng...@arm.com wrote: Add the necessary infrastructure for identity-mapped HYP page tables. Idmap-ed code must be in the .hyp.idmap.text linker section. The rest of the HYP ends up in .hyp.text. Signed-off-by: Marc Zyngier

Re: [PATCH v3 07/32] arm64: KVM: fault injection into a guest

2013-04-23 Thread Christoffer Dall
: Christoffer Dall c.d...@virtualopensystems.com + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + * + * This program is distributed in the hope

Re: [PATCH v3 08/32] arm64: KVM: architecture specific MMU backend

2013-04-23 Thread Christoffer Dall
On Mon, Apr 08, 2013 at 05:17:10PM +0100, Marc Zyngier wrote: Define the arm64 specific MMU backend: - HYP/kernel VA offset - S2 4/64kB definitions - S2 page table populating and flushing - icache cleaning Reviewed-by: Christopher Covington c...@codeaurora.org Signed-off-by: Marc Zyngier

Re: [PATCH v3 11/32] arm64: KVM: CPU specific system registers handling

2013-04-23 Thread Christoffer Dall
/coproc_a15.c: + * Copyright (C) 2012 - Virtual Open Systems and Columbia University + * Authors: Rusty Russell ru...@rustcorp.au + * Christoffer Dall c.d...@virtualopensystems.com + * + * This program is free software; you can redistribute it and/or modify + * it under the terms

Re: [PATCH v3 15/32] arm64: KVM: guest one-reg interface

2013-04-23 Thread Christoffer Dall
Ltd + * Author: Marc Zyngier marc.zyng...@arm.com + * + * Derived from arch/arm/kvm/guest.c: + * Copyright (C) 2012 - Virtual Open Systems and Columbia University + * Author: Christoffer Dall c.d...@virtualopensystems.com + * + * This program is free software; you can redistribute

Re: [PATCH v3 17/32] arm64: KVM: HYP mode world switch implementation

2013-04-23 Thread Christoffer Dall
On Mon, Apr 08, 2013 at 05:17:19PM +0100, Marc Zyngier wrote: The HYP mode world switch in all its glory. Implements save/restore of host/guest registers, EL2 trapping, IPA resolution, and additional services (tlb invalidation). Reviewed-by: Christopher Covington c...@codeaurora.org

Re: [PATCH v3 19/32] arm64: KVM: Plug the VGIC

2013-04-23 Thread Christoffer Dall
On Mon, Apr 08, 2013 at 05:17:21PM +0100, Marc Zyngier wrote: Add support for the in-kernel GIC emulation. The include file is a complete duplicate of the 32bit one - something to fix at one point. seems like something that should be fixed sooner as opposed to later... Is it hard?

Re: [PATCH v3 20/32] arm64: KVM: Plug the arch timer

2013-04-23 Thread Christoffer Dall
On Mon, Apr 08, 2013 at 05:17:22PM +0100, Marc Zyngier wrote: Add support for the in-kernel timer emulation. The include file is a complete duplicate of the 32bit one - something to fix at one point. again, I'd really like to see this fixed before we merge the code... Reviewed-by:

Re: [PATCH v3 24/32] arm64: KVM: 32bit GP register access

2013-04-23 Thread Christoffer Dall
+ * + * Derived from arch/arm/kvm/emulate.c: + * Copyright (C) 2012 - Virtual Open Systems and Columbia University + * Author: Christoffer Dall c.d...@virtualopensystems.com + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General

Re: [PATCH v3 25/32] arm64: KVM: 32bit conditional execution emulation

2013-04-23 Thread Christoffer Dall
..01d4713 --- /dev/null +++ b/arch/arm64/kvm/emulate.c @@ -0,0 +1,154 @@ +/* + * (not much of an) Emulation layer for 32bit guests. + * + * Copyright (C) 2012 - Virtual Open Systems and Columbia University + * Author: Christoffer Dall c.d...@virtualopensystems.com don't you want to add

Re: [PATCH v3 10/32] arm64: KVM: system register handling

2013-04-23 Thread Christoffer Dall
+ * + * Derived from arch/arm/kvm/coproc.c: + * Copyright (C) 2012 - Virtual Open Systems and Columbia University + * Authors: Rusty Russell ru...@rustcorp.com.au + * Christoffer Dall c.d...@virtualopensystems.com + * + * This program is free software; you can redistribute it and/or modify

Re: [PATCH v3 26/32] arm64: KVM: 32bit handling of coprocessor traps

2013-04-23 Thread Christoffer Dall
On Mon, Apr 08, 2013 at 05:17:28PM +0100, Marc Zyngier wrote: Provide the necessary infrastructure to trap coprocessor accesses that occur when running 32bit guests. Also wire SMC and HVC trapped in 32bit mode while were at it. Reviewed-by: Christopher Covington c...@codeaurora.org

Re: [PATCH v3 29/32] arm64: KVM: 32bit guest fault injection

2013-04-23 Thread Christoffer Dall
On Mon, Apr 08, 2013 at 05:17:31PM +0100, Marc Zyngier wrote: Add fault injection capability for 32bit guests. looks ok, but seems we are duplicating some functionality here, but I realize it may not be that easy to share due to different define names for things like PSR_X_BIT... Did you look

Re: [PATCH v3 30/32] arm64: KVM: enable initialization of a 32bit vcpu

2013-04-23 Thread Christoffer Dall
On Mon, Apr 08, 2013 at 05:17:32PM +0100, Marc Zyngier wrote: Wire the init of a 32bit vcpu by allowing 32bit modes in pstate, and providing sensible defaults out of reset state. This feature is of course conditioned by the presence of 32bit capability on the physical CPU, and is checked by

Re: [PATCH v3 31/32] arm64: KVM: userspace API documentation

2013-04-23 Thread Christoffer Dall
On Mon, Apr 08, 2013 at 05:17:33PM +0100, Marc Zyngier wrote: Unsurprisingly, the arm64 userspace API is extremely similar to the 32bit one, the only significant difference being the ONE_REG register mapping. Signed-off-by: Marc Zyngier marc.zyng...@arm.com ---

Re: [PATCH v3 00/32] Port of KVM to arm64

2013-04-23 Thread Christoffer Dall
at the least clearly commenting on the index into the kvm_regs struct): Acked-by: Christoffer Dall cd...@cs.columbia.edu -Christoffer As we do not have a 64bit QEMU port, it has been tested using kvmtools. Note that some of the changes have broken the userspace ABI in v2, and you must update

Re: [kvmarm] [PATCH 09/29] arm64: KVM: system register handling

2013-04-23 Thread Christoffer Dall
On Mon, Mar 25, 2013 at 1:19 AM, Marc Zyngier marc.zyng...@arm.com wrote: Hi Alex, On Thu, 7 Mar 2013 11:30:20 +0100, Alexander Graf ag...@suse.de wrote: On 05.03.2013, at 04:47, Marc Zyngier wrote: Provide 64bit system register handling, modeled after the cp15 handling for ARM.

Re: [PATCH v3 07/32] arm64: KVM: fault injection into a guest

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 3:04 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 23/04/13 23:57, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:09PM +0100, Marc Zyngier wrote: Implement the injection of a fault (undefined, data abort or prefetch abort) into a 64bit guest. Reviewed

Re: [PATCH v3 08/32] arm64: KVM: architecture specific MMU backend

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 4:10 AM, Will Deacon will.dea...@arm.com wrote: On Wed, Apr 24, 2013 at 12:03:10PM +0100, Marc Zyngier wrote: On 23/04/13 23:58, Christoffer Dall wrote: I noticed that this doesn't do any cache cleaning. Are the MMU page table walks guaranteed to be coherent

Re: [PATCH v3 08/32] arm64: KVM: architecture specific MMU backend

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 4:03 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 23/04/13 23:58, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:10PM +0100, Marc Zyngier wrote: Define the arm64 specific MMU backend: - HYP/kernel VA offset - S2 4/64kB definitions - S2 page table populating

Re: [PATCH v3 15/32] arm64: KVM: guest one-reg interface

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 4:27 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 23/04/13 23:59, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:17PM +0100, Marc Zyngier wrote: Let userspace play with the guest registers. Reviewed-by: Christopher Covington c...@codeaurora.org Signed-off

Re: [PATCH v3 17/32] arm64: KVM: HYP mode world switch implementation

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 4:39 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 23/04/13 23:59, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:19PM +0100, Marc Zyngier wrote: The HYP mode world switch in all its glory. Implements save/restore of host/guest registers, EL2 trapping, IPA

Re: [PATCH v3 24/32] arm64: KVM: 32bit GP register access

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 6:06 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 24/04/13 00:00, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:26PM +0100, Marc Zyngier wrote: Allow access to the 32bit register file through the usual API. Reviewed-by: Christopher Covington c

Re: [PATCH v3 25/32] arm64: KVM: 32bit conditional execution emulation

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 6:13 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 24/04/13 00:00, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:27PM +0100, Marc Zyngier wrote: As conditional instructions can trap on AArch32, add the thinest possible emulation layer to keep 32bit guests

Re: [PATCH v3 26/32] arm64: KVM: 32bit handling of coprocessor traps

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 6:42 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 24/04/13 00:01, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:28PM +0100, Marc Zyngier wrote: Provide the necessary infrastructure to trap coprocessor accesses that occur when running 32bit guests. Also wire

Re: [PATCH v3 29/32] arm64: KVM: 32bit guest fault injection

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 6:46 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 24/04/13 00:02, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:31PM +0100, Marc Zyngier wrote: Add fault injection capability for 32bit guests. looks ok, but seems we are duplicating some functionality here

Re: [PATCH v3 30/32] arm64: KVM: enable initialization of a 32bit vcpu

2013-04-24 Thread Christoffer Dall
On Wed, Apr 24, 2013 at 6:49 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 24/04/13 00:02, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:32PM +0100, Marc Zyngier wrote: Wire the init of a 32bit vcpu by allowing 32bit modes in pstate, and providing sensible defaults out of reset state

Re: [PATCH v3 08/32] arm64: KVM: architecture specific MMU backend

2013-04-25 Thread Christoffer Dall
On Thu, Apr 25, 2013 at 5:59 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 24/04/13 17:55, Christoffer Dall wrote: On Wed, Apr 24, 2013 at 4:03 AM, Marc Zyngier marc.zyng...@arm.com wrote: On 23/04/13 23:58, Christoffer Dall wrote: On Mon, Apr 08, 2013 at 05:17:10PM +0100, Marc Zyngier wrote

[GIT PULL] KVM/ARM Changes for 3.10

2013-04-28 Thread Christoffer Dall
check Arnd Bergmann (1): ARM: KVM: define KVM_ARM_MAX_VCPUS unconditionally Christoffer Dall (2): KVM: ARM: Fix API documentation for ONE_REG encoding KVM: ARM: Fix spelling in error message Marc Zyngier (10): ARM: KVM: add support for minimal host vs guest profiling

Re: [GIT PULL] KVM/ARM Changes for 3.10

2013-04-29 Thread Christoffer Dall
On Mon, Apr 29, 2013 at 7:11 PM, Marcelo Tosatti mtosa...@redhat.com wrote: On Sun, Apr 28, 2013 at 10:29:07PM -0700, Christoffer Dall wrote: Hi Marcelo and Gleb, These are the changes for KVM/ARM for 3.10. The patches depend on the cleanup branch, which you've already merged. Main thing

[GIT PULL v2] KVM/ARM Changes for 3.10

2013-04-30 Thread Christoffer Dall
] No changes since v1, except sending patch series with this one. Thanks! Andre Przywara (1): ARM: KVM: iterate over all CPUs for CPU compatibility check Arnd Bergmann (1): ARM: KVM: define KVM_ARM_MAX_VCPUS unconditionally Christoffer Dall (2): KVM: ARM: Fix API documentation for ONE_REG

[PATCH 01/15] ARM: KVM: add support for minimal host vs guest profiling

2013-04-30 Thread Christoffer Dall
being able to profile your KVM host. Signed-off-by: Marc Zyngier marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/include/asm/kvm_host.h |3 ++ arch/arm/kvm/Makefile |2 +- arch/arm/kvm/arm.c |4 +++ arch/arm/kvm/perf.c

[PATCH 03/15] ARM: KVM: simplify HYP mapping population

2013-04-30 Thread Christoffer Dall
the two PTE accessors, passing a pgprot_t around, and moving the various validity checks to the upper layers. Signed-off-by: Marc Zyngier marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/kvm/mmu.c | 102 ++-- 1 file

[PATCH 06/15] ARM: KVM: enforce maximum size for identity mapped code

2013-04-30 Thread Christoffer Dall
...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/kernel/vmlinux.lds.S |7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S index b571484..a871b8e 100644 --- a/arch/arm/kernel

[PATCH 07/15] ARM: KVM: rework HYP page table freeing

2013-04-30 Thread Christoffer Dall
thing we never actually called free_hyp_pmds before...). Signed-off-by: Marc Zyngier marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/include/asm/kvm_mmu.h |2 +- arch/arm/kvm/arm.c |2 +- arch/arm/kvm/mmu.c | 181

[PATCH 05/15] ARM: KVM: move to a KVM provided HYP idmap

2013-04-30 Thread Christoffer Dall
marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/include/asm/idmap.h |1 - arch/arm/include/asm/kvm_mmu.h |1 - arch/arm/kvm/mmu.c | 24 +++- arch/arm/mm/idmap.c| 32 +--- 4 files

[PATCH 10/15] ARM: KVM: add architecture specific hook for capabilities

2013-04-30 Thread Christoffer Dall
marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/include/asm/kvm_host.h |5 + arch/arm/kvm/arm.c |2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/arm/include/asm/kvm_host.h b/arch/arm/include/asm/kvm_host.h index

[PATCH 15/15] ARM: KVM: iterate over all CPUs for CPU compatibility check

2013-04-30 Thread Christoffer Dall
(for example in Big.Little). [ I cut some of the commit message and changed the formatting of the code slightly to pass checkpatch and look more like the rest of the kvm/arm init code - Christoffer ] Signed-off-by: Andre Przywara andre.przyw...@linaro.org Signed-off-by: Christoffer Dall cd

[PATCH 14/15] KVM: ARM: Fix spelling in error message

2013-04-30 Thread Christoffer Dall
s/unkown/unknown/ Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/kvm/handle_exit.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/kvm/handle_exit.c b/arch/arm/kvm/handle_exit.c index 26ad173..3d74a0b 100644 --- a/arch/arm/kvm/handle_exit.c

[PATCH 13/15] ARM: KVM: define KVM_ARM_MAX_VCPUS unconditionally

2013-04-30 Thread Christoffer Dall
Zyngier marc.zyng...@arm.com Cc: Christoffer Dall cd...@cs.columbia.edu Cc: Will Deacon will.dea...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/kvm/Kconfig |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/arm/kvm/Kconfig b/arch/arm/kvm

[PATCH 11/15] ARM: KVM: promote vfp_host pointer to generic host cpu context

2013-04-30 Thread Christoffer Dall
to the guest. Simply rename the vfp_host field to host_cpu_context, and the corresponding type to kvm_cpu_context_t. No change in functionnality. Signed-off-by: Marc Zyngier marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/include/asm/kvm_host.h |8

[PATCH 12/15] KVM: ARM: Fix API documentation for ONE_REG encoding

2013-04-30 Thread Christoffer Dall
Unless I'm mistaken, the size field was encoded 4 bits off and a wrong value was used for 64-bit FP registers. Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- Documentation/virtual/kvm/api.txt | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git

[PATCH 09/15] ARM: KVM: perform HYP initilization for hotplugged CPUs

2013-04-30 Thread Christoffer Dall
with HYP mode enabled and return to the kernel by following the normal boot path (HYP stub installed). Signed-off-by: Marc Zyngier marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/include/asm/kvm_mmu.h |1 + arch/arm/kvm/arm.c | 49

[PATCH 08/15] ARM: KVM: switch to a dual-step HYP init code

2013-04-30 Thread Christoffer Dall
mapping permanently (it is not strictly an idmap anymore) to allow for CPU hotplug in later patches. Signed-off-by: Marc Zyngier marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/include/asm/kvm_host.h | 31 + arch/arm/include/asm/kvm_mmu.h | 24

[PATCH 04/15] ARM: KVM: fix HYP mapping limitations around zero

2013-04-30 Thread Christoffer Dall
with the rest of the kernel in the process. Signed-off-by: Marc Zyngier marc.zyng...@arm.com Signed-off-by: Christoffer Dall cd...@cs.columbia.edu --- arch/arm/kvm/mmu.c | 21 ++--- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/arch/arm/kvm/mmu.c b/arch/arm/kvm/mmu.c

[PATCH 02/15] ARM: KVM: arch_timer: use symbolic constants

2013-04-30 Thread Christoffer Dall
From: Mark Rutland mark.rutl...@arm.com In clocksource/arm_arch_timer.h we define useful symbolic constants. Let's use them to make the KVM arch_timer code clearer. Signed-off-by: Mark Rutland mark.rutl...@arm.com Acked-by: Marc Zyngier marc.zyng...@arm.com Cc: Christoffer Dall cd

Re: [PATCH 1/4] ARM: KVM: be more thorough when invalidating TLBs

2013-04-30 Thread Christoffer Dall
On Tue, Apr 30, 2013 at 7:17 AM, Marc Zyngier marc.zyng...@arm.com wrote: The KVM/ARM MMU code doesn't take care of invalidating TLBs before freeing a {pte,pmd} table. This could cause problems if the page is reallocated and then speculated into by another CPU. Reported-by: Catalin Marinas

Re: [PATCH 4/4] ARM: KVM: fix use of S2_PGD_SIZE

2013-04-30 Thread Christoffer Dall
On Tue, Apr 30, 2013 at 7:17 AM, Marc Zyngier marc.zyng...@arm.com wrote: S2_PGD_SIZE describe the number of pages a used by a stage-2 PGD, not the size of the PGD. Fix the VM_BUG_ON() call that doesn't check much when S2_PGD_SIZE is equal to 1. Signed-off-by: Marc Zyngier

Re: [PATCH 4/4] ARM: KVM: fix use of S2_PGD_SIZE

2013-04-30 Thread Christoffer Dall
On Tue, Apr 30, 2013 at 06:52:24PM +0100, Marc Zyngier wrote: On 30/04/13 18:40, Christoffer Dall wrote: On Tue, Apr 30, 2013 at 7:17 AM, Marc Zyngier marc.zyng...@arm.com wrote: S2_PGD_SIZE describe the number of pages a used by a stage-2 PGD, not the size of the PGD. Fix the VM_BUG_ON

<    2   3   4   5   6   7   8   9   10   11   >