Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge tag 'kvm-s390-master-4.12-1' of git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux into HEAD

KVM: s390: Fix for master (4.12)

- The newly created AIS capability enables the feature unconditionally
and ignores the cpu model

+2 -5
-1
arch/s390/include/asm/kvm_host.h
··· 541 541 struct mutex ais_lock; 542 542 u8 simm; 543 543 u8 nimm; 544 - int ais_enabled; 545 544 }; 546 545 547 546 struct kvm_hw_wp_info_arch {
+2 -2
arch/s390/kvm/interrupt.c
··· 2160 2160 struct kvm_s390_ais_req req; 2161 2161 int ret = 0; 2162 2162 2163 - if (!fi->ais_enabled) 2163 + if (!test_kvm_facility(kvm, 72)) 2164 2164 return -ENOTSUPP; 2165 2165 2166 2166 if (copy_from_user(&req, (void __user *)attr->addr, sizeof(req))) ··· 2204 2204 }; 2205 2205 int ret = 0; 2206 2206 2207 - if (!fi->ais_enabled || !adapter->suppressible) 2207 + if (!test_kvm_facility(kvm, 72) || !adapter->suppressible) 2208 2208 return kvm_s390_inject_vm(kvm, &s390int); 2209 2209 2210 2210 mutex_lock(&fi->ais_lock);
-2
arch/s390/kvm/kvm-s390.c
··· 558 558 } else { 559 559 set_kvm_facility(kvm->arch.model.fac_mask, 72); 560 560 set_kvm_facility(kvm->arch.model.fac_list, 72); 561 - kvm->arch.float_int.ais_enabled = 1; 562 561 r = 0; 563 562 } 564 563 mutex_unlock(&kvm->lock); ··· 1532 1533 mutex_init(&kvm->arch.float_int.ais_lock); 1533 1534 kvm->arch.float_int.simm = 0; 1534 1535 kvm->arch.float_int.nimm = 0; 1535 - kvm->arch.float_int.ais_enabled = 0; 1536 1536 spin_lock_init(&kvm->arch.float_int.lock); 1537 1537 for (i = 0; i < FIRQ_LIST_COUNT; i++) 1538 1538 INIT_LIST_HEAD(&kvm->arch.float_int.lists[i]);