From: Will Deacon <will.deacon@arm.com>
To: kvm@vger.kernel.org
Cc: penberg@kernel.org, sasha.levin@oracle.com, marc.zyngier@arm.com,
Marc Zyngier <Marc.Zyngier@arm.com>,
Will Deacon <will.deacon@arm.com>
Subject: [PATCH 4/5] kvm tools: arm64: add support for AEM and Foundation models
Date: Thu, 11 Apr 2013 17:36:25 +0100 [thread overview]
Message-ID: <1365698186-27355-5-git-send-email-will.deacon@arm.com> (raw)
In-Reply-To: <1365698186-27355-1-git-send-email-will.deacon@arm.com>
From: Marc Zyngier <Marc.Zyngier@arm.com>
The ARMv8 architecture is supported by two publicly available
software models: the Architecture Enveloppe Model, and the
Foundation model.
Both are fairly similar to the Cortex-A57 from a kvm tools point of
view, so we can hijack the A57 implementation to register these
new targets.
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
---
tools/kvm/arm/aarch64/cortex-a57.c | 20 +++++++++++++++++++-
1 file changed, 19 insertions(+), 1 deletion(-)
diff --git a/tools/kvm/arm/aarch64/cortex-a57.c b/tools/kvm/arm/aarch64/cortex-a57.c
index 5b0dc4c..0c340fb 100644
--- a/tools/kvm/arm/aarch64/cortex-a57.c
+++ b/tools/kvm/arm/aarch64/cortex-a57.c
@@ -49,6 +49,22 @@ static int cortex_a57__vcpu_init(struct kvm_cpu *vcpu)
return 0;
}
+/*
+ * As far as userspace is concerned, both of these implementations are
+ * extremely similar.
+ */
+static struct kvm_arm_target target_aem_v8 = {
+ .id = KVM_ARM_TARGET_AEM_V8,
+ .compatible = "arm,arm-v8",
+ .init = cortex_a57__vcpu_init,
+};
+
+static struct kvm_arm_target target_foundation_v8 = {
+ .id = KVM_ARM_TARGET_FOUNDATION_V8,
+ .compatible = "arm,arm-v8",
+ .init = cortex_a57__vcpu_init,
+};
+
static struct kvm_arm_target target_cortex_a57 = {
.id = KVM_ARM_TARGET_CORTEX_A57,
.compatible = "arm,cortex-a57",
@@ -57,6 +73,8 @@ static struct kvm_arm_target target_cortex_a57 = {
static int cortex_a57__core_init(struct kvm *kvm)
{
- return kvm_cpu__register_kvm_arm_target(&target_cortex_a57);
+ return (kvm_cpu__register_kvm_arm_target(&target_aem_v8) ||
+ kvm_cpu__register_kvm_arm_target(&target_foundation_v8) ||
+ kvm_cpu__register_kvm_arm_target(&target_cortex_a57));
}
core_init(cortex_a57__core_init);
--
1.8.0
next prev parent reply other threads:[~2013-04-11 16:36 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-11 16:36 [PATCH 0/5] Usual batch of random ARM fixes for kvmtool Will Deacon
2013-04-11 16:36 ` [PATCH 1/5] kvm tools: arm: don't crash when no compatible CPU is found Will Deacon
2013-04-11 16:36 ` [PATCH 2/5] kvm tools: arm: add CPU compatible string to target structure Will Deacon
2013-04-11 16:36 ` [PATCH 3/5] kvm tools: arm: consolidate CPU node generation Will Deacon
2013-04-11 16:36 ` Will Deacon [this message]
2013-04-11 16:36 ` [PATCH 5/5] kvm tools: bump number of virtio MMIO vqueues Will Deacon
2013-04-11 16:45 ` [PATCH 0/5] Usual batch of random ARM fixes for kvmtool Sasha Levin
2013-04-12 6:52 ` Pekka Enberg
2013-04-12 8:30 ` Marc Zyngier
2013-04-12 8:50 ` Will Deacon
2013-04-11 20:02 ` virtio-net mq vq initialization (was: [PATCH 0/5] Usual batch of random ARM fixes for kvmtool) Sasha Levin
2013-04-12 11:36 ` Rusty Russell
2013-04-12 12:41 ` Will Deacon
2013-04-14 10:03 ` Michael S. Tsirkin
2013-04-13 21:23 ` virtio-net mq vq initialization Sasha Levin
2013-04-14 10:01 ` Michael S. Tsirkin
2013-04-14 15:16 ` Sasha Levin
2013-04-14 15:53 ` Michael S. Tsirkin
2013-04-14 15:59 ` Sasha Levin
2013-04-14 18:35 ` Michael S. Tsirkin
2013-04-15 2:55 ` Rusty Russell
2013-04-15 5:58 ` Jason Wang
2013-04-22 18:32 ` Sasha Levin
2013-04-12 7:12 ` [PATCH 0/5] Usual batch of random ARM fixes for kvmtool Pekka Enberg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1365698186-27355-5-git-send-email-will.deacon@arm.com \
--to=will.deacon@arm.com \
--cc=kvm@vger.kernel.org \
--cc=marc.zyngier@arm.com \
--cc=penberg@kernel.org \
--cc=sasha.levin@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.