Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp5191136imm; Tue, 21 Aug 2018 07:44:22 -0700 (PDT) X-Google-Smtp-Source: AA+uWPx5yGNX14GVJYYigjliOmOeBmJGx1zIAdgVl/xmQ5eNYS3dPg8f/MgDSbtx/pyl4phjPXTW X-Received: by 2002:a17:902:b193:: with SMTP id s19-v6mr14617872plr.217.1534862662542; Tue, 21 Aug 2018 07:44:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1534862662; cv=none; d=google.com; s=arc-20160816; b=QI02JsqfNnI+AL0MovxiKFWmWVVdmO218/VZec0OWS5SZq8vy/+DvFn/aoI2vgKEPw xOt/C0y4W4oqVzgjinMgSACtw1aOTBnmPDFUdEAne4w3W/jRPnUQwjDKQ7bXffrOdDP9 YxchTsjD+8hwcfH1zQo5+orCL7/YJr6mii0W4uBqeP/UJWyIpCvX/+1q16tQ1ttwhEfq tW2HPalLG87N/NW/pWcL3jtZ9sNxbSYF9/FGdb03Jkfa+lfvy4xQDFhr68RCQyIei+8h 2cVLVnxpoROhuLU5nqvpK2aWgFsvy86TzM2hrwYLzJE43m8+GFrewo+hmtWrbpLfKIaS 8eOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:arc-authentication-results; bh=QfVzK3JJoU9bZbWEcVGUBUfweokSfEkdXYulcY+Gves=; b=pJEBDp0/9Xzvrys5yEF6VW1QUVM+fgkSMhaxMXY0l8AzWN1P5PMDy+FxOtVyU9hF/y g5iVR5Cbb0Bf9jHmNfNwQ4mOFu88leNLBto1WVHV/YEHMP5oYLCXKDAeeBk50ybb7KF/ F75tbCOfU4NVAuIsxoAWjaa6nNnubCchKpoitWgznUMlOcRurnd5/+00fE2lvEFjzq/W ihgUBJIDYl/P9x7gvmDmADxngm0kv/AJ34zkmnkHHlcYpBXjECV5fsA9G8MBYnclYGHQ skvkQWrtaIBOwKh1Stv7IFzDClACXyh9DWqAKp1q/8Y4NMs9cUUkXZOJhxRet1VMHYXP NFgg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f24-v6si5901840plj.509.2018.08.21.07.44.07; Tue, 21 Aug 2018 07:44:22 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727809AbeHUSDP (ORCPT + 99 others); Tue, 21 Aug 2018 14:03:15 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:51840 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726590AbeHUSDP (ORCPT ); Tue, 21 Aug 2018 14:03:15 -0400 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 1F37F7D84D; Tue, 21 Aug 2018 14:42:49 +0000 (UTC) Received: from gondolin (dhcp-192-222.str.redhat.com [10.33.192.222]) by smtp.corp.redhat.com (Postfix) with ESMTP id A570F94653; Tue, 21 Aug 2018 14:42:45 +0000 (UTC) Date: Tue, 21 Aug 2018 16:42:43 +0200 From: Cornelia Huck To: David Hildenbrand Cc: Pierre Morel , linux-kernel@vger.kernel.org, linux-s390@vger.kernel.org, kvm@vger.kernel.org, frankja@linux.ibm.com, akrowiak@linux.ibm.com, borntraeger@de.ibm.com, schwidefsky@de.ibm.com, heiko.carstens@de.ibm.com Subject: Re: [PATCH] KVM: s390: vsie: BUG correction by shadow_crycb Message-ID: <20180821164243.584e891f.cohuck@redhat.com> In-Reply-To: <4c91cd0c-d679-eecc-0566-ed45158f6b7f@redhat.com> References: <1534861178-30372-1-git-send-email-pmorel@linux.ibm.com> <20180821163348.327ce02d.cohuck@redhat.com> <4c91cd0c-d679-eecc-0566-ed45158f6b7f@redhat.com> Organization: Red Hat GmbH MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.79 on 10.11.54.5 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.2]); Tue, 21 Aug 2018 14:42:49 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.2]); Tue, 21 Aug 2018 14:42:49 +0000 (UTC) for IP:'10.11.54.5' DOMAIN:'int-mx05.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'cohuck@redhat.com' RCPT:'' Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 21 Aug 2018 16:36:19 +0200 David Hildenbrand wrote: > On 21.08.2018 16:33, Cornelia Huck wrote: > > On Tue, 21 Aug 2018 16:19:38 +0200 > > Pierre Morel wrote: > > > >> Copy the key mask to the right offset inside the shadow CRYCB > >> > >> Signed-off-by: Pierre Morel > >> --- > >> arch/s390/kvm/vsie.c | 3 ++- > >> 1 file changed, 2 insertions(+), 1 deletion(-) > >> > >> diff --git a/arch/s390/kvm/vsie.c b/arch/s390/kvm/vsie.c > >> index 63844b9..a2b28cd 100644 > >> --- a/arch/s390/kvm/vsie.c > >> +++ b/arch/s390/kvm/vsie.c > >> @@ -173,7 +173,8 @@ static int shadow_crycb(struct kvm_vcpu *vcpu, struct vsie_page *vsie_page) > >> return set_validity_icpt(scb_s, 0x0039U); > >> > >> /* copy only the wrapping keys */ > >> - if (read_guest_real(vcpu, crycb_addr + 72, &vsie_page->crycb, 56)) > >> + if (read_guest_real(vcpu, crycb_addr + 72, > >> + vsie_page->crycb.dea_wrapping_key_mask, 56)) > > > > Don't you need the address here? > > As it is defined as an array, the address would result in the same value. > > (&vsie_page->crycb.dea_wrapping_key_mask[0]) /me looks... Indeed, it just looks a bit odd. With the changed subject Reviewed-by: Cornelia Huck > > > > >> return set_validity_icpt(scb_s, 0x0035U); > >> > >> scb_s->ecb3 |= ecb3_flags; > > > >