summaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorDavid Hildenbrand2017-08-18 13:43:51 +0200
committerCornelia Huck2017-08-30 18:23:25 +0200
commit5e7164c50c9f6ac531a0e3c7a49b3771ddefb8f3 (patch)
tree1d20e6d48e59ce7d72439f939fb595d74e813a84 /target
parenttarget/s390x: move a couple of functions to cpu.c (diff)
downloadqemu-5e7164c50c9f6ac531a0e3c7a49b3771ddefb8f3.tar.gz
qemu-5e7164c50c9f6ac531a0e3c7a49b3771ddefb8f3.tar.xz
qemu-5e7164c50c9f6ac531a0e3c7a49b3771ddefb8f3.zip
s390x: avoid calling kvm_ functions outside of target/s390x/
Let's just introduce an helper. Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Signed-off-by: David Hildenbrand <david@redhat.com> Message-Id: <20170818114353.13455-17-david@redhat.com> Signed-off-by: Cornelia Huck <cohuck@redhat.com>
Diffstat (limited to 'target')
-rw-r--r--target/s390x/cpu.c7
-rw-r--r--target/s390x/cpu.h1
2 files changed, 8 insertions, 0 deletions
diff --git a/target/s390x/cpu.c b/target/s390x/cpu.c
index 90e2db7b1f..c538a95850 100644
--- a/target/s390x/cpu.c
+++ b/target/s390x/cpu.c
@@ -471,6 +471,13 @@ bool s390_get_squash_mcss(void)
return false;
}
+
+void s390_enable_css_support(S390CPU *cpu)
+{
+ if (kvm_enabled()) {
+ kvm_s390_enable_css_support(cpu);
+ }
+}
#endif
static gchar *s390_gdb_arch_name(CPUState *cs)
diff --git a/target/s390x/cpu.h b/target/s390x/cpu.h
index a2cefb7a0c..77b29774cc 100644
--- a/target/s390x/cpu.h
+++ b/target/s390x/cpu.h
@@ -404,6 +404,7 @@ int cpu_s390x_signal_handler(int host_signum, void *pinfo,
#ifndef CONFIG_USER_ONLY
+void s390_enable_css_support(S390CPU *cpu);
int s390_virtio_hypercall(CPUS390XState *env);
#ifdef CONFIG_KVM