From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587534; cv=none; d=zoho.com; s=zohoarc; b=SFC8wqR3RKk8oEH7Sr6r7N+8kcOM0hmefw5Wsg+PcY2xU0POTnymOctqG9WdiOVcW7AA3JlXA1bkA2054OnXJjuzgR98zte7KS3MiIEV7NUcUM+QQTuEv+t8LUN+0q3AXsmnNXjzrv4eq9E+tc/6u7nrzFuxrxzphDBKwyaruBg= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587534; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=2OTxaVKlCVmcbMLYvHCnFkFyCM3KzBg7np6jtmLJTmw=; b=dubnRE4HxhvFR+6YZZISpiE5+sQB/K1w4PIc/gYMiC/ffzhOZHwaN1bmk3EubO9LNQrzPQTeL9h4qWdSVnLowynAobVl0PWxnlcNP9/ghI5Zj/BX0X+G9Z8oFjmGpU8PWZdJiYt9kIqp31ka2C4rtTtZVCQG89/yAvNM/FLyKaA= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 155558753451218.00521050533382; Thu, 18 Apr 2019 04:38:54 -0700 (PDT) Received: from localhost ([127.0.0.1]:39891 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5NQ-00081c-HB for importer@patchew.org; Thu, 18 Apr 2019 07:38:48 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50690) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GH-0002kh-Uu for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GF-0004Wl-Qh for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:25 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:40880 helo=mx0a-001b2d01.pphosted.com) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GF-0004P4-FE for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:23 -0400 Received: from pps.filterd (m0098419.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBTcwb102787 for ; Thu, 18 Apr 2019 07:31:18 -0400 Received: from e06smtp04.uk.ibm.com (e06smtp04.uk.ibm.com [195.75.94.100]) by mx0b-001b2d01.pphosted.com with ESMTP id 2rxqa933pc-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:18 -0400 Received: from localhost by e06smtp04.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:16 +0100 Received: from b06cxnps4075.portsmouth.uk.ibm.com (9.149.109.197) by e06smtp04.uk.ibm.com (192.168.101.134) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 18 Apr 2019 12:31:13 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVBZs40370290 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:12 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B531452057; Thu, 18 Apr 2019 11:31:11 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id AC4D652054; Thu, 18 Apr 2019 11:31:11 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 6C4F120F63B; Thu, 18 Apr 2019 13:31:11 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:01 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-0016-0000-0000-0000027035E7 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-0017-0000-0000-000032CC8CE8 Message-Id: <20190418113110.160664-2-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=771 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.158.5 Subject: [Qemu-devel] [PATCH 01/10] linux header sync X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" to be replaced by a proper one Signed-off-by: Christian Borntraeger --- linux-headers/asm-s390/kvm.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/linux-headers/asm-s390/kvm.h b/linux-headers/asm-s390/kvm.h index 0265482f8f..03ab5968c7 100644 --- a/linux-headers/asm-s390/kvm.h +++ b/linux-headers/asm-s390/kvm.h @@ -152,7 +152,10 @@ struct kvm_s390_vm_cpu_subfunc { __u8 pcc[16]; /* with MSA4 */ __u8 ppno[16]; /* with MSA5 */ __u8 kma[16]; /* with MSA8 */ - __u8 reserved[1808]; + __u8 kdsa[16]; /* with MSA9 */ + __u8 sortl[32]; /* with STFLE.150 */ + __u8 dfltcc[32]; /* with STFLE.151 */ + __u8 reserved[1728]; }; =20 /* kvm attributes for crypto */ --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587545; cv=none; d=zoho.com; s=zohoarc; b=Y7oDHnUv1Qx4FF2iVrlCyi4pq4ff0WIHFC2daWp0X1PuARBjzJxv2LH3SnGbjhUkTLP1l/T3hVD858ctogI28k1DCGqoeifJpILx1uY0d9XxGWD0zughkTZnCv+liqzAMj0vDFkGFJgIRp4BfHNV2sT+BUliGHaXRVuBbfQ7LAI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587545; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=xHN9zRrFo1sM8sgrjMq0JM4BJLloAKadNUpkleAIgjs=; b=RTnClj6Azjw6WI4T+IBY9yB35y7OJmr4CpStVX2CYb+dZnlafZHTviLKmvGrx2jMyKXLEBLyyTeSkYfMZCwPotwjUpsjuAngapiulLXOexGLvJl6ax++uyYA5L0avtVh5XXvvYH0iBuQpXroaYglwvCNZkIP6IUS3UagZ7wNFxk= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1555587545339726.2743091953487; Thu, 18 Apr 2019 04:39:05 -0700 (PDT) Received: from localhost ([127.0.0.1]:39893 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5Na-0008BB-8G for importer@patchew.org; Thu, 18 Apr 2019 07:38:58 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50756) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GJ-0002mC-Es for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:29 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GF-0004XK-UV for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:27 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:45196 helo=mx0a-001b2d01.pphosted.com) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GF-0004Om-FF for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:23 -0400 Received: from pps.filterd (m0098417.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBTTh3033227 for ; Thu, 18 Apr 2019 07:31:18 -0400 Received: from e06smtp04.uk.ibm.com (e06smtp04.uk.ibm.com [195.75.94.100]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxq86368w-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:17 -0400 Received: from localhost by e06smtp04.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:15 +0100 Received: from b06cxnps4074.portsmouth.uk.ibm.com (9.149.109.196) by e06smtp04.uk.ibm.com (192.168.101.134) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 18 Apr 2019 12:31:13 +0100 Received: from d06av24.portsmouth.uk.ibm.com (d06av24.portsmouth.uk.ibm.com [9.149.105.60]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVC0x46465146 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:12 GMT Received: from d06av24.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 210EA4204D; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: from d06av24.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 0CF9D42045; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av24.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id B2B2920F639; Thu, 18 Apr 2019 13:31:11 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:02 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-0016-0000-0000-0000027035EA X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-0017-0000-0000-000032CC8CE9 Message-Id: <20190418113110.160664-3-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.158.5 Subject: [Qemu-devel] [PATCH 02/10] s390x/cpumodel: remove CSSKE from base model X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" conditional sske is deprecated and a distant future machine (will be one where the IBC will not allow to fully go back to z14) will remove this feature. To prepare for this and allow for the z14 and older cpu model to still run on systems without csske, remove csske from the base (and thus the default models for z10..z14). For compat machines we have to add those back. Signed-off-by: Christian Borntraeger --- hw/s390x/s390-virtio-ccw.c | 2 ++ target/s390x/cpu_models.c | 21 +++++++++++++++++++++ target/s390x/cpu_models.h | 1 + target/s390x/gen-features.c | 1 - 4 files changed, 24 insertions(+), 1 deletion(-) diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c index d11069b860..3415948b2c 100644 --- a/hw/s390x/s390-virtio-ccw.c +++ b/hw/s390x/s390-virtio-ccw.c @@ -648,6 +648,8 @@ bool css_migration_enabled(void) =20 static void ccw_machine_4_0_instance_options(MachineState *machine) { + /* re-enable csske for compat machines in the base model */ + s390_cpumodel_fixup_csske(); } =20 static void ccw_machine_4_0_class_options(MachineClass *mc) diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c index eb125d4d0d..4e5aa879f3 100644 --- a/target/s390x/cpu_models.c +++ b/target/s390x/cpu_models.c @@ -93,6 +93,27 @@ static S390FeatBitmap qemu_max_cpu_feat; /* features part of a base model but not relevant for finding a base model= */ S390FeatBitmap ignored_base_feat; =20 +/* + * We removed CSSKE from the base features. This is a hook for compat mach= ines + * to put this back for gen10..gen14. As the base model is also part of the + * default model to have to fixup both bitfields + */ +void s390_cpumodel_fixup_csske(void) +{ + int i; + + for (i =3D 0; i < ARRAY_SIZE(s390_cpu_defs); i++) { + const S390CPUDef *def =3D &s390_cpu_defs[i]; + + if (def->gen < 10 || def->gen > 14) { + continue; + } + + set_bit(S390_FEAT_CONDITIONAL_SSKE, (unsigned long *)&def->base_fe= at); + set_bit(S390_FEAT_CONDITIONAL_SSKE, (unsigned long *)&def->default= _feat); + } +} + void s390_cpudef_featoff(uint8_t gen, uint8_t ec_ga, S390Feat feat) { const S390CPUDef *def; diff --git a/target/s390x/cpu_models.h b/target/s390x/cpu_models.h index 174a99e561..b2e37bc8cf 100644 --- a/target/s390x/cpu_models.h +++ b/target/s390x/cpu_models.h @@ -73,6 +73,7 @@ struct S390CPUModel { #define ibc_gen(x) (x =3D=3D 0 ? 0 : ((x >> 4) + S390_GEN_Z10)) #define ibc_ec_ga(x) (x & 0xf) =20 +void s390_cpumodel_fixup_csske(void); void s390_cpudef_featoff(uint8_t gen, uint8_t ec_ga, S390Feat feat); void s390_cpudef_featoff_greater(uint8_t gen, uint8_t ec_ga, S390Feat feat= ); void s390_cpudef_group_featoff_greater(uint8_t gen, uint8_t ec_ga, diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c index e4739a6b9f..bea2f80c49 100644 --- a/target/s390x/gen-features.c +++ b/target/s390x/gen-features.c @@ -301,7 +301,6 @@ static uint16_t base_GEN9_GA1[] =3D { #define base_GEN9_GA3 EmptyFeat =20 static uint16_t base_GEN10_GA1[] =3D { - S390_FEAT_CONDITIONAL_SSKE, S390_FEAT_PARSING_ENH, S390_FEAT_MOVE_WITH_OPTIONAL_SPEC, S390_FEAT_EXTRACT_CPU_TIME, --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587221; cv=none; d=zoho.com; s=zohoarc; b=Ql9k38vzpkkzvEZU8+3i8m3oxdoUNg3osoWPwVNEYbb3rgvt45FqPCWoZt3/mEWhmCKSy/JHDczKC8l3OpTdR3Oe3hk8w2tybFbLgPQLkTLyki380yLMQmAiYkeYW4DprBb7uPbdg6i5HRKfA+n0XMV5cAEhEZt6qcKknXqag+0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587221; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=do30qRBEr5r2LqrwltZObLphl1iokB/ezy8QlbXFnf8=; b=LJL9ld6Gwzg35E+9ec5bOmtv+z3UbEUfDPJ20D3Tpu+zYzwDJKCMhmxJoRXNy0lU05l0zionx/RO0kAAGQfbmgSU2tzGedukOajqr0vlBQj/wWDCTd8AYZYOLBsBjxlOqF4eAeOry8GkxxgPLhkj8+rvHDZHWNOL7Sxom6ZkeoQ= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1555587221350633.0685830850759; Thu, 18 Apr 2019 04:33:41 -0700 (PDT) Received: from localhost ([127.0.0.1]:39808 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5IN-0003zO-7z for importer@patchew.org; Thu, 18 Apr 2019 07:33:35 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50650) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GG-0002jL-Q2 for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GF-0004W0-Ij for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:24 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:58798) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GF-0004Tk-4a for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:23 -0400 Received: from pps.filterd (m0098399.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBTRcH147144 for ; Thu, 18 Apr 2019 07:31:20 -0400 Received: from e06smtp04.uk.ibm.com (e06smtp04.uk.ibm.com [195.75.94.100]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxq8239r4-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:19 -0400 Received: from localhost by e06smtp04.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:17 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (9.149.109.198) by e06smtp04.uk.ibm.com (192.168.101.134) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 18 Apr 2019 12:31:14 +0100 Received: from d06av21.portsmouth.uk.ibm.com (d06av21.portsmouth.uk.ibm.com [9.149.105.232]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVCk546202894 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:12 GMT Received: from d06av21.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 4723652054; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av21.portsmouth.uk.ibm.com (Postfix) with ESMTPS id 3E70852052; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 009DE20F63B; Thu, 18 Apr 2019 13:31:11 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:03 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-0016-0000-0000-0000027035EB X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-0017-0000-0000-000032CC8CEA Message-Id: <20190418113110.160664-4-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.156.1 Subject: [Qemu-devel] [PATCH 03/10] s390x/cpumodel: Miscellaneous-Instruction-Extensions Facility 3 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" Provide the "Miscellaneous-Instruction-Extensions Facility 3" via stfle.61. Signed-off-by: Christian Borntraeger Reviewed-by: David Hildenbrand --- target/s390x/cpu_features.c | 1 + target/s390x/cpu_features_def.h | 1 + 2 files changed, 2 insertions(+) diff --git a/target/s390x/cpu_features.c b/target/s390x/cpu_features.c index 1843c84aaa..bbd8902087 100644 --- a/target/s390x/cpu_features.c +++ b/target/s390x/cpu_features.c @@ -83,6 +83,7 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("minste2", S390_FEAT_TYPE_STFL, 58, "Miscellaneous-instructi= on-extensions facility 2"), FEAT_INIT("sema", S390_FEAT_TYPE_STFL, 59, "Semaphore-assist facility"= ), FEAT_INIT("tsi", S390_FEAT_TYPE_STFL, 60, "Time-slice Instrumentation = facility"), + FEAT_INIT("minste3", S390_FEAT_TYPE_STFL, 61, "Miscellaneous-Instructi= on-Extensions Facility 3"), FEAT_INIT("ri", S390_FEAT_TYPE_STFL, 64, "CPU runtime-instrumentation = facility"), FEAT_INIT("zpci", S390_FEAT_TYPE_STFL, 69, "z/PCI facility"), FEAT_INIT("aen", S390_FEAT_TYPE_STFL, 71, "General-purpose-adapter-eve= nt-notification facility"), diff --git a/target/s390x/cpu_features_def.h b/target/s390x/cpu_features_de= f.h index 5fc7e7bf01..31dd678301 100644 --- a/target/s390x/cpu_features_def.h +++ b/target/s390x/cpu_features_def.h @@ -71,6 +71,7 @@ typedef enum { S390_FEAT_MISC_INSTRUCTION_EXT, S390_FEAT_SEMAPHORE_ASSIST, S390_FEAT_TIME_SLICE_INSTRUMENTATION, + S390_FEAT_MISC_INSTRUCTION_EXT3, S390_FEAT_RUNTIME_INSTRUMENTATION, S390_FEAT_ZPCI, S390_FEAT_ADAPTER_EVENT_NOTIFICATION, --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: temperror (zoho.com: Error in retrieving data from DNS) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=temperror (zoho.com: Error in retrieving data from DNS) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587678; cv=none; d=zoho.com; s=zohoarc; b=AGWwrFX7zBqcyYOIdSXzWt8WjpTWrJutscJVs5D3AnyOervVN60euTHPGx97JHNDvAjy8gPjFy1Fh0O0V8wlA0+gHatVO5cgSsnx+WVdQxWNrgSWaLsxjo1vyvlLhqlsHFa8dMsLZeb5WRF6QiEa5NM3OVqrDnIY41DsLZ1Bdfo= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587678; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=/7vC/dZOmBGfjkOZQr9icGqM4xHaP+B1hXjeM04AXMA=; b=GQcFgNG5K3ekxh5uNoCu+CQhBW7t7d6VL1eennJs50l1HvRDalyxDgASkRwW75Ei23dyYZjHkcX52v2EulkOoJW1Wtv/7NIzACKJSb77+QVz6psYhayrEIOFCBKVFhVQ8FnrQ505hHc1+4BooaWmaQuKQoXZK7LZ1giHs8TwN6k= ARC-Authentication-Results: i=1; mx.zoho.com; spf=temperror (zoho.com: Error in retrieving data from DNS) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1555587678941166.51258239999856; Thu, 18 Apr 2019 04:41:18 -0700 (PDT) Received: from localhost ([127.0.0.1]:39950 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5Pe-0001N5-Rf for importer@patchew.org; Thu, 18 Apr 2019 07:41:06 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50800) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GK-0002nZ-Sz for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:30 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GG-0004YL-FP for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:28 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:45248 helo=mx0a-001b2d01.pphosted.com) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GG-0004PP-AK for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:24 -0400 Received: from pps.filterd (m0098417.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBTVrO033417 for ; Thu, 18 Apr 2019 07:31:19 -0400 Received: from e06smtp01.uk.ibm.com (e06smtp01.uk.ibm.com [195.75.94.97]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxq86369k-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:18 -0400 Received: from localhost by e06smtp01.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:16 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (9.149.109.198) 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, 18 Apr 2019 12:31:14 +0100 Received: from d06av23.portsmouth.uk.ibm.com (d06av23.portsmouth.uk.ibm.com [9.149.105.59]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVCwv41943062 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:12 GMT Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 9BD73A4053; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 80875A405B; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av23.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 423C320F639; Thu, 18 Apr 2019 13:31:12 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:04 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-4275-0000-0000-000003293A18 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-4276-0000-0000-000038387323 Message-Id: <20190418113110.160664-5-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.158.5 Subject: [Qemu-devel] [PATCH 04/10] s390x/cpumodel: msa9 facility X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" Provide the MSA9 facility (stfle.155). This also contains pckmo functions for key wrapping. Keep them in a separate group to allow disabling/enabling those as a block if necessary. Signed-off-by: Christian Borntraeger --- target/s390x/cpu_features.c | 32 +++++++++++++++++++++++++ target/s390x/cpu_features.h | 1 + target/s390x/cpu_features_def.h | 31 ++++++++++++++++++++++++ target/s390x/cpu_models.c | 1 + target/s390x/gen-features.c | 42 +++++++++++++++++++++++++++++++++ target/s390x/kvm.c | 6 +++++ 6 files changed, 113 insertions(+) diff --git a/target/s390x/cpu_features.c b/target/s390x/cpu_features.c index bbd8902087..4d624b2256 100644 --- a/target/s390x/cpu_features.c +++ b/target/s390x/cpu_features.c @@ -108,6 +108,7 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("irbm", S390_FEAT_TYPE_STFL, 145, "Insert-reference-bits-mul= tiple facility"), FEAT_INIT("msa8-base", S390_FEAT_TYPE_STFL, 146, "Message-security-ass= ist-extension-8 facility (excluding subfunctions)"), FEAT_INIT("cmmnt", S390_FEAT_TYPE_STFL, 147, "CMM: ESSA-enhancement (n= o translate) facility"), + FEAT_INIT("msa9-base", S390_FEAT_TYPE_STFL, 155, "Message-security-ass= ist-extension-9 facility (excluding subfunctions)"), FEAT_INIT("etoken", S390_FEAT_TYPE_STFL, 156, "Etoken facility"), =20 /* SCLP SCCB Byte 80 - 98 (bit numbers relative to byte-80) */ @@ -242,6 +243,11 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("pckmo-aes-128", S390_FEAT_TYPE_PCKMO, 18, "PCKMO Encrypted-= AES-128-Key"), FEAT_INIT("pckmo-aes-192", S390_FEAT_TYPE_PCKMO, 19, "PCKMO Encrypted-= AES-192-Key"), FEAT_INIT("pckmo-aes-256", S390_FEAT_TYPE_PCKMO, 20, "PCKMO Encrypted-= AES-256-Key"), + FEAT_INIT("pckmo-ecc-p256", S390_FEAT_TYPE_PCKMO,32, "PCKMO Encrypt-EC= C-P256-Key"), + FEAT_INIT("pckmo-ecc-p384", S390_FEAT_TYPE_PCKMO,33, "PCKMO Encrypt-EC= C-P384-Key"), + FEAT_INIT("pckmo-ecc-p521", S390_FEAT_TYPE_PCKMO,34, "PCKMO Encrypt-EC= C-P521-Key"), + FEAT_INIT("pckmo-ecc-ed25519", S390_FEAT_TYPE_PCKMO,40 , "PCKMO Encryp= t-ECC-Ed25519-Key"), + FEAT_INIT("pckmo-ecc-ed448", S390_FEAT_TYPE_PCKMO,41 , "PCKMO Encrypt-= ECC-Ed448-Key"), =20 FEAT_INIT("kmctr-dea", S390_FEAT_TYPE_KMCTR, 1, "KMCTR DEA"), FEAT_INIT("kmctr-tdea-128", S390_FEAT_TYPE_KMCTR, 2, "KMCTR TDEA-128"), @@ -298,6 +304,13 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("pcc-xts-aes-256", S390_FEAT_TYPE_PCC, 52, "PCC Compute-XTS-= Parameter-Using-AES-256"), FEAT_INIT("pcc-xts-eaes-128", S390_FEAT_TYPE_PCC, 58, "PCC Compute-XTS= -Parameter-Using-Encrypted-AES-128"), FEAT_INIT("pcc-xts-eaes-256", S390_FEAT_TYPE_PCC, 60, "PCC Compute-XTS= -Parameter-Using-Encrypted-AES-256"), + FEAT_INIT("pcc-scalar-mult-p256", S390_FEAT_TYPE_PCC, 64, "PCC Scalar-= Multiply-P256"), + FEAT_INIT("pcc-scalar-mult-p384", S390_FEAT_TYPE_PCC, 65, "PCC Scalar-= Multiply-P384"), + FEAT_INIT("pcc-scalar-mult-p521", S390_FEAT_TYPE_PCC, 66, "PCC Scalar-= Multiply-P521"), + FEAT_INIT("pcc-scalar-mult-ed25519", S390_FEAT_TYPE_PCC, 72, "PCC Scal= ar-Multiply-Ed25519"), + FEAT_INIT("pcc-scalar-mult-ed448", S390_FEAT_TYPE_PCC, 73, "PCC Scalar= -Multiply-Ed448"), + FEAT_INIT("pcc-scalar-mult-x25519", S390_FEAT_TYPE_PCC, 80, "PCC Scala= r-Multiply-X25519"), + FEAT_INIT("pcc-scalar-mult-x448", S390_FEAT_TYPE_PCC, 81, "PCC Scalar-= Multiply-X448"), =20 FEAT_INIT("ppno-sha-512-drng", S390_FEAT_TYPE_PPNO, 3, "PPNO SHA-512-D= RNG"), FEAT_INIT("prno-trng-qrtcr", S390_FEAT_TYPE_PPNO, 112, "PRNO TRNG-Quer= y-Raw-to-Conditioned-Ratio"), @@ -309,6 +322,22 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("kma-gcm-eaes-128", S390_FEAT_TYPE_KMA, 26, "KMA GCM-Encrypt= ed-AES-128"), FEAT_INIT("kma-gcm-eaes-192", S390_FEAT_TYPE_KMA, 27, "KMA GCM-Encrypt= ed-AES-192"), FEAT_INIT("kma-gcm-eaes-256", S390_FEAT_TYPE_KMA, 28, "KMA GCM-Encrypt= ed-AES-256"), + + FEAT_INIT("kdsa-ecdsa-verify-p256", S390_FEAT_TYPE_KDSA, 1, "KDSA ECDS= A-Verify-P256"), + FEAT_INIT("kdsa-ecdsa-verify-p384", S390_FEAT_TYPE_KDSA, 2, "KDSA ECDS= A-Verify-P384"), + FEAT_INIT("kdsa-ecdsa-verify-p521", S390_FEAT_TYPE_KDSA, 3, "KDSA ECDS= A-Verify-P521"), + FEAT_INIT("kdsa-ecdsa-sign-p256", S390_FEAT_TYPE_KDSA, 9, "KDSA ECDSA-= Sign-P256"), + FEAT_INIT("kdsa-ecdsa-sign-p384", S390_FEAT_TYPE_KDSA, 10, "KDSA ECDSA= -Sign-P384"), + FEAT_INIT("kdsa-ecdsa-sign-p521", S390_FEAT_TYPE_KDSA, 11, "KDSA ECDSA= -Sign-P521"), + FEAT_INIT("kdsa-eecdsa-sign-p256", S390_FEAT_TYPE_KDSA, 17, "KDSA Encr= ypted-ECDSA-Sign-P256"), + FEAT_INIT("kdsa-eecdsa-sign-p384", S390_FEAT_TYPE_KDSA, 18, "KDSA Encr= ypted-ECDSA-Sign-P384"), + FEAT_INIT("kdsa-eecdsa-sign-p521", S390_FEAT_TYPE_KDSA, 19, "KDSA Encr= ypted-ECDSA-Sign-P521"), + FEAT_INIT("kdsa-eddsa-verify-ed25519", S390_FEAT_TYPE_KDSA, 32, "KDSA = EdDSA-Verify-Ed25519"), + FEAT_INIT("kdsa-eddsa-verify-ed448", S390_FEAT_TYPE_KDSA, 36, "KDSA Ed= DSA-Verify-Ed448"), + FEAT_INIT("kdsa-eddsa-sign-ed25519", S390_FEAT_TYPE_KDSA, 40, "KDSA Ed= DSA-Sign-Ed25519"), + FEAT_INIT("kdsa-eddsa-sign-ed448", S390_FEAT_TYPE_KDSA, 44, "KDSA EdDS= A-Sign-Ed448"), + FEAT_INIT("kdsa-eeddsa-sign-ed25519", S390_FEAT_TYPE_KDSA, 48, "KDSA E= ncrypted-EdDSA-Sign-Ed25519"), + FEAT_INIT("kdsa-eeddsa-sign-ed448", S390_FEAT_TYPE_KDSA, 52, "KDSA Enc= rypted-EdDSA-Sign-Ed448"), }; =20 const S390FeatDef *s390_feat_def(S390Feat feat) @@ -371,6 +400,7 @@ void s390_fill_feat_block(const S390FeatBitmap features= , S390FeatType type, case S390_FEAT_TYPE_PCC: case S390_FEAT_TYPE_PPNO: case S390_FEAT_TYPE_KMA: + case S390_FEAT_TYPE_KDSA: set_be_bit(0, data); /* query is always available */ break; default: @@ -466,6 +496,8 @@ static S390FeatGroupDef s390_feature_groups[] =3D { FEAT_GROUP_INIT("msa6", MSA_EXT_6, "Message-security-assist-extension = 6 facility"), FEAT_GROUP_INIT("msa7", MSA_EXT_7, "Message-security-assist-extension = 7 facility"), FEAT_GROUP_INIT("msa8", MSA_EXT_8, "Message-security-assist-extension = 8 facility"), + FEAT_GROUP_INIT("msa9", MSA_EXT_9, "Message-security-assist-extension = 9 facility"), + FEAT_GROUP_INIT("msa9_pckmo", MSA_EXT_9_PCKMO, "Message-security-assis= t-extension 9 PCKMO subfunctions"), FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements = introduced with Multiple-epoch facility"), }; =20 diff --git a/target/s390x/cpu_features.h b/target/s390x/cpu_features.h index effe790271..5ffd3db083 100644 --- a/target/s390x/cpu_features.h +++ b/target/s390x/cpu_features.h @@ -39,6 +39,7 @@ typedef enum { S390_FEAT_TYPE_PCC, S390_FEAT_TYPE_PPNO, S390_FEAT_TYPE_KMA, + S390_FEAT_TYPE_KDSA, } S390FeatType; =20 /* Definition of a CPU feature */ diff --git a/target/s390x/cpu_features_def.h b/target/s390x/cpu_features_de= f.h index 31dd678301..030784811b 100644 --- a/target/s390x/cpu_features_def.h +++ b/target/s390x/cpu_features_def.h @@ -96,6 +96,7 @@ typedef enum { S390_FEAT_INSERT_REFERENCE_BITS_MULT, S390_FEAT_MSA_EXT_8, S390_FEAT_CMM_NT, + S390_FEAT_MSA_EXT_9, S390_FEAT_ETOKEN, =20 /* Sclp Conf Char */ @@ -240,6 +241,11 @@ typedef enum { S390_FEAT_PCKMO_AES_128, S390_FEAT_PCKMO_AES_192, S390_FEAT_PCKMO_AES_256, + S390_FEAT_PCKMO_ECC_P256, + S390_FEAT_PCKMO_ECC_P384, + S390_FEAT_PCKMO_ECC_P521, + S390_FEAT_PCKMO_ECC_ED25519, + S390_FEAT_PCKMO_ECC_ED448, =20 /* KMCTR */ S390_FEAT_KMCTR_DEA, @@ -300,6 +306,13 @@ typedef enum { S390_FEAT_PCC_XTS_AES_256, S390_FEAT_PCC_XTS_EAES_128, S390_FEAT_PCC_XTS_EAES_256, + S390_FEAT_PCC_SCALAR_MULT_P256, + S390_FEAT_PCC_SCALAR_MULT_P384, + S390_FEAT_PCC_SCALAR_MULT_P512, + S390_FEAT_PCC_SCALAR_MULT_ED25519, + S390_FEAT_PCC_SCALAR_MULT_ED448, + S390_FEAT_PCC_SCALAR_MULT_X25519, + S390_FEAT_PCC_SCALAR_MULT_X448, =20 /* PPNO/PRNO */ S390_FEAT_PPNO_SHA_512_DRNG, @@ -313,6 +326,24 @@ typedef enum { S390_FEAT_KMA_GCM_EAES_128, S390_FEAT_KMA_GCM_EAES_192, S390_FEAT_KMA_GCM_EAES_256, + + /* KDSA */ + S390_FEAT_ECDSA_VERIFY_P256, + S390_FEAT_ECDSA_VERIFY_P384, + S390_FEAT_ECDSA_VERIFY_P512, + S390_FEAT_ECDSA_SIGN_P256, + S390_FEAT_ECDSA_SIGN_P384, + S390_FEAT_ECDSA_SIGN_P512, + S390_FEAT_EECDSA_SIGN_P256, + S390_FEAT_EECDSA_SIGN_P384, + S390_FEAT_EECDSA_SIGN_P512, + S390_FEAT_EDDSA_VERIFY_ED25519, + S390_FEAT_EDDSA_VERIFY_ED448, + S390_FEAT_EDDSA_SIGN_ED25519, + S390_FEAT_EDDSA_SIGN_ED448, + S390_FEAT_EEDDSA_SIGN_ED25519, + S390_FEAT_EEDDSA_SIGN_ED448, + S390_FEAT_MAX, } S390Feat; =20 diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c index 4e5aa879f3..4c355e936e 100644 --- a/target/s390x/cpu_models.c +++ b/target/s390x/cpu_models.c @@ -808,6 +808,7 @@ static void check_consistency(const S390CPUModel *model) { S390_FEAT_SIE_CMMA, S390_FEAT_SIE_GSLS }, { S390_FEAT_SIE_PFMFI, S390_FEAT_EDAT }, { S390_FEAT_MSA_EXT_8, S390_FEAT_MSA_EXT_3 }, + { S390_FEAT_MSA_EXT_9, S390_FEAT_MSA_EXT_3 }, { S390_FEAT_MULTIPLE_EPOCH, S390_FEAT_TOD_CLOCK_STEERING }, { S390_FEAT_VECTOR_PACKED_DECIMAL, S390_FEAT_VECTOR }, { S390_FEAT_VECTOR_ENH, S390_FEAT_VECTOR }, diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c index bea2f80c49..64fe850ff2 100644 --- a/target/s390x/gen-features.c +++ b/target/s390x/gen-features.c @@ -213,6 +213,38 @@ S390_FEAT_KMA_GCM_EAES_192, \ S390_FEAT_KMA_GCM_EAES_256 =20 +#define S390_FEAT_GROUP_MSA_EXT_9 \ + S390_FEAT_MSA_EXT_9, \ + S390_FEAT_ECDSA_VERIFY_P256, \ + S390_FEAT_ECDSA_VERIFY_P384, \ + S390_FEAT_ECDSA_VERIFY_P512, \ + S390_FEAT_ECDSA_SIGN_P256, \ + S390_FEAT_ECDSA_SIGN_P384, \ + S390_FEAT_ECDSA_SIGN_P512, \ + S390_FEAT_EECDSA_SIGN_P256, \ + S390_FEAT_EECDSA_SIGN_P384, \ + S390_FEAT_EECDSA_SIGN_P512, \ + S390_FEAT_EDDSA_VERIFY_ED25519, \ + S390_FEAT_EDDSA_VERIFY_ED448, \ + S390_FEAT_EDDSA_SIGN_ED25519, \ + S390_FEAT_EDDSA_SIGN_ED448, \ + S390_FEAT_EEDDSA_SIGN_ED25519, \ + S390_FEAT_EEDDSA_SIGN_ED448, \ + S390_FEAT_PCC_SCALAR_MULT_P256, \ + S390_FEAT_PCC_SCALAR_MULT_P384, \ + S390_FEAT_PCC_SCALAR_MULT_P512, \ + S390_FEAT_PCC_SCALAR_MULT_ED25519, \ + S390_FEAT_PCC_SCALAR_MULT_ED448, \ + S390_FEAT_PCC_SCALAR_MULT_X25519, \ + S390_FEAT_PCC_SCALAR_MULT_X448 + +#define S390_FEAT_GROUP_MSA_EXT_9_PCKMO \ + S390_FEAT_PCKMO_ECC_P256, \ + S390_FEAT_PCKMO_ECC_P384, \ + S390_FEAT_PCKMO_ECC_P521, \ + S390_FEAT_PCKMO_ECC_ED25519, \ + S390_FEAT_PCKMO_ECC_ED448 + /* cpu feature groups */ static uint16_t group_PLO[] =3D { S390_FEAT_GROUP_PLO, @@ -254,6 +286,14 @@ static uint16_t group_MSA_EXT_8[] =3D { S390_FEAT_GROUP_MSA_EXT_8, }; =20 +static uint16_t group_MSA_EXT_9[] =3D { + S390_FEAT_GROUP_MSA_EXT_9, +}; + +static uint16_t group_MSA_EXT_9_PCKMO[] =3D { + S390_FEAT_GROUP_MSA_EXT_9_PCKMO, +}; + /* Base features (in order of release) * Only non-hypervisor managed features belong here. * Base feature sets are static meaning they do not change in future QEMU @@ -708,6 +748,8 @@ static FeatGroupDefSpec FeatGroupDef[] =3D { FEAT_GROUP_INITIALIZER(MSA_EXT_6), FEAT_GROUP_INITIALIZER(MSA_EXT_7), FEAT_GROUP_INITIALIZER(MSA_EXT_8), + FEAT_GROUP_INITIALIZER(MSA_EXT_9), + FEAT_GROUP_INITIALIZER(MSA_EXT_9_PCKMO), FEAT_GROUP_INITIALIZER(MULTIPLE_EPOCH_PTFF), }; =20 diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c index 19530fb94e..88cef3476c 100644 --- a/target/s390x/kvm.c +++ b/target/s390x/kvm.c @@ -2080,6 +2080,9 @@ static int query_cpu_subfunc(S390FeatBitmap features) if (test_bit(S390_FEAT_MSA_EXT_8, features)) { s390_add_from_feat_block(features, S390_FEAT_TYPE_KMA, prop.kma); } + if (test_bit(S390_FEAT_MSA_EXT_9, features)) { + s390_add_from_feat_block(features, S390_FEAT_TYPE_KDSA, prop.kdsa); + } return 0; } =20 @@ -2124,6 +2127,9 @@ static int configure_cpu_subfunc(const S390FeatBitmap= features) if (test_bit(S390_FEAT_MSA_EXT_8, features)) { s390_fill_feat_block(features, S390_FEAT_TYPE_KMA, prop.kma); } + if (test_bit(S390_FEAT_MSA_EXT_9, features)) { + s390_fill_feat_block(features, S390_FEAT_TYPE_KDSA, prop.kdsa); + } return kvm_vm_ioctl(kvm_state, KVM_SET_DEVICE_ATTR, &attr); } =20 --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587222; cv=none; d=zoho.com; s=zohoarc; b=axY1VjCP9I/vSmwZXFlehLeyVqvGNnJ1oqLx4D4NPxRhKPZNQnxyM7UrebSdV8viY5C4ZfxafLR0dB+X+U9irERQTlms2DWrefj+WQfEdnRpx1TewQX1be2Hypok6Pr1nRk0eMJ+7Q+KpvXjaOwS3qLO5307tlqUXF7uDvtShYQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587222; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=X2TpVKxtbKEv4NT0bddFTkOK+JEx925CMmlTVJlQZ3g=; b=kdJf4h//Gc8Nx9ojLBM/03RL0wMTVFq1Rv3f6XlwrIeaXn4za7HdiLNjHCYJMLt43fTmPm0/kumDl0QccfYxMW3IATOkmWksciWmKcUlUc+zIeZ5SuTo9LfsxsyTfaCGplAoXeVOy1hQ91BBZ6xnoPBm/gAEoqJKULBbxnEhYmQ= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1555587222015948.4845546154544; Thu, 18 Apr 2019 04:33:42 -0700 (PDT) Received: from localhost ([127.0.0.1]:39810 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5IQ-0003zW-2C for importer@patchew.org; Thu, 18 Apr 2019 07:33:38 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50655) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GH-0002ju-3g for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GF-0004Vr-GN for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:24 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:58796) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GF-0004Tj-3v for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:23 -0400 Received: from pps.filterd (m0098399.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBTROo147148 for ; Thu, 18 Apr 2019 07:31:20 -0400 Received: from e06smtp03.uk.ibm.com (e06smtp03.uk.ibm.com [195.75.94.99]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxq8239r7-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:19 -0400 Received: from localhost by e06smtp03.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:17 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (9.149.109.198) by e06smtp03.uk.ibm.com (192.168.101.133) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 18 Apr 2019 12:31:14 +0100 Received: from d06av23.portsmouth.uk.ibm.com (d06av23.portsmouth.uk.ibm.com [9.149.105.59]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVCRP38666444 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:13 GMT Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id D4FB9A405D; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id C224BA4055; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av23.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 18 Apr 2019 11:31:12 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 8446A20F63B; Thu, 18 Apr 2019 13:31:12 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:05 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-0012-0000-0000-000003103181 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-0013-0000-0000-0000214873C7 Message-Id: <20190418113110.160664-6-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.156.1 Subject: [Qemu-devel] [PATCH 05/10] s390x/cpumodel: vector enhancements X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" Add vector enhancements to the cpu model. Signed-off-by: Christian Borntraeger Reviewed-by: David Hildenbrand --- target/s390x/cpu_features.c | 2 ++ target/s390x/cpu_features_def.h | 2 ++ 2 files changed, 4 insertions(+) diff --git a/target/s390x/cpu_features.c b/target/s390x/cpu_features.c index 4d624b2256..ed3f6aa969 100644 --- a/target/s390x/cpu_features.c +++ b/target/s390x/cpu_features.c @@ -108,6 +108,8 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("irbm", S390_FEAT_TYPE_STFL, 145, "Insert-reference-bits-mul= tiple facility"), FEAT_INIT("msa8-base", S390_FEAT_TYPE_STFL, 146, "Message-security-ass= ist-extension-8 facility (excluding subfunctions)"), FEAT_INIT("cmmnt", S390_FEAT_TYPE_STFL, 147, "CMM: ESSA-enhancement (n= o translate) facility"), + FEAT_INIT("vxeh2", S390_FEAT_TYPE_STFL, 148, "Vector Enhancements faci= lity 2"), + FEAT_INIT("vxbeh", S390_FEAT_TYPE_STFL, 152, "Vector BCD enhancements = facility 1"), FEAT_INIT("msa9-base", S390_FEAT_TYPE_STFL, 155, "Message-security-ass= ist-extension-9 facility (excluding subfunctions)"), FEAT_INIT("etoken", S390_FEAT_TYPE_STFL, 156, "Etoken facility"), =20 diff --git a/target/s390x/cpu_features_def.h b/target/s390x/cpu_features_de= f.h index 030784811b..ce2223c9d7 100644 --- a/target/s390x/cpu_features_def.h +++ b/target/s390x/cpu_features_def.h @@ -96,6 +96,8 @@ typedef enum { S390_FEAT_INSERT_REFERENCE_BITS_MULT, S390_FEAT_MSA_EXT_8, S390_FEAT_CMM_NT, + S390_FEAT_VECTOR_ENH2, + S390_FEAT_VECTOR_BCD_ENH, S390_FEAT_MSA_EXT_9, S390_FEAT_ETOKEN, =20 --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587637; cv=none; d=zoho.com; s=zohoarc; b=TaFYik71T27gfugXNc9RyrdQ7+u8H+QTATtYR1m64ZbYQrtLPWJDiYwpmySv29Azdk9nci/XP1BviELSzQoCm0i/jQA3oSgvsV4WnGvG6HkIgkV3Vqv8ogp1fxsb08GhLPlgBqMmA3RJCZ8i1AnbqoObj+abNOCvBsp2RxJlYCA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587637; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=VQS7/KKmSP1nqtsmjrPKjAPg/hi8ohszvgBGnk9DEmc=; b=oSIHmHI7uAauCgQa4gAD9iSQuBTL8L1yJtfNyzYoNVRPyA7+4/eR7AbyUN1IysD4EOZ2+O9Fm1dEAP4se9BwNrWnIyXZX0qvJy7phZrkEwi0qBJ0vyANLZPzUXehekFdNu+FEYi+hlTbU2FzZKs3FV4S1L/LAd4hikroaX5qjj0= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1555587637603848.1553181797537; Thu, 18 Apr 2019 04:40:37 -0700 (PDT) Received: from localhost ([127.0.0.1]:39936 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5P7-0000ud-IM for importer@patchew.org; Thu, 18 Apr 2019 07:40:33 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50683) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GH-0002kZ-RG for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GF-0004WI-LI for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:25 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:37664) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GF-0004TZ-43 for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:23 -0400 Received: from pps.filterd (m0098409.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBUVGE130071 for ; Thu, 18 Apr 2019 07:31:20 -0400 Received: from e06smtp05.uk.ibm.com (e06smtp05.uk.ibm.com [195.75.94.101]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxqjrtc4g-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:19 -0400 Received: from localhost by e06smtp05.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:17 +0100 Received: from b06cxnps4074.portsmouth.uk.ibm.com (9.149.109.196) by e06smtp05.uk.ibm.com (192.168.101.135) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 18 Apr 2019 12:31:14 +0100 Received: from d06av25.portsmouth.uk.ibm.com (d06av25.portsmouth.uk.ibm.com [9.149.105.61]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVD7w49414398 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:13 GMT Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 2713911C06F; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 1576611C064; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av25.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id C8D0420F639; Thu, 18 Apr 2019 13:31:12 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:06 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-0020-0000-0000-0000033130D8 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-0021-0000-0000-00002183810C Message-Id: <20190418113110.160664-7-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.156.1 Subject: [Qemu-devel] [PATCH 06/10] s390x/cpumodel: enhanced sort facility X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" add the enhanced sort facility. Signed-off-by: Christian Borntraeger Reviewed-by: David Hildenbrand --- target/s390x/cpu_features.c | 10 ++++++++++ target/s390x/cpu_features.h | 1 + target/s390x/cpu_features_def.h | 8 ++++++++ target/s390x/gen-features.c | 14 ++++++++++++++ target/s390x/kvm.c | 6 ++++++ 5 files changed, 39 insertions(+) diff --git a/target/s390x/cpu_features.c b/target/s390x/cpu_features.c index ed3f6aa969..e0a4769c19 100644 --- a/target/s390x/cpu_features.c +++ b/target/s390x/cpu_features.c @@ -109,6 +109,7 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("msa8-base", S390_FEAT_TYPE_STFL, 146, "Message-security-ass= ist-extension-8 facility (excluding subfunctions)"), FEAT_INIT("cmmnt", S390_FEAT_TYPE_STFL, 147, "CMM: ESSA-enhancement (n= o translate) facility"), FEAT_INIT("vxeh2", S390_FEAT_TYPE_STFL, 148, "Vector Enhancements faci= lity 2"), + FEAT_INIT("esort-base", S390_FEAT_TYPE_STFL, 150, "Enhanced-sort facil= ity (excluding subfunctions)"), FEAT_INIT("vxbeh", S390_FEAT_TYPE_STFL, 152, "Vector BCD enhancements = facility 1"), FEAT_INIT("msa9-base", S390_FEAT_TYPE_STFL, 155, "Message-security-ass= ist-extension-9 facility (excluding subfunctions)"), FEAT_INIT("etoken", S390_FEAT_TYPE_STFL, 156, "Etoken facility"), @@ -340,6 +341,12 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("kdsa-eddsa-sign-ed448", S390_FEAT_TYPE_KDSA, 44, "KDSA EdDS= A-Sign-Ed448"), FEAT_INIT("kdsa-eeddsa-sign-ed25519", S390_FEAT_TYPE_KDSA, 48, "KDSA E= ncrypted-EdDSA-Sign-Ed25519"), FEAT_INIT("kdsa-eeddsa-sign-ed448", S390_FEAT_TYPE_KDSA, 52, "KDSA Enc= rypted-EdDSA-Sign-Ed448"), + + FEAT_INIT("sortl-sflr", S390_FEAT_TYPE_SORTL, 1, "SORTL SFLR"), + FEAT_INIT("sortl-svlr", S390_FEAT_TYPE_SORTL, 2, "SORTL SVLR"), + FEAT_INIT("sortl-32", S390_FEAT_TYPE_SORTL, 130, "SORTL 32 input lists= "), + FEAT_INIT("sortl-128", S390_FEAT_TYPE_SORTL, 132, "SORTL 128 input lis= ts"), + FEAT_INIT("sortl-f0", S390_FEAT_TYPE_SORTL, 192, "SORTL format 0 param= eter-block"), }; =20 const S390FeatDef *s390_feat_def(S390Feat feat) @@ -403,6 +410,7 @@ void s390_fill_feat_block(const S390FeatBitmap features= , S390FeatType type, case S390_FEAT_TYPE_PPNO: case S390_FEAT_TYPE_KMA: case S390_FEAT_TYPE_KDSA: + case S390_FEAT_TYPE_SORTL: set_be_bit(0, data); /* query is always available */ break; default: @@ -430,6 +438,7 @@ void s390_add_from_feat_block(S390FeatBitmap features, = S390FeatType type, nr_bits =3D 16384; break; case S390_FEAT_TYPE_PLO: + case S390_FEAT_TYPE_SORTL: nr_bits =3D 256; break; default: @@ -501,6 +510,7 @@ static S390FeatGroupDef s390_feature_groups[] =3D { FEAT_GROUP_INIT("msa9", MSA_EXT_9, "Message-security-assist-extension = 9 facility"), FEAT_GROUP_INIT("msa9_pckmo", MSA_EXT_9_PCKMO, "Message-security-assis= t-extension 9 PCKMO subfunctions"), FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements = introduced with Multiple-epoch facility"), + FEAT_GROUP_INIT("esort", ENH_SORT, "Enhanced-sort facility"), }; =20 const S390FeatGroupDef *s390_feat_group_def(S390FeatGroup group) diff --git a/target/s390x/cpu_features.h b/target/s390x/cpu_features.h index 5ffd3db083..3b8c5b25dd 100644 --- a/target/s390x/cpu_features.h +++ b/target/s390x/cpu_features.h @@ -40,6 +40,7 @@ typedef enum { S390_FEAT_TYPE_PPNO, S390_FEAT_TYPE_KMA, S390_FEAT_TYPE_KDSA, + S390_FEAT_TYPE_SORTL, } S390FeatType; =20 /* Definition of a CPU feature */ diff --git a/target/s390x/cpu_features_def.h b/target/s390x/cpu_features_de= f.h index ce2223c9d7..bb8585847f 100644 --- a/target/s390x/cpu_features_def.h +++ b/target/s390x/cpu_features_def.h @@ -97,6 +97,7 @@ typedef enum { S390_FEAT_MSA_EXT_8, S390_FEAT_CMM_NT, S390_FEAT_VECTOR_ENH2, + S390_FEAT_ESORT_BASE, S390_FEAT_VECTOR_BCD_ENH, S390_FEAT_MSA_EXT_9, S390_FEAT_ETOKEN, @@ -346,6 +347,13 @@ typedef enum { S390_FEAT_EEDDSA_SIGN_ED25519, S390_FEAT_EEDDSA_SIGN_ED448, =20 + /* SORTL */ + S390_FEAT_SORTL_SFLR, + S390_FEAT_SORTL_SVLR, + S390_FEAT_SORTL_32, + S390_FEAT_SORTL_128, + S390_FEAT_SORTL_F0, + S390_FEAT_MAX, } S390Feat; =20 diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c index 64fe850ff2..3db323fc0c 100644 --- a/target/s390x/gen-features.c +++ b/target/s390x/gen-features.c @@ -245,6 +245,15 @@ S390_FEAT_PCKMO_ECC_ED25519, \ S390_FEAT_PCKMO_ECC_ED448 =20 +#define S390_FEAT_GROUP_ENH_SORT \ + S390_FEAT_ESORT_BASE, \ + S390_FEAT_SORTL_SFLR, \ + S390_FEAT_SORTL_SVLR, \ + S390_FEAT_SORTL_32, \ + S390_FEAT_SORTL_128, \ + S390_FEAT_SORTL_F0 + + /* cpu feature groups */ static uint16_t group_PLO[] =3D { S390_FEAT_GROUP_PLO, @@ -294,6 +303,10 @@ static uint16_t group_MSA_EXT_9_PCKMO[] =3D { S390_FEAT_GROUP_MSA_EXT_9_PCKMO, }; =20 +static uint16_t group_ENH_SORT[] =3D { + S390_FEAT_GROUP_ENH_SORT, +}; + /* Base features (in order of release) * Only non-hypervisor managed features belong here. * Base feature sets are static meaning they do not change in future QEMU @@ -751,6 +764,7 @@ static FeatGroupDefSpec FeatGroupDef[] =3D { FEAT_GROUP_INITIALIZER(MSA_EXT_9), FEAT_GROUP_INITIALIZER(MSA_EXT_9_PCKMO), FEAT_GROUP_INITIALIZER(MULTIPLE_EPOCH_PTFF), + FEAT_GROUP_INITIALIZER(ENH_SORT), }; =20 #define QEMU_FEAT_INITIALIZER(_name) \ diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c index 88cef3476c..7681492c41 100644 --- a/target/s390x/kvm.c +++ b/target/s390x/kvm.c @@ -2083,6 +2083,9 @@ static int query_cpu_subfunc(S390FeatBitmap features) if (test_bit(S390_FEAT_MSA_EXT_9, features)) { s390_add_from_feat_block(features, S390_FEAT_TYPE_KDSA, prop.kdsa); } + if (test_bit(S390_FEAT_ESORT_BASE, features)) { + s390_add_from_feat_block(features, S390_FEAT_TYPE_SORTL, prop.sort= l); + } return 0; } =20 @@ -2130,6 +2133,9 @@ static int configure_cpu_subfunc(const S390FeatBitmap= features) if (test_bit(S390_FEAT_MSA_EXT_9, features)) { s390_fill_feat_block(features, S390_FEAT_TYPE_KDSA, prop.kdsa); } + if (test_bit(S390_FEAT_ESORT_BASE, features)) { + s390_fill_feat_block(features, S390_FEAT_TYPE_SORTL, prop.sortl); + } return kvm_vm_ioctl(kvm_state, KVM_SET_DEVICE_ATTR, &attr); } =20 --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: temperror (zoho.com: Error in retrieving data from DNS) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=temperror (zoho.com: Error in retrieving data from DNS) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587362; cv=none; d=zoho.com; s=zohoarc; b=hwRh5lbEOovQNAeceVhfLE/zpDnyI+Fd9chDdgDLidnzlQEX0qTM/ffvFBL4WRUx7VjXGZ2faI+knHx7tZPpYRaib9zr847kaGpnrsCXq8uaErHhbWebVqXbzD7mX8bVt8jI3lWfHbR7QwxjuODqze1MfIfIBzJwTSqp1N266/w= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587362; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=WF4NG3HCo0FglibUQRTZCA/aPAvdD7Mi7MZeR3uQEow=; b=OM1ZPSLP7vYz2F6um5WiR6GUsMfx05eOoTeYjSrdRQ7FvMYcS4zTNqZp0baM3m7/1GPtDh+GNWw2ley9xNE695Y1U+zng74VMGr2NWdPpxKwi7GLhx1WtIJw4pjIoA4BnHoMToa213+ScGA8p51IsvDngHWLnq0efgJBqkKJVe0= ARC-Authentication-Results: i=1; mx.zoho.com; spf=temperror (zoho.com: Error in retrieving data from DNS) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 1555587362181252.94796256066286; Thu, 18 Apr 2019 04:36:02 -0700 (PDT) Received: from localhost ([127.0.0.1]:39858 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5KQ-0005dK-3E for importer@patchew.org; Thu, 18 Apr 2019 07:35:42 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50594) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GE-0002g5-VO for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GD-0004Sh-HI for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:22 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:45406 helo=mx0a-001b2d01.pphosted.com) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GD-0004Rn-BT for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:21 -0400 Received: from pps.filterd (m0098417.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBTSJn033218 for ; Thu, 18 Apr 2019 07:31:20 -0400 Received: from e06smtp07.uk.ibm.com (e06smtp07.uk.ibm.com [195.75.94.103]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxq8636bb-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:20 -0400 Received: from localhost by e06smtp07.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:18 +0100 Received: from b06cxnps3075.portsmouth.uk.ibm.com (9.149.109.195) by e06smtp07.uk.ibm.com (192.168.101.137) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 18 Apr 2019 12:31:15 +0100 Received: from d06av23.portsmouth.uk.ibm.com (d06av23.portsmouth.uk.ibm.com [9.149.105.59]) by b06cxnps3075.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVDim34734116 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:13 GMT Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 6E02CA405B; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 5EFA7A4059; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av23.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 16AD520F63B; Thu, 18 Apr 2019 13:31:13 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:07 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-0028-0000-0000-0000036231C8 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-0029-0000-0000-00002421720F Message-Id: <20190418113110.160664-8-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.158.5 Subject: [Qemu-devel] [PATCH 07/10] s390x/cpumodel: deflate X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" add the deflate conversion facility. Signed-off-by: Christian Borntraeger --- target/s390x/cpu_features.c | 9 +++++++++ target/s390x/cpu_features.h | 1 + target/s390x/cpu_features_def.h | 7 +++++++ target/s390x/gen-features.c | 12 ++++++++++++ target/s390x/kvm.c | 6 ++++++ 5 files changed, 35 insertions(+) diff --git a/target/s390x/cpu_features.c b/target/s390x/cpu_features.c index e0a4769c19..5f37e655fe 100644 --- a/target/s390x/cpu_features.c +++ b/target/s390x/cpu_features.c @@ -110,6 +110,7 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("cmmnt", S390_FEAT_TYPE_STFL, 147, "CMM: ESSA-enhancement (n= o translate) facility"), FEAT_INIT("vxeh2", S390_FEAT_TYPE_STFL, 148, "Vector Enhancements faci= lity 2"), FEAT_INIT("esort-base", S390_FEAT_TYPE_STFL, 150, "Enhanced-sort facil= ity (excluding subfunctions)"), + FEAT_INIT("deflate-base", S390_FEAT_TYPE_STFL, 151, "Deflate-conversio= n facility (excluding subfunctions)"), FEAT_INIT("vxbeh", S390_FEAT_TYPE_STFL, 152, "Vector BCD enhancements = facility 1"), FEAT_INIT("msa9-base", S390_FEAT_TYPE_STFL, 155, "Message-security-ass= ist-extension-9 facility (excluding subfunctions)"), FEAT_INIT("etoken", S390_FEAT_TYPE_STFL, 156, "Etoken facility"), @@ -347,6 +348,11 @@ static const S390FeatDef s390_features[] =3D { FEAT_INIT("sortl-32", S390_FEAT_TYPE_SORTL, 130, "SORTL 32 input lists= "), FEAT_INIT("sortl-128", S390_FEAT_TYPE_SORTL, 132, "SORTL 128 input lis= ts"), FEAT_INIT("sortl-f0", S390_FEAT_TYPE_SORTL, 192, "SORTL format 0 param= eter-block"), + + FEAT_INIT("dfltcc-gdht", S390_FEAT_TYPE_DFLTCC, 1, "DFLTCC GDHT"), + FEAT_INIT("dfltcc-cmpr", S390_FEAT_TYPE_DFLTCC, 2, "DFLTCC CMPR"), + FEAT_INIT("dfltcc-xpnd", S390_FEAT_TYPE_DFLTCC, 4, "DFLTCC XPND"), + FEAT_INIT("dfltcc-f0", S390_FEAT_TYPE_DFLTCC, 192, "DFLTCC format 0 pa= rameter-block"), }; =20 const S390FeatDef *s390_feat_def(S390Feat feat) @@ -411,6 +417,7 @@ void s390_fill_feat_block(const S390FeatBitmap features= , S390FeatType type, case S390_FEAT_TYPE_KMA: case S390_FEAT_TYPE_KDSA: case S390_FEAT_TYPE_SORTL: + case S390_FEAT_TYPE_DFLTCC: set_be_bit(0, data); /* query is always available */ break; default: @@ -439,6 +446,7 @@ void s390_add_from_feat_block(S390FeatBitmap features, = S390FeatType type, break; case S390_FEAT_TYPE_PLO: case S390_FEAT_TYPE_SORTL: + case S390_FEAT_TYPE_DFLTCC: nr_bits =3D 256; break; default: @@ -511,6 +519,7 @@ static S390FeatGroupDef s390_feature_groups[] =3D { FEAT_GROUP_INIT("msa9_pckmo", MSA_EXT_9_PCKMO, "Message-security-assis= t-extension 9 PCKMO subfunctions"), FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements = introduced with Multiple-epoch facility"), FEAT_GROUP_INIT("esort", ENH_SORT, "Enhanced-sort facility"), + FEAT_GROUP_INIT("deflate", DEFLATE_CONVERSION, "Deflate-conversion fac= ility"), }; =20 const S390FeatGroupDef *s390_feat_group_def(S390FeatGroup group) diff --git a/target/s390x/cpu_features.h b/target/s390x/cpu_features.h index 3b8c5b25dd..da695a8346 100644 --- a/target/s390x/cpu_features.h +++ b/target/s390x/cpu_features.h @@ -41,6 +41,7 @@ typedef enum { S390_FEAT_TYPE_KMA, S390_FEAT_TYPE_KDSA, S390_FEAT_TYPE_SORTL, + S390_FEAT_TYPE_DFLTCC, } S390FeatType; =20 /* Definition of a CPU feature */ diff --git a/target/s390x/cpu_features_def.h b/target/s390x/cpu_features_de= f.h index bb8585847f..292b17b35d 100644 --- a/target/s390x/cpu_features_def.h +++ b/target/s390x/cpu_features_def.h @@ -98,6 +98,7 @@ typedef enum { S390_FEAT_CMM_NT, S390_FEAT_VECTOR_ENH2, S390_FEAT_ESORT_BASE, + S390_FEAT_DEFLATE_BASE, S390_FEAT_VECTOR_BCD_ENH, S390_FEAT_MSA_EXT_9, S390_FEAT_ETOKEN, @@ -354,6 +355,12 @@ typedef enum { S390_FEAT_SORTL_128, S390_FEAT_SORTL_F0, =20 + /* DEFLATE */ + S390_FEAT_DEFLATE_GHDT, + S390_FEAT_DEFLATE_CMPR, + S390_FEAT_DEFLATE_XPND, + S390_FEAT_DEFLATE_F0, + S390_FEAT_MAX, } S390Feat; =20 diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c index 3db323fc0c..170226d3dd 100644 --- a/target/s390x/gen-features.c +++ b/target/s390x/gen-features.c @@ -254,6 +254,13 @@ S390_FEAT_SORTL_F0 =20 =20 +#define S390_FEAT_GROUP_DEFLATE_CONVERSION \ + S390_FEAT_DEFLATE_BASE, \ + S390_FEAT_DEFLATE_GHDT, \ + S390_FEAT_DEFLATE_CMPR, \ + S390_FEAT_DEFLATE_XPND, \ + S390_FEAT_DEFLATE_F0 + /* cpu feature groups */ static uint16_t group_PLO[] =3D { S390_FEAT_GROUP_PLO, @@ -307,6 +314,10 @@ static uint16_t group_ENH_SORT[] =3D { S390_FEAT_GROUP_ENH_SORT, }; =20 +static uint16_t group_DEFLATE_CONVERSION[] =3D { + S390_FEAT_GROUP_DEFLATE_CONVERSION, +}; + /* Base features (in order of release) * Only non-hypervisor managed features belong here. * Base feature sets are static meaning they do not change in future QEMU @@ -765,6 +776,7 @@ static FeatGroupDefSpec FeatGroupDef[] =3D { FEAT_GROUP_INITIALIZER(MSA_EXT_9_PCKMO), FEAT_GROUP_INITIALIZER(MULTIPLE_EPOCH_PTFF), FEAT_GROUP_INITIALIZER(ENH_SORT), + FEAT_GROUP_INITIALIZER(DEFLATE_CONVERSION), }; =20 #define QEMU_FEAT_INITIALIZER(_name) \ diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c index 7681492c41..db9108b63c 100644 --- a/target/s390x/kvm.c +++ b/target/s390x/kvm.c @@ -2086,6 +2086,9 @@ static int query_cpu_subfunc(S390FeatBitmap features) if (test_bit(S390_FEAT_ESORT_BASE, features)) { s390_add_from_feat_block(features, S390_FEAT_TYPE_SORTL, prop.sort= l); } + if (test_bit(S390_FEAT_DEFLATE_BASE, features)) { + s390_add_from_feat_block(features, S390_FEAT_TYPE_DFLTCC, prop.dfl= tcc); + } return 0; } =20 @@ -2136,6 +2139,9 @@ static int configure_cpu_subfunc(const S390FeatBitmap= features) if (test_bit(S390_FEAT_ESORT_BASE, features)) { s390_fill_feat_block(features, S390_FEAT_TYPE_SORTL, prop.sortl); } + if (test_bit(S390_FEAT_DEFLATE_BASE, features)) { + s390_fill_feat_block(features, S390_FEAT_TYPE_DFLTCC, prop.dfltcc); + } return kvm_vm_ioctl(kvm_state, KVM_SET_DEVICE_ATTR, &attr); } =20 --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: temperror (zoho.com: Error in retrieving data from DNS) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=temperror (zoho.com: Error in retrieving data from DNS) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587396; cv=none; d=zoho.com; s=zohoarc; b=j3LhgrpcmGBpKoYkZj7aTgfu5v9sziPae1MAXxq39BgbSCMOStF/P3jttxHoBLMXsY+j7rehlxuoYPa6cMWenrACwGxRNy+3Vlon3Rm1Q2m+2now31+Oz67rHaB5dmvmipgF3G4BNC/1cv5mJP5UgcHZg5ANHNgLhYiw2bhqiB4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587396; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=p37UMsbbmIpE7xeX5+PtbT9iBZ3CPE6ovNPo2b52u38=; b=eUhv/A1aadEFtXtq5GuFgiylfx9W4AcqYHdclC7H7Ls3y2IThBnOns3HI9/EANcOGsfoqaZzO+ptEZ9iJni4wAm6NuJLuOgGx5r/kWQ+KXRCEPRloHrgb2TLcd2qMONb7I0faicgI9WNhDANUN+j1uyX5AjnsP5sEZifq1WSVVk= ARC-Authentication-Results: i=1; mx.zoho.com; spf=temperror (zoho.com: Error in retrieving data from DNS) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (209.51.188.17 [209.51.188.17]) by mx.zohomail.com with SMTPS id 15555873963901018.4590799550199; Thu, 18 Apr 2019 04:36:36 -0700 (PDT) Received: from localhost ([127.0.0.1]:39873 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5L8-0006FP-IN for importer@patchew.org; Thu, 18 Apr 2019 07:36:26 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50746) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GJ-0002m7-B3 for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:28 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GF-0004Wc-Ns for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:27 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:49832) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GF-0004Tm-66 for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:23 -0400 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 x3IBTUCH047911 for ; Thu, 18 Apr 2019 07:31:21 -0400 Received: from e06smtp01.uk.ibm.com (e06smtp01.uk.ibm.com [195.75.94.97]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxp2renkn-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:20 -0400 Received: from localhost by e06smtp01.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:17 +0100 Received: from b06cxnps3074.portsmouth.uk.ibm.com (9.149.109.194) 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, 18 Apr 2019 12:31:15 +0100 Received: from d06av26.portsmouth.uk.ibm.com (d06av26.portsmouth.uk.ibm.com [9.149.105.62]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVDHm61014094 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:13 GMT Received: from d06av26.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id AD62DAE05A; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: from d06av26.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id A17DDAE059; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av26.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 5868C20F639; Thu, 18 Apr 2019 13:31:13 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:08 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-4275-0000-0000-000003293A19 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-4276-0000-0000-000038387324 Message-Id: <20190418113110.160664-9-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=832 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.156.1 Subject: [Qemu-devel] [PATCH 08/10] s390x/cpumodel: add gen15 defintions X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" add several new features (msa9, sort, deflate, additional vector instructions, new general purpose instructions) to generation 15. Also disable csske and bpb from the default model. This will allow to migrate generation 15 machines to future machines that do not have these features. Signed-off-by: Christian Borntraeger --- hw/s390x/s390-virtio-ccw.c | 4 ++++ target/s390x/gen-features.c | 25 +++++++++++++++++++++++++ 2 files changed, 29 insertions(+) diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c index 3415948b2c..d7a9e487e0 100644 --- a/hw/s390x/s390-virtio-ccw.c +++ b/hw/s390x/s390-virtio-ccw.c @@ -594,6 +594,10 @@ static inline void s390_machine_initfn(Object *obj) " to upper case) to pass to machine loader, boot manager," " and guest kernel", NULL); + + /* deprecated functionality for gen15 and later */ + s390_cpudef_featoff_greater(15, 1, S390_FEAT_BPB); + s390_cpudef_featoff_greater(15, 1, S390_FEAT_CONDITIONAL_SSKE); } =20 static const TypeInfo ccw_machine_info =3D { diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c index 170226d3dd..4cf5a21cc1 100644 --- a/target/s390x/gen-features.c +++ b/target/s390x/gen-features.c @@ -418,6 +418,10 @@ static uint16_t base_GEN14_GA1[] =3D { =20 #define base_GEN14_GA2 EmptyFeat =20 +static uint16_t base_GEN15_GA1[] =3D { + S390_FEAT_MISC_INSTRUCTION_EXT3, +}; + /* Full features (in order of release) * Automatically includes corresponding base features. * Full features are all features this hardware supports even if kvm/QEMU = do not @@ -547,6 +551,16 @@ static uint16_t full_GEN14_GA1[] =3D { =20 #define full_GEN14_GA2 EmptyFeat =20 +static uint16_t full_GEN15_GA1[] =3D { + S390_FEAT_VECTOR_ENH2, + S390_FEAT_GROUP_ENH_SORT, + S390_FEAT_GROUP_DEFLATE_CONVERSION, + S390_FEAT_VECTOR_BCD_ENH, + S390_FEAT_GROUP_MSA_EXT_9, + S390_FEAT_GROUP_MSA_EXT_9_PCKMO, + S390_FEAT_ETOKEN, +}; + /* Default features (in order of release) * Automatically includes corresponding base features. * Default features are all features this version of QEMU supports for this @@ -623,6 +637,16 @@ static uint16_t default_GEN14_GA1[] =3D { =20 #define default_GEN14_GA2 EmptyFeat =20 +static uint16_t default_GEN15_GA1[] =3D { + S390_FEAT_VECTOR_ENH2, + S390_FEAT_GROUP_ENH_SORT, + S390_FEAT_GROUP_DEFLATE_CONVERSION, + S390_FEAT_VECTOR_BCD_ENH, + S390_FEAT_GROUP_MSA_EXT_9, + S390_FEAT_GROUP_MSA_EXT_9_PCKMO, + S390_FEAT_ETOKEN, +}; + /* QEMU (CPU model) features */ =20 static uint16_t qemu_V2_11[] =3D { @@ -739,6 +763,7 @@ static CpuFeatDefSpec CpuFeatDef[] =3D { CPU_FEAT_INITIALIZER(GEN13_GA2), CPU_FEAT_INITIALIZER(GEN14_GA1), CPU_FEAT_INITIALIZER(GEN14_GA2), + CPU_FEAT_INITIALIZER(GEN15_GA1), }; =20 #define FEAT_GROUP_INITIALIZER(_name) \ --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587502; cv=none; d=zoho.com; s=zohoarc; b=WOYm5FwghCH7roGgh4NZ48ZUsdTzE3IPxIixk2IqqANnktA6epLmDjF5urpvI9QGV9tDvLfAbCxaG2LQPwg+onInYt6HZ41bSK/Kc8dTc9mlhTywLqFIYfN2gQA+vItyrR7oxmOGrF4Csh5aibfZ4sxM3OO2Dj/VPHdvCdg4w9U= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587502; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=WXniStjIazaPb3+h2UTEalwKyuEkCsDJ9fRGGneXOrI=; b=HtuH13yaphPDhVCjrbhO4zQhOvrQcLEjG1OGo3FH52NDrjpeK2TotjP7m9TjV0SME/x6f2w4sCY9RoUel5nk5X9aVGM2VYFvzaqTwXekDsI7jcCIUlpZXzWuNtfJZGba9ECo26LmNAzDNtmonDfL7+kk8j81gTClpRglzBdRpBs= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1555587502530675.6637825291956; Thu, 18 Apr 2019 04:38:22 -0700 (PDT) Received: from localhost ([127.0.0.1]:39889 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5Mu-0007cu-8j for importer@patchew.org; Thu, 18 Apr 2019 07:38:16 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50653) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GH-0002ji-2m for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GF-0004WD-Ju for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:24 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:45966) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GF-0004Td-50 for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:23 -0400 Received: from pps.filterd (m0098393.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBTThu134685 for ; Thu, 18 Apr 2019 07:31:20 -0400 Received: from e06smtp05.uk.ibm.com (e06smtp05.uk.ibm.com [195.75.94.101]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxq723fpw-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:19 -0400 Received: from localhost by e06smtp05.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:17 +0100 Received: from b06cxnps3074.portsmouth.uk.ibm.com (9.149.109.194) by e06smtp05.uk.ibm.com (192.168.101.135) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 18 Apr 2019 12:31:15 +0100 Received: from d06av25.portsmouth.uk.ibm.com (d06av25.portsmouth.uk.ibm.com [9.149.105.61]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVEC753870716 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:14 GMT Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id ED26811C054; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: from d06av25.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id E1E4E11C05C; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av25.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 18 Apr 2019 11:31:13 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id 9C9A520F63B; Thu, 18 Apr 2019 13:31:13 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:09 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-0020-0000-0000-0000033130D9 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-0021-0000-0000-00002183810F Message-Id: <20190418113110.160664-10-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=841 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.156.1 Subject: [Qemu-devel] [PATCH 09/10] s390x/cpumodel: wire up 8561 and 8562 as gen15 machines X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" 8561 and 8562 will be gen15 machines. There is no name yet, lets us use the cpu id as base name. Later on we can provide aliases with the proper name. Signed-off-by: Christian Borntraeger --- target/s390x/cpu_models.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c index 4c355e936e..e727519686 100644 --- a/target/s390x/cpu_models.c +++ b/target/s390x/cpu_models.c @@ -82,6 +82,8 @@ static S390CPUDef s390_cpu_defs[] =3D { CPUDEF_INIT(0x3906, 14, 1, 47, 0x08000000U, "z14", "IBM z14 GA1"), CPUDEF_INIT(0x3906, 14, 2, 47, 0x08000000U, "z14.2", "IBM z14 GA2"), CPUDEF_INIT(0x3907, 14, 1, 47, 0x08000000U, "z14ZR1", "IBM z14 Model Z= R1 GA1"), + CPUDEF_INIT(0x8561, 15, 1, 47, 0x08000000U, "8561", "IBM 8561 GA1"), + CPUDEF_INIT(0x8562, 15, 1, 47, 0x08000000U, "8562", "IBM 8562 GA1"), }; =20 #define QEMU_MAX_CPU_TYPE 0x2827 --=20 2.19.1 From nobody Mon Apr 29 16:04:59 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=de.ibm.com ARC-Seal: i=1; a=rsa-sha256; t=1555587389; cv=none; d=zoho.com; s=zohoarc; b=UayNGrQ2RfMPjNLhg7cDwrOhXeKIZx83vBZlDCd1fpUvG7i+u2n7Gr/jga4wPFBnFpuyAKgWkyT7mg8WpK7EC9DZPkflueeC/AkVaNpZ9BfBqdpPIqL7Ipmdci6FBPVj97hT3v8HPWWuYnbRaMMteY1iRMwUd/hPCbr6kcReK3Y= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555587389; h=Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To:ARC-Authentication-Results; bh=/c04r2MmxwDo+yCTSd6/KboZquxkCdYKb9YUeS93gbU=; b=LsBzRHskSZRiuC/O1AUdZ0xqVDWX2QguzE82KTwHyIoOJeDl+NP6BfkCuPuT4ChdsijjHnCIvpqBd50YSqzjcSGCkpuOyzj+aUFYC0LA1zpgYu9URhyHzUHK8OX0IbpgNIZpORZEK7YLN+ArJyo6/iTq2FqebXBLIDVjQXECOSc= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1555587389391137.16362922043754; Thu, 18 Apr 2019 04:36:29 -0700 (PDT) Received: from localhost ([127.0.0.1]:39871 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5L0-00069n-8K for importer@patchew.org; Thu, 18 Apr 2019 07:36:18 -0400 Received: from eggs.gnu.org ([209.51.188.92]:50709) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hH5GI-0002lT-Iv for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hH5GF-0004Ws-S7 for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:26 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:55400) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hH5GF-0004UA-BE for qemu-devel@nongnu.org; Thu, 18 Apr 2019 07:31:23 -0400 Received: from pps.filterd (m0098396.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x3IBTRPf101384 for ; Thu, 18 Apr 2019 07:31:22 -0400 Received: from e06smtp04.uk.ibm.com (e06smtp04.uk.ibm.com [195.75.94.100]) by mx0a-001b2d01.pphosted.com with ESMTP id 2rxqyu18ys-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Thu, 18 Apr 2019 07:31:21 -0400 Received: from localhost by e06smtp04.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 18 Apr 2019 12:31:19 +0100 Received: from b06cxnps4074.portsmouth.uk.ibm.com (9.149.109.196) by e06smtp04.uk.ibm.com (192.168.101.134) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Thu, 18 Apr 2019 12:31:15 +0100 Received: from d06av23.portsmouth.uk.ibm.com (d06av23.portsmouth.uk.ibm.com [9.149.105.59]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x3IBVEUG24838344 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 18 Apr 2019 11:31:14 GMT Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 32CC0A4059; Thu, 18 Apr 2019 11:31:14 +0000 (GMT) Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 2A9C8A4051; Thu, 18 Apr 2019 11:31:14 +0000 (GMT) Received: from tuxmaker.boeblingen.de.ibm.com (unknown [9.152.85.9]) by d06av23.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Thu, 18 Apr 2019 11:31:14 +0000 (GMT) Received: by tuxmaker.boeblingen.de.ibm.com (Postfix, from userid 25651) id E0CC620F639; Thu, 18 Apr 2019 13:31:13 +0200 (CEST) From: Christian Borntraeger To: Cornelia Huck Date: Thu, 18 Apr 2019 13:31:10 +0200 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190418113110.160664-1-borntraeger@de.ibm.com> References: <20190418113110.160664-1-borntraeger@de.ibm.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-TM-AS-GCONF: 00 x-cbid: 19041811-0016-0000-0000-0000027035EC X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19041811-0017-0000-0000-000032CC8CED Message-Id: <20190418113110.160664-11-borntraeger@de.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-04-18_06:, , 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=762 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1904180082 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 148.163.156.1 Subject: [Qemu-devel] [PATCH 10/10] s390x/cpumodel: do not claim csske for expanded models in qmp X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Jason J . Herne" , Collin Walling , David Hildenbrand , qemu-devel , Halil Pasic , Christian Borntraeger , qemu-s390x , Richard Henderson Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" Content-Type: text/plain; charset="utf-8" While we have removed csske and bpb from the default model, the very common case of "host-model" in libvirt (expanded to a base model + features) would still contain bpb and csske. This can prevent migration to a future machine for a host-model machine. Let us fence bpb and csske when we run on a generation 15. If necessary the user can still use -cpu 8561,csske=3Don,bpb=3Don to force enable these features. Signed-off-by: Christian Borntraeger --- target/s390x/cpu_models.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c index e727519686..03bdca1fb8 100644 --- a/target/s390x/cpu_models.c +++ b/target/s390x/cpu_models.c @@ -629,6 +629,17 @@ CpuModelExpansionInfo *qmp_query_cpu_model_expansion(C= puModelExpansionType type, return NULL; } =20 + /* + * Do not claim CSSKE and BPB if the host model expands to + * generation 15 or newer + */ + if (s390_model.def->gen >=3D 15) { + clear_bit(S390_FEAT_CONDITIONAL_SSKE, + (unsigned long *) &s390_model.features); + clear_bit(S390_FEAT_BPB, + (unsigned long *) &s390_model.features); + } + if (type =3D=3D CPU_MODEL_EXPANSION_TYPE_STATIC) { delta_changes =3D true; } else if (type !=3D CPU_MODEL_EXPANSION_TYPE_FULL) { --=20 2.19.1