From mboxrd@z Thu Jan 1 00:00:00 1970 From: Cornelia Huck Subject: Re: [PULL 1/1] KVM: s390: Fix memory access error detection Date: Mon, 20 Jan 2014 13:00:02 +0100 Message-ID: <20140120130002.29d01053@gondolin> References: <1390218843-15196-1-git-send-email-borntraeger@de.ibm.com> <1390218843-15196-2-git-send-email-borntraeger@de.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: Gleb Natapov , Paolo Bonzini , kvm@vger.kernel.org, Thomas Huth , Dominik Dingel To: Christian Borntraeger Return-path: Received: from e06smtp15.uk.ibm.com ([195.75.94.111]:58912 "EHLO e06smtp15.uk.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752008AbaATMAI (ORCPT ); Mon, 20 Jan 2014 07:00:08 -0500 Received: from /spool/local by e06smtp15.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 20 Jan 2014 12:00:07 -0000 Received: from b06cxnps4076.portsmouth.uk.ibm.com (d06relay13.portsmouth.uk.ibm.com [9.149.109.198]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id 643611B08076 for ; Mon, 20 Jan 2014 11:59:30 +0000 (GMT) Received: from d06av05.portsmouth.uk.ibm.com (d06av05.portsmouth.uk.ibm.com [9.149.37.229]) by b06cxnps4076.portsmouth.uk.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id s0KBxrpE65142808 for ; Mon, 20 Jan 2014 11:59:53 GMT Received: from d06av05.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av05.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s0KC04rs011998 for ; Mon, 20 Jan 2014 05:00:05 -0700 In-Reply-To: <1390218843-15196-2-git-send-email-borntraeger@de.ibm.com> Sender: kvm-owner@vger.kernel.org List-ID: On Mon, 20 Jan 2014 12:54:03 +0100 Christian Borntraeger wrote: > Seems that commit 210b1607012cc9034841a393e0591b2c86d9e26c > (KVM: s390: Removed SIE_INTERCEPT_UCONTROL) lost a hunk when we > reworked our patch queue to rework the async_fp code. We now > ignore faults on the sie instruction (guest accesses non-existing > memory) instead of sending a fault into the guest. This leads to > hang situations with the old virtio transport that checks for > descriptor memory after guest memory. Instead of bailing out this > code now goes wild... > Lets re-add the check. > > Signed-off-by: Christian Borntraeger Acked-by: Cornelia Huck > --- > arch/s390/kvm/kvm-s390.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c > index 1bb1dda..7635c00 100644 > --- a/arch/s390/kvm/kvm-s390.c > +++ b/arch/s390/kvm/kvm-s390.c > @@ -738,6 +738,10 @@ static int vcpu_post_run(struct kvm_vcpu *vcpu, int exit_reason) > current->thread.gmap_addr; > vcpu->run->s390_ucontrol.pgm_code = 0x10; > rc = -EREMOTE; > + } else { > + VCPU_EVENT(vcpu, 3, "%s", "fault in sie instruction"); > + trace_kvm_s390_sie_fault(vcpu); > + rc = kvm_s390_inject_program_int(vcpu, PGM_ADDRESSING); > } > > memcpy(&vcpu->run->s.regs.gprs[14], &vcpu->arch.sie_block->gg14, 16);