aboutsummaryrefslogtreecommitdiff
path: root/hw/s390x
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2021-07-12 19:15:11 +0100
committerPeter Maydell <peter.maydell@linaro.org>2021-07-12 19:15:11 +0100
commit57e28d34c0cb04abf7683ac6a12c87ede447c320 (patch)
tree08efbe5bff4d97f761f38d3f7b1544b14774a3fb /hw/s390x
parent552fda48e095c16a14c9d275b4fdc5c392c386cf (diff)
parent7ab3eb42b0d795f7321c4fca0ea06cb76a005b04 (diff)
downloadqemu-57e28d34c0cb04abf7683ac6a12c87ede447c320.zip
qemu-57e28d34c0cb04abf7683ac6a12c87ede447c320.tar.gz
qemu-57e28d34c0cb04abf7683ac6a12c87ede447c320.tar.bz2
Merge remote-tracking branch 'remotes/cohuck-gitlab/tags/s390x-20210708' into staging
s390x updates: - add gen16 cpumodels - refactor/cleanup some code - bugfixes # gpg: Signature made Thu 08 Jul 2021 12:26:21 BST # gpg: using EDDSA key 69A3B536F5CBFC65208026C1DE88BB5641DE66C1 # gpg: issuer "cohuck@redhat.com" # gpg: Good signature from "Cornelia Huck <conny@cornelia-huck.de>" [unknown] # gpg: aka "Cornelia Huck <huckc@linux.vnet.ibm.com>" [full] # gpg: aka "Cornelia Huck <cornelia.huck@de.ibm.com>" [full] # gpg: aka "Cornelia Huck <cohuck@kernel.org>" [unknown] # gpg: aka "Cornelia Huck <cohuck@redhat.com>" [unknown] # Primary key fingerprint: C3D0 D66D C362 4FF6 A8C0 18CE DECF 6B93 C6F0 2FAF # Subkey fingerprint: 69A3 B536 F5CB FC65 2080 26C1 DE88 BB56 41DE 66C1 * remotes/cohuck-gitlab/tags/s390x-20210708: target/s390x: split sysemu part of cpu models target/s390x: move kvm files into kvm/ target/s390x: remove kvm-stub.c target/s390x: use kvm_enabled() to wrap call to kvm_s390_get_hpage_1m target/s390x: make helper.c sysemu-only target/s390x: split cpu-dump from helper.c target/s390x: move sysemu-only code out to cpu-sysemu.c target/s390x: start moving TCG-only code to tcg/ target/s390x: rename internal.h to s390x-internal.h target/s390x: remove tcg-stub.c hw/s390x: only build tod-tcg from the CONFIG_TCG build hw/s390x: tod: make explicit checks for accelerators when initializing hw/s390x: rename tod-qemu.c to tod-tcg.c target/s390x: meson: add target_user_arch s390x/tcg: Fix m5 vs. m4 field for VECTOR MULTIPLY SUM LOGICAL target/s390x: Fix CC set by CONVERT TO FIXED/LOGICAL s390x/cpumodel: add 3931 and 3932 Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/s390x')
-rw-r--r--hw/s390x/meson.build4
-rw-r--r--hw/s390x/s390-stattrib-kvm.c2
-rw-r--r--hw/s390x/tod-kvm.c2
-rw-r--r--hw/s390x/tod-tcg.c (renamed from hw/s390x/tod-qemu.c)4
-rw-r--r--hw/s390x/tod.c9
5 files changed, 15 insertions, 6 deletions
diff --git a/hw/s390x/meson.build b/hw/s390x/meson.build
index 327e9c9..2848425 100644
--- a/hw/s390x/meson.build
+++ b/hw/s390x/meson.build
@@ -16,7 +16,6 @@ s390x_ss.add(files(
'sclp.c',
'sclpcpu.c',
'sclpquiesce.c',
- 'tod-qemu.c',
'tod.c',
))
s390x_ss.add(when: 'CONFIG_KVM', if_true: files(
@@ -25,6 +24,9 @@ s390x_ss.add(when: 'CONFIG_KVM', if_true: files(
's390-stattrib-kvm.c',
'pv.c',
))
+s390x_ss.add(when: 'CONFIG_TCG', if_true: files(
+ 'tod-tcg.c',
+))
s390x_ss.add(when: 'CONFIG_S390_CCW_VIRTIO', if_true: files('s390-virtio-ccw.c'))
s390x_ss.add(when: 'CONFIG_TERMINAL3270', if_true: files('3270-ccw.c'))
s390x_ss.add(when: 'CONFIG_VFIO', if_true: files('s390-pci-vfio.c'))
diff --git a/hw/s390x/s390-stattrib-kvm.c b/hw/s390x/s390-stattrib-kvm.c
index f0b11a7..24cd013 100644
--- a/hw/s390x/s390-stattrib-kvm.c
+++ b/hw/s390x/s390-stattrib-kvm.c
@@ -16,7 +16,7 @@
#include "qemu/error-report.h"
#include "sysemu/kvm.h"
#include "exec/ram_addr.h"
-#include "kvm_s390x.h"
+#include "kvm/kvm_s390x.h"
Object *kvm_s390_stattrib_create(void)
{
diff --git a/hw/s390x/tod-kvm.c b/hw/s390x/tod-kvm.c
index 0b94477..ec85581 100644
--- a/hw/s390x/tod-kvm.c
+++ b/hw/s390x/tod-kvm.c
@@ -13,7 +13,7 @@
#include "qemu/module.h"
#include "sysemu/runstate.h"
#include "hw/s390x/tod.h"
-#include "kvm_s390x.h"
+#include "kvm/kvm_s390x.h"
static void kvm_s390_get_tod_raw(S390TOD *tod, Error **errp)
{
diff --git a/hw/s390x/tod-qemu.c b/hw/s390x/tod-tcg.c
index e91b959..9bb94ff 100644
--- a/hw/s390x/tod-qemu.c
+++ b/hw/s390x/tod-tcg.c
@@ -1,5 +1,5 @@
/*
- * TOD (Time Of Day) clock - QEMU implementation
+ * TOD (Time Of Day) clock - TCG implementation
*
* Copyright 2018 Red Hat, Inc.
* Author(s): David Hildenbrand <david@redhat.com>
@@ -16,7 +16,7 @@
#include "qemu/cutils.h"
#include "qemu/module.h"
#include "cpu.h"
-#include "tcg_s390x.h"
+#include "tcg/tcg_s390x.h"
static void qemu_s390_tod_get(const S390TODState *td, S390TOD *tod,
Error **errp)
diff --git a/hw/s390x/tod.c b/hw/s390x/tod.c
index 3c29791..fd5a36b 100644
--- a/hw/s390x/tod.c
+++ b/hw/s390x/tod.c
@@ -14,6 +14,8 @@
#include "qemu/error-report.h"
#include "qemu/module.h"
#include "sysemu/kvm.h"
+#include "sysemu/tcg.h"
+#include "sysemu/qtest.h"
#include "migration/qemu-file-types.h"
#include "migration/register.h"
@@ -23,8 +25,13 @@ void s390_init_tod(void)
if (kvm_enabled()) {
obj = object_new(TYPE_KVM_S390_TOD);
- } else {
+ } else if (tcg_enabled()) {
obj = object_new(TYPE_QEMU_S390_TOD);
+ } else if (qtest_enabled()) {
+ return;
+ } else {
+ error_report("current accelerator not handled in s390_init_tod!");
+ abort();
}
object_property_add_child(qdev_get_machine(), TYPE_S390_TOD, obj);
object_unref(obj);