From: Eric Auger <eric.auger@redhat.com>
To: eric.auger.pro@gmail.com, eric.auger@redhat.com,
peter.maydell@linaro.org, qemu-arm@nongnu.org,
qemu-devel@nongnu.org, p.fedin@samsung.com
Cc: diana.craciun@freescale.com, shlomopongratz@gmail.com
Subject: [Qemu-devel] [RFC v4 2/6] target-arm: move gicv3_class_name from machine to kvm_arm.h
Date: Wed, 6 Jul 2016 11:46:00 +0200 [thread overview]
Message-ID: <1467798364-9049-3-git-send-email-eric.auger@redhat.com> (raw)
In-Reply-To: <1467798364-9049-1-git-send-email-eric.auger@redhat.com>
Machine.c contains code related to migration. Let's move
gicv3_class_name to kvm_arm.h instead.
Signed-off-by: Eric Auger <eric.auger@redhat.com>
Suggested-by: Peter Maydell <peter.maydell@linaro.org>
---
v4: creation
---
target-arm/kvm_arm.h | 16 +++++++++++++++-
target-arm/machine.c | 16 ----------------
2 files changed, 15 insertions(+), 17 deletions(-)
diff --git a/target-arm/kvm_arm.h b/target-arm/kvm_arm.h
index 544e404..4fb6d15 100644
--- a/target-arm/kvm_arm.h
+++ b/target-arm/kvm_arm.h
@@ -223,7 +223,21 @@ static inline const char *gic_class_name(void)
*
* Returns: class name to use
*/
-const char *gicv3_class_name(void);
+static inline const char *gicv3_class_name(void)
+{
+ if (kvm_irqchip_in_kernel()) {
+#ifdef TARGET_AARCH64
+ return "kvm-arm-gicv3";
+#else
+ error_report("KVM GICv3 acceleration is not supported on this "
+ "platform");
+#endif
+ } else {
+ return "arm-gicv3";
+ }
+
+ exit(1);
+}
/**
* kvm_arm_handle_debug:
diff --git a/target-arm/machine.c b/target-arm/machine.c
index 2dbeb82..d90943b 100644
--- a/target-arm/machine.c
+++ b/target-arm/machine.c
@@ -331,19 +331,3 @@ const VMStateDescription vmstate_arm_cpu = {
NULL
}
};
-
-const char *gicv3_class_name(void)
-{
- if (kvm_irqchip_in_kernel()) {
-#ifdef TARGET_AARCH64
- return "kvm-arm-gicv3";
-#else
- error_report("KVM GICv3 acceleration is not supported on this "
- "platform");
-#endif
- } else {
- return "arm-gicv3";
- }
-
- exit(1);
-}
--
2.5.5
next prev parent reply other threads:[~2016-07-06 9:49 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-06 9:45 [Qemu-devel] [RFC v4 0/6] vITS support Eric Auger
2016-07-06 9:45 ` [Qemu-arm] [RFC v4 1/6] hw/intc/arm_gicv3_its: Implement ITS base class Eric Auger
2016-07-06 9:46 ` Eric Auger [this message]
2016-07-10 20:17 ` [Qemu-arm] [RFC v4 2/6] target-arm: move gicv3_class_name from machine to kvm_arm.h Auger Eric
2016-07-06 9:46 ` [Qemu-arm] [RFC v4 3/6] linux-headers: update to 4.7-rc6 + ITS emulation and GSI routing Eric Auger
2016-07-06 9:46 ` [Qemu-arm] [RFC v4 4/6] target-arm/kvm: Pass requester ID to MSI routing functions Eric Auger
2016-07-06 9:46 ` [Qemu-arm] [RFC v4 5/6] hw/intc/arm_gicv3_its: Implement support for in-kernel ITS emulation Eric Auger
2016-07-29 13:35 ` Peter Maydell
2016-07-29 14:13 ` [Qemu-devel] " Auger Eric
2016-07-29 14:22 ` Peter Maydell
2016-07-06 9:46 ` [Qemu-arm] [RFC v4 6/6] arm/virt: Add ITS to the virt board Eric Auger
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=1467798364-9049-3-git-send-email-eric.auger@redhat.com \
--to=eric.auger@redhat.com \
--cc=diana.craciun@freescale.com \
--cc=eric.auger.pro@gmail.com \
--cc=p.fedin@samsung.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-arm@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=shlomopongratz@gmail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).