Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp6877213imu; Thu, 31 Jan 2019 00:55:16 -0800 (PST) X-Google-Smtp-Source: ALg8bN5ul+4L0yJwqiBugE/JxtOdbHmzgpjvStecpNxYDHBtaP0v/c9yswRJp+sawYBN1Io9hF++ X-Received: by 2002:a17:902:d697:: with SMTP id v23mr22346401ply.261.1548924916548; Thu, 31 Jan 2019 00:55:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548924916; cv=none; d=google.com; s=arc-20160816; b=06+qdkD514WMkPFnmfg7MhSmkS7/Lx7IHyXUkB7PrQr8RQpAk4/R95qAtr5ofgltDY yF/4CXRo/TY2F84Ybdr+kW+2I039e5wO9xU4oA58aQHcs0IWlv2iBlLHcAJh832DbulB lw1PQzu7WwYDAMTxU+puTLc2MN2Ks2xVcJfgxUWSttSUxTgm2J+/E0YEXJDSEVKa8IXL 7IkNqM/duAiKoavSDLMjK8+7LotgS/voH1XXRWFrPX8wszf/evnD/2lgygoovINMjnUC t3CCIU4VOVBhzTiyMeKRD5bLagbF05Zb3NvBnY4Tmfch5vaOC6OPy2ljFRsBS+qjcVew XC7A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:references:in-reply-to:date :subject:cc:to:from; bh=rV+Q/LwDYI8eCdHrLgK6wZCBEheTwtGu0q519Vnh5zA=; b=TgxGvgRq4Jq/9hz6j2FCumVMaUR57zyeUe1MyHPyy1eQx1n8nPnpRanrohfnTnfmET KzB5D4d6yrFaRCTcZAwp0OY8OOtcLthPNfqgXT7TvlSsut3/pyA6ng3hMynqg6N6Vr5p F/+iE2BQ0uVYQxcPYbZkA4EzF/oUwGal2+YdrPnu1CgSr6R51QFJwGb8VoDc6ekTFUDW ngJ8NknGA1+Wu5EF3BiQI1y+HyrgIYRGO9Ji46lLADNGxZXXnKy1pIhT/WT3TXJhZsj/ 1fhsI8k4wyhc8N0PO6Uc81QmpQKiqd+uuiZuBORslz6zFVrBcrYDy6YAEUF7Z5+uD+2n +EeA== 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=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y2si4119608pli.266.2019.01.31.00.55.01; Thu, 31 Jan 2019 00:55:16 -0800 (PST) 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=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731447AbfAaIy0 (ORCPT + 99 others); Thu, 31 Jan 2019 03:54:26 -0500 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:52686 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731424AbfAaIxe (ORCPT ); Thu, 31 Jan 2019 03:53:34 -0500 Received: from pps.filterd (m0098404.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x0V8htU8105905 for ; Thu, 31 Jan 2019 03:53:33 -0500 Received: from e06smtp01.uk.ibm.com (e06smtp01.uk.ibm.com [195.75.94.97]) by mx0a-001b2d01.pphosted.com with ESMTP id 2qbwr60d27-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 31 Jan 2019 03:53:32 -0500 Received: from localhost by e06smtp01.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 31 Jan 2019 08:53:30 -0000 Received: from b06cxnps3075.portsmouth.uk.ibm.com (9.149.109.195) by e06smtp01.uk.ibm.com (192.168.101.131) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 31 Jan 2019 08:53:26 -0000 Received: from d06av24.portsmouth.uk.ibm.com (d06av24.portsmouth.uk.ibm.com [9.149.105.60]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x0V8rPBl32047118 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Thu, 31 Jan 2019 08:53:25 GMT Received: from d06av24.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 0967142049; Thu, 31 Jan 2019 08:53:25 +0000 (GMT) Received: from d06av24.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 9BBE042042; Thu, 31 Jan 2019 08:53:24 +0000 (GMT) Received: from s38lp84.lnxne.boe (unknown [9.152.108.100]) by d06av24.portsmouth.uk.ibm.com (Postfix) with ESMTP; Thu, 31 Jan 2019 08:53:24 +0000 (GMT) From: Michael Mueller To: KVM Mailing List Cc: Linux-S390 Mailing List , linux-kernel@vger.kernel.org, Martin Schwidefsky , Heiko Carstens , Christian Borntraeger , Janosch Frank , David Hildenbrand , Cornelia Huck , Halil Pasic , Pierre Morel , Michael Mueller Subject: [PATCH v7 10/15] KVM: s390: add kvm reference to struct sie_page2 Date: Thu, 31 Jan 2019 09:52:41 +0100 X-Mailer: git-send-email 2.13.4 In-Reply-To: <20190131085247.13826-1-mimu@linux.ibm.com> References: <20190131085247.13826-1-mimu@linux.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 19013108-4275-0000-0000-00000308391F X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19013108-4276-0000-0000-0000381641B1 Message-Id: <20190131085247.13826-11-mimu@linux.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-01-31_04:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=944 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1901310070 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Adding the kvm reference to struct sie_page2 will allow to determine the kvm a given gisa belongs to: container_of(gisa, struct sie_page2, gisa)->kvm This functionality will be required to process a gisa in gib alert interruption context. Signed-off-by: Michael Mueller Reviewed-by: Pierre Morel Reviewed-by: Cornelia Huck Reviewed-by: David Hildenbrand Reviewed-by: Halil Pasic --- arch/s390/include/asm/kvm_host.h | 3 ++- arch/s390/kvm/kvm-s390.c | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/s390/include/asm/kvm_host.h b/arch/s390/include/asm/kvm_host.h index 397af0d33539..7077762ab460 100644 --- a/arch/s390/include/asm/kvm_host.h +++ b/arch/s390/include/asm/kvm_host.h @@ -801,7 +801,8 @@ struct sie_page2 { __u64 fac_list[S390_ARCH_FAC_LIST_SIZE_U64]; /* 0x0000 */ struct kvm_s390_crypto_cb crycb; /* 0x0800 */ struct kvm_s390_gisa gisa; /* 0x0900 */ - u8 reserved920[0x1000 - 0x920]; /* 0x0920 */ + struct kvm *kvm; /* 0x0920 */ + u8 reserved928[0x1000 - 0x928]; /* 0x0928 */ }; struct kvm_s390_vsie { diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c index 118d4c0bbb8e..67023d5656fd 100644 --- a/arch/s390/kvm/kvm-s390.c +++ b/arch/s390/kvm/kvm-s390.c @@ -2210,6 +2210,7 @@ int kvm_arch_init_vm(struct kvm *kvm, unsigned long type) if (!kvm->arch.sie_page2) goto out_err; + kvm->arch.sie_page2->kvm = kvm; kvm->arch.model.fac_list = kvm->arch.sie_page2->fac_list; for (i = 0; i < kvm_s390_fac_size(); i++) { -- 2.13.4