KVM: s390/cpacf: Fix kernel bug under z/VM
authorChristian Borntraeger <borntraeger@de.ibm.com>
Thu, 26 Feb 2015 12:53:47 +0000 (13:53 +0100)
committerChristian Borntraeger <borntraeger@de.ibm.com>
Wed, 4 Mar 2015 09:29:55 +0000 (10:29 +0100)
commit86044c8c14b618b11558d3cba96aa0548c81274d
tree7f086f7a95e223e5e3d47427e43a7f393cb19876
parented6f76b464ab53e59adc7ec6cc8428d3d6ade1a5
KVM: s390/cpacf: Fix kernel bug under z/VM

Under z/VM PQAP might trigger an operation exception if no crypto cards
are defined via APVIRTUAL or APDEDICATED.

[  386.098666] Kernel BUG at 0000000000135c56 [verbose debug info unavailable]
[  386.098693] illegal operation: 0001 ilc:2 [#1] SMP
[...]
[  386.098751] Krnl PSW : 0704c00180000000 0000000000135c56 (kvm_s390_apxa_installed+0x46/0x98)
[...]
[  386.098804]  [<000000000013627c>] kvm_arch_init_vm+0x29c/0x358
[  386.098806]  [<000000000012d008>] kvm_dev_ioctl+0xc0/0x460
[  386.098809]  [<00000000002c639a>] do_vfs_ioctl+0x332/0x508
[  386.098811]  [<00000000002c660e>] SyS_ioctl+0x9e/0xb0
[  386.098814]  [<000000000070476a>] system_call+0xd6/0x258
[  386.098815]  [<000003fffc7400a2>] 0x3fffc7400a2

Lets add an extable entry and provide a zeroed config in that case.

Reported-by: Stefan Zimmermann <stzi@linux.vnet.ibm.com>
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Reviewed-by: Thomas Huth <thuth@linux.vnet.ibm.com>
Tested-by: Stefan Zimmermann <stzi@linux.vnet.ibm.com>
arch/s390/kvm/kvm-s390.c