Skip to content

Commit b10bd9a

Browse files
Pierre Morelborntraeger
authored andcommitted
s390: vsie: Use effective CRYCBD.31 to check CRYCBD validity
When facility.76 MSAX3 is present for the guest we must issue a validity interception if the CRYCBD is not valid. The bit CRYCBD.31 is an effective field and tested at each guest level and has for effect to mask the facility.76 It follows that if CRYCBD.31 is clear and AP is not in use we do not have to test the CRYCBD validatity even if facility.76 is present in the host. Fixes: 6ee7409 ("KVM: s390: vsie: allow CRYCB FORMAT-0") Cc: stable@vger.kernel.org Signed-off-by: Pierre Morel <pmorel@linux.ibm.com> Reported-by: Claudio Imbrenda <imbrenda@linux.ibm.com> Acked-by: David Hildenbrand <david@redhat.com> Acked-by: Cornelia Huck <cohuck@redhat.com> Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com> Message-Id: <1549876849-32680-1-git-send-email-pmorel@linux.ibm.com> Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
1 parent bfeffd1 commit b10bd9a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/s390/kvm/vsie.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ static int shadow_crycb(struct kvm_vcpu *vcpu, struct vsie_page *vsie_page)
297297
scb_s->crycbd = 0;
298298

299299
apie_h = vcpu->arch.sie_block->eca & ECA_APIE;
300-
if (!apie_h && !key_msk)
300+
if (!apie_h && (!key_msk || fmt_o == CRYCB_FORMAT0))
301301
return 0;
302302

303303
if (!crycb_addr)

0 commit comments

Comments
 (0)