diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2016-05-18 13:08:02 +0200 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2016-05-19 13:07:34 +0200 |
commit | b01501db18dbb04a30c647981b376fb5712bc34f (patch) | |
tree | 72fdc0e222b98fdced4e983c0e36f9b63307361c /target-s390x/machine.c | |
parent | f115a19c40b6ef19f08d12eeb032d88f176d6870 (diff) |
s390x: move .needed functions for subsections to machine.c
These functions are only used when defining subsections, so move
them there.
Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'target-s390x/machine.c')
-rw-r--r-- | target-s390x/machine.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/target-s390x/machine.c b/target-s390x/machine.c index a30b16fe3d..aa39e5daa4 100644 --- a/target-s390x/machine.c +++ b/target-s390x/machine.c @@ -76,6 +76,16 @@ static const VMStateDescription vmstate_fpu = { } }; +static bool vregs_needed(void *opaque) +{ +#ifdef CONFIG_KVM + if (kvm_enabled()) { + return kvm_check_extension(kvm_state, KVM_CAP_S390_VECTOR_REGISTERS); + } +#endif + return 0; +} + static const VMStateDescription vmstate_vregs = { .name = "cpu/vregs", .version_id = 1, @@ -135,6 +145,16 @@ static const VMStateDescription vmstate_vregs = { } }; +static bool riccb_needed(void *opaque) +{ +#ifdef CONFIG_KVM + if (kvm_enabled()) { + return kvm_s390_get_ri(); + } +#endif + return 0; +} + const VMStateDescription vmstate_riccb = { .name = "cpu/riccb", .version_id = 1, |