aboutsummaryrefslogtreecommitdiff
path: root/target-s390x
diff options
context:
space:
mode:
authorDominik Dingel <dingel@linux.vnet.ibm.com>2015-08-11 11:12:12 +0200
committerCornelia Huck <cornelia.huck@de.ibm.com>2015-11-11 17:21:39 +0100
commit4c292a009700755a1e6b234063ef3f2db235aaae (patch)
tree923a0f286415fc21b9359a2b0a65d04c69bef069 /target-s390x
parentae23a33591056d6349753766047ebc511158da9c (diff)
s390x/kvm: don't enable CMMA when hugetlbfs will be used
On hugetlbfs CMMA will not be useful as every ESSA instruction will trap. So don't offer CMMA to guests with a hugepages backing. Signed-off-by: Dominik Dingel <dingel@linux.vnet.ibm.com> Acked-by: Christian Borntraeger <borntraeger@de.ibm.com> Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Diffstat (limited to 'target-s390x')
-rw-r--r--target-s390x/kvm.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/target-s390x/kvm.c b/target-s390x/kvm.c
index c3be180de2..75a0e5d1c3 100644
--- a/target-s390x/kvm.c
+++ b/target-s390x/kvm.c
@@ -258,7 +258,9 @@ int kvm_arch_init(MachineState *ms, KVMState *s)
cap_mem_op = kvm_check_extension(s, KVM_CAP_S390_MEM_OP);
cap_s390_irq = kvm_check_extension(s, KVM_CAP_S390_INJECT_IRQ);
- kvm_s390_enable_cmma(s);
+ if (!mem_path) {
+ kvm_s390_enable_cmma(s);
+ }
if (!kvm_check_extension(s, KVM_CAP_S390_GMAP)
|| !kvm_check_extension(s, KVM_CAP_S390_COW)) {