From nobody Sat May 4 05:59:12 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; arc=pass (i=1dmarc=pass fromdomain=arm.com) ARC-Seal: i=2; a=rsa-sha256; t=1598239769; cv=pass; d=zohomail.com; s=zohoarc; b=N1lQl45Gs04YAXlKLkHJKp0eHg0lvtuakONdWHF4/laXc9w2PD4bhqiBgJ+hac1K1W4B6zt6vaIBt8BzxtxzQV3RipY3lwFHRvHDg/gr8bhartR2KzEFftH2UZs2tNJIFFvRwJ7GTXKHfGbTbnRxy+ZTeT0vhlcd7HGZnRaquXc= ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1598239769; h=Content-Type:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=s+H3wJF+JHcr7lSYGrwxDrb7AbgKV+XERRs6NTOnc74=; b=bfc37+9as6eKWpk2QYknO9cDdSQ6OLBIp5R+V64P3cY52E/W9PF5GkKnKIih3d8vKLbZkeGbBb+zr80y+KNArUvoEe1hXyU1lOVFL26S6wOwYH3gnsEKFCIpNQN21iztH8LAFCxwySxluRtY1zmm5JgKjz6bfpuG2hJOsWEy/zU= ARC-Authentication-Results: i=2; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; arc=pass (i=1dmarc=pass fromdomain=arm.com) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1598239769754333.2909566889746; Sun, 23 Aug 2020 20:29:29 -0700 (PDT) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1kA3AF-0004eA-9S; Mon, 24 Aug 2020 03:28:55 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1kA3AE-0004e5-Lg for xen-devel@lists.xenproject.org; Mon, 24 Aug 2020 03:28:54 +0000 Received: from EUR04-DB3-obe.outbound.protection.outlook.com (unknown [40.107.6.76]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id cfddd72c-a4e3-4d2b-905a-11773d4e3d15; Mon, 24 Aug 2020 03:28:52 +0000 (UTC) Received: from AM6PR10CA0048.EURPRD10.PROD.OUTLOOK.COM (2603:10a6:209:80::25) by DBAPR08MB5558.eurprd08.prod.outlook.com (2603:10a6:10:1b3::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.25; Mon, 24 Aug 2020 03:28:51 +0000 Received: from AM5EUR03FT014.eop-EUR03.prod.protection.outlook.com (2603:10a6:209:80:cafe::f) by AM6PR10CA0048.outlook.office365.com (2603:10a6:209:80::25) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.25 via Frontend Transport; Mon, 24 Aug 2020 03:28:50 +0000 Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by AM5EUR03FT014.mail.protection.outlook.com (10.152.16.130) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.24 via Frontend Transport; Mon, 24 Aug 2020 03:28:50 +0000 Received: ("Tessian outbound 7fc8f57bdedc:v64"); Mon, 24 Aug 2020 03:28:50 +0000 Received: from c58748b821c1.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 06EAF8FD-4D80-4363-B2BA-9384155B09EC.1; Mon, 24 Aug 2020 03:28:45 +0000 Received: from EUR04-VI1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id c58748b821c1.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Mon, 24 Aug 2020 03:28:45 +0000 Received: from DB8PR03CA0032.eurprd03.prod.outlook.com (2603:10a6:10:be::45) by AM6PR08MB4582.eurprd08.prod.outlook.com (2603:10a6:20b:8f::24) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.24; Mon, 24 Aug 2020 03:28:43 +0000 Received: from DB5EUR03FT028.eop-EUR03.prod.protection.outlook.com (2603:10a6:10:be:cafe::18) by DB8PR03CA0032.outlook.office365.com (2603:10a6:10:be::45) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.24 via Frontend Transport; Mon, 24 Aug 2020 03:28:43 +0000 Received: from nebula.arm.com (40.67.248.234) by DB5EUR03FT028.mail.protection.outlook.com (10.152.20.99) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.3305.24 via Frontend Transport; Mon, 24 Aug 2020 03:28:43 +0000 Received: from AZ-NEU-EX04.Arm.com (10.251.24.32) by AZ-NEU-EX03.Arm.com (10.251.24.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2044.4; Mon, 24 Aug 2020 03:28:42 +0000 Received: from localhost.localdomain (10.169.214.112) by mail.arm.com (10.251.24.32) with Microsoft SMTP Server id 15.1.2044.4 via Frontend Transport; Mon, 24 Aug 2020 03:28:39 +0000 X-Inumbo-ID: cfddd72c-a4e3-4d2b-905a-11773d4e3d15 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=s+H3wJF+JHcr7lSYGrwxDrb7AbgKV+XERRs6NTOnc74=; b=TQkpWI+QLGRKaXRbZj7FGaEEeCTPCXSD3AWmLSpwtoLlLylJi28yiJlQRQJdmzi0weLDaS2QCXMNu+VRbUuY6GhzDdu1eNuMc1HpEdS75r3l+RCx997mnbK9IDxYUFGPWCQu4A8ZKJi6NaCL6dx+k0LHRvlXkRTcBm2/2QJSzQM= X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; lists.xenproject.org; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;lists.xenproject.org; dmarc=bestguesspass action=none header.from=arm.com; Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; X-CheckRecipientChecked: true X-CR-MTA-CID: 4dcd6ddfea3d147f X-CR-MTA-TID: 64aa7808 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=cIuFdDTK4QYDnNHVrdvBnkikjox4BRwvPqCTk+pEQzJmhYaT1FIMJ7vBWbM8RVic78HPgA6gt9Ycg2md0qGVGeNsNlLzFUtEptBqdR1gIcC4LJmLBgLPpFIbpfWP2scPItHbFYEPhut0TR5l3RYkm7i98qxtzVpeyOORO5COcYiFP0LaWkTr0i4eJKCZmbiqCLzk+nFYVJjaBWX4sZ1ID4rvpXBDrvatd9Cm2rwLhU3mPcJpCtVVoYC9KY90b0WBvKBA9PuYTDtDubIi2yQdzCJSjl9/atleypg8/MLdwfIOTXbJ9WF2FHqPCzzGA/x4eMZrFRGSO5diSysZBz/Y/Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=s+H3wJF+JHcr7lSYGrwxDrb7AbgKV+XERRs6NTOnc74=; b=h1Ya9OA/BDbZBLhyG2f9e4JfNIDkGJRfVnx3SYhjEBw1JptcKHbnXgNiGLL/X3nK4k6SXCp7MiNN7AKxkRPgESMfBiusOOBm/daYj3TpT9s+weU7YK1drKtfrXEuNWq5dOi8zFgkUF+gwv1LnpsSsV1PnnZxXVlgm0a0fZanJjIkmsMuIBm+SJKgMRLDGkCaLlbA4dv/ywi9zb+qZJlq7cOFeZ20AjwE9vm/S9798VL5V0P1jXrx4cNWIdEqWTgBqGc8BvDtQsh4JB7nRBgvf3dAKedbT/TRdETCX4b4x3TZ+wc7LxVSKmlJDARxMQ/JN9G7Dk/hldhBrpMewpsnQw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=arm.com; dmarc=bestguesspass action=none header.from=arm.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=s+H3wJF+JHcr7lSYGrwxDrb7AbgKV+XERRs6NTOnc74=; b=TQkpWI+QLGRKaXRbZj7FGaEEeCTPCXSD3AWmLSpwtoLlLylJi28yiJlQRQJdmzi0weLDaS2QCXMNu+VRbUuY6GhzDdu1eNuMc1HpEdS75r3l+RCx997mnbK9IDxYUFGPWCQu4A8ZKJi6NaCL6dx+k0LHRvlXkRTcBm2/2QJSzQM= X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; lists.xenproject.org; dkim=none (message not signed) header.d=none;lists.xenproject.org; dmarc=bestguesspass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 40.67.248.234 as permitted sender) receiver=protection.outlook.com; client-ip=40.67.248.234; helo=nebula.arm.com; From: Wei Chen To: , , CC: , , , , Subject: [PATCH v2 1/2] xen/arm: Missing N1/A76/A75 FP registers in vCPU context switch Date: Mon, 24 Aug 2020 03:28:24 +0000 Message-ID: <20200824032825.18368-2-wei.chen@arm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200824032825.18368-1-wei.chen@arm.com> References: <20200824032825.18368-1-wei.chen@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-Office365-Filtering-HT: Tenant X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 1ff2c318-66ed-48d5-c2b6-08d847ddd1ec X-MS-TrafficTypeDiagnostic: AM6PR08MB4582:|DBAPR08MB5558: X-Microsoft-Antispam-PRVS: x-checkrecipientrouted: true NoDisclaimer: true X-MS-Oob-TLC-OOBClassifiers: OLM:7691;OLM:7691; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: MBZi2oeAXQNPAFJxKsa0qYoF5IIfuQ85zqSu80Bsy2XaQApWnVlR8x44gbyRZGqFbTBP45VQwMZ1jSmTDxpzFXuVIR/tSvNv5b62KCKK6MFhImQpOu05Ztc1IRrjJnbFZYuTt/WvXksEm9cYEyqWucEZe3YZPlA+IpinUrnd+GZQe0bNDnbQZdfZFE4WBFdKE8xpt9IfxkigOcKXMZhlagBHq3iqAiEk6TUlESY4VJrqeuZhPbNzP0I0Gd4LYoYz+G2POpDL7cS6TZKMWA3lRt9GkHai3aMImMZYigRtGo80hPsFhWZv8OSZ8WNBQ0RtMHUQ+S+FLT4sFXS6k2aBe138EwQAGW1HyKwqcszDSTXdegktJOKq/amJiy25iuQCkzHkjfEpGFU9FrRqmFFxQA== X-Forefront-Antispam-Report-Untrusted: CIP:40.67.248.234; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(4636009)(39850400004)(136003)(396003)(376002)(346002)(46966005)(86362001)(70206006)(426003)(336012)(4326008)(1076003)(26005)(44832011)(70586007)(2616005)(5660300002)(36756003)(6666004)(2906002)(186003)(8936002)(54906003)(8676002)(316002)(82740400003)(82310400002)(478600001)(110136005)(47076004)(81166007)(356005)(83380400001); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR08MB4582 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM5EUR03FT014.eop-EUR03.prod.protection.outlook.com X-MS-Office365-Filtering-Correlation-Id-Prvs: ba96a953-16cf-4955-d6cd-08d847ddcd74 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 3TE+wIu80BhcJQJ3IXDBP2Fb5N50eIO9K9JIcvLDS/6VaHbiT+CA0fgqweOashg3EFsqdmiJh3yB0hPVz5JNTGvighK/GYAUJg7gX5LLe8f1Y317R78wH10T6vRgBkJX+kRi2sgUfoOnvyZTEVSYue7mGVGNwAVpKNz5yt7lliPIFdK+obgck4UzZcXXRDm8Ta0CXLGRO0KZI7Hmas6nYMlA/3mtvAJZegAA4kfQVHiDfbvnVtQwBldLNq/vCXcElop1In8DjkrKXmV8Fbxy4jpg1uQD4eyoFYej03AVOKs3Y9uubq7ESve5pTKfN0PG0MuAppSEs+mGbca97pL0fZZwiY7d8LvlpUHxgVp2AByjF4LkK2SClinaC7EuF7ne7K724a7ESOVRvGuvgvcgvA== X-Forefront-Antispam-Report: CIP:63.35.35.123; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:64aa7808-outbound-1.mta.getcheckrecipient.com; PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com; CAT:NONE; SFS:(4636009)(136003)(39850400004)(396003)(346002)(376002)(46966005)(8936002)(186003)(2906002)(44832011)(4326008)(5660300002)(1076003)(70206006)(70586007)(26005)(36756003)(6666004)(336012)(426003)(8676002)(478600001)(83380400001)(36906005)(82310400002)(81166007)(316002)(54906003)(47076004)(82740400003)(110136005)(2616005)(86362001); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Aug 2020 03:28:50.7654 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 1ff2c318-66ed-48d5-c2b6-08d847ddd1ec X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[63.35.35.123]; Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: AM5EUR03FT014.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBAPR08MB5558 X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" X-ZohoMail-DKIM: pass (identity @armh.onmicrosoft.com) Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Xen has cpu_has_fp/cpu_has_simd to detect whether the CPU supports FP/SIMD or not. But currently, these two MACROs only consider value 0 of ID_AA64PFR0_EL1.FP/SIMD as FP/SIMD features enabled. But for CPUs that support FP/SIMD and half-precision floating-point arithmetic, the ID_AA64PFR0_EL1.FP/SIMD are 1 (see Arm ARM DDI0487F.b, D13.2.64). For these CPUs, xen will treat them as no FP/SIMD supporti, the vfp_save/restore_state will not take effect. From the TRM documents of Cortex-A75/A76/N1, we know these CPUs support basic Advanced SIMD/FP and half-precision floating-point arithmetic. In this case, on N1/A76/A75 platforms, Xen will always miss the floating pointer registers save/restore. If different vCPUs are running on the same pCPU, the floating pointer registers will be corrupted randomly. This patch fixes Xen on these new cores. Signed-off-by: Wei Chen Reviewed-by: Bertrand Marquis Reviewed-by: Julien Grall --- xen/include/asm-arm/cpufeature.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xen/include/asm-arm/cpufeature.h b/xen/include/asm-arm/cpufeat= ure.h index 674beb0353..10878ead8a 100644 --- a/xen/include/asm-arm/cpufeature.h +++ b/xen/include/asm-arm/cpufeature.h @@ -13,8 +13,8 @@ #define cpu_has_el2_64 (boot_cpu_feature64(el2) >=3D 1) #define cpu_has_el3_32 (boot_cpu_feature64(el3) =3D=3D 2) #define cpu_has_el3_64 (boot_cpu_feature64(el3) >=3D 1) -#define cpu_has_fp (boot_cpu_feature64(fp) =3D=3D 0) -#define cpu_has_simd (boot_cpu_feature64(simd) =3D=3D 0) +#define cpu_has_fp (boot_cpu_feature64(fp) < 8) +#define cpu_has_simd (boot_cpu_feature64(simd) < 8) #define cpu_has_gicv3 (boot_cpu_feature64(gic) =3D=3D 1) #endif =20 --=20 2.17.1 From nobody Sat May 4 05:59:12 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; arc=pass (i=1dmarc=pass fromdomain=arm.com) ARC-Seal: i=2; a=rsa-sha256; t=1598239769; cv=pass; d=zohomail.com; s=zohoarc; b=g9WS/qOW11P7b0XYCv+KqIP/qMDYotYxveFRCHvPJp9xpN0RMu7PjoI6H0V9KkYSL6j6ja5oGiYI5wSFGJUoFo1BeOsrNiGuPvtv1SXMdn1eKUZT6htNiQLvrmVUJq/GF92wHb/a0tfKV1PIDU09RlsrKOUQ4kxMymGKDLZGn9I= ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1598239769; h=Content-Type:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=dCRNMai18oICp1g78MOkm0i99zbDOHtAX7WyMRefru4=; b=huXXXJM+R+bo3Y0goCsfqRX6SOFsdirIz0r9rIvMtMZqu/d7XfH1kYzMacV8js9GfYF7xiKQ2DRd721qKwyYMzGQV0b0O9seyO0Q6ZpFEkBj4zoJ+j74FINeDvAdL0ocCNpEgW9iTqdl4zKe+OYflrUTjqtSh6YAo6Cp/FgySY0= ARC-Authentication-Results: i=2; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; arc=pass (i=1dmarc=pass fromdomain=arm.com) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1598239769168325.5142759509738; Sun, 23 Aug 2020 20:29:29 -0700 (PDT) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1kA3AM-0004fm-W8; Mon, 24 Aug 2020 03:29:02 +0000 Received: from all-amaz-eas1.inumbo.com ([34.197.232.57] helo=us1-amaz-eas2.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1kA3AL-0004eS-Dg for xen-devel@lists.xenproject.org; Mon, 24 Aug 2020 03:29:01 +0000 Received: from EUR05-DB8-obe.outbound.protection.outlook.com (unknown [40.107.20.55]) by us1-amaz-eas2.inumbo.com (Halon) with ESMTPS id db653abf-4213-4d15-be38-197771c511c4; Mon, 24 Aug 2020 03:28:57 +0000 (UTC) Received: from DB7PR05CA0052.eurprd05.prod.outlook.com (2603:10a6:10:2e::29) by AM7PR08MB5317.eurprd08.prod.outlook.com (2603:10a6:20b:101::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.24; Mon, 24 Aug 2020 03:28:54 +0000 Received: from DB5EUR03FT020.eop-EUR03.prod.protection.outlook.com (2603:10a6:10:2e:cafe::2b) by DB7PR05CA0052.outlook.office365.com (2603:10a6:10:2e::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.25 via Frontend Transport; Mon, 24 Aug 2020 03:28:54 +0000 Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by DB5EUR03FT020.mail.protection.outlook.com (10.152.20.134) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.24 via Frontend Transport; Mon, 24 Aug 2020 03:28:54 +0000 Received: ("Tessian outbound 7fc8f57bdedc:v64"); Mon, 24 Aug 2020 03:28:54 +0000 Received: from 55bd7e3e9c10.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 908F2E21-1BE4-4CB2-BE5B-ECCA4033C068.1; Mon, 24 Aug 2020 03:28:49 +0000 Received: from EUR05-VI1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 55bd7e3e9c10.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Mon, 24 Aug 2020 03:28:48 +0000 Received: from AM6P195CA0059.EURP195.PROD.OUTLOOK.COM (2603:10a6:209:87::36) by AM6PR08MB5237.eurprd08.prod.outlook.com (2603:10a6:20b:e9::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.25; Mon, 24 Aug 2020 03:28:47 +0000 Received: from AM5EUR03FT018.eop-EUR03.prod.protection.outlook.com (2603:10a6:209:87:cafe::b5) by AM6P195CA0059.outlook.office365.com (2603:10a6:209:87::36) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3305.25 via Frontend Transport; Mon, 24 Aug 2020 03:28:47 +0000 Received: from nebula.arm.com (40.67.248.234) by AM5EUR03FT018.mail.protection.outlook.com (10.152.16.114) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.3305.24 via Frontend Transport; Mon, 24 Aug 2020 03:28:47 +0000 Received: from AZ-NEU-EX01.Emea.Arm.com (10.251.26.4) by AZ-NEU-EX04.Arm.com (10.251.24.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.2044.4; Mon, 24 Aug 2020 03:28:46 +0000 Received: from AZ-NEU-EX04.Arm.com (10.251.24.32) by AZ-NEU-EX01.Emea.Arm.com (10.251.26.4) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1779.2; Mon, 24 Aug 2020 03:28:45 +0000 Received: from localhost.localdomain (10.169.214.112) by mail.arm.com (10.251.24.32) with Microsoft SMTP Server id 15.1.2044.4 via Frontend Transport; Mon, 24 Aug 2020 03:28:42 +0000 X-Inumbo-ID: db653abf-4213-4d15-be38-197771c511c4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=dCRNMai18oICp1g78MOkm0i99zbDOHtAX7WyMRefru4=; b=Z/VYTaApnlrkJ9dEuR4TgyEDloj18fO+yBiqrmiG1C7tdA43HGMjSJENMxelkwVLWsCqfS+GhDiQMTh5K5F+W75hXh+6Th85Y1/ZkUryoTs33V/hIi6a3RqKgjPqrBAXfjMntVNRVrMuUqR7a9ZGcohQhDP2fGPXCDAMmd7z7KQ= X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; lists.xenproject.org; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;lists.xenproject.org; dmarc=bestguesspass action=none header.from=arm.com; Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; X-CheckRecipientChecked: true X-CR-MTA-CID: b9144900e4aa8f0e X-CR-MTA-TID: 64aa7808 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Mrtt4Uk+uc3P6Lg9tUAwWkOJJgA+20/ShJCsdB1tzA2zN9TAQSbx1/lnxBKlv1aWMpxLJ/5MWLc8araoNwH7/fnPDsBu11NMHM0o2d3keNyvMBJWWdqkPFkhkM4C0yDNg6HbJEV/srIAqSQy4M9v7Lv1hlz4AO72YNh5cqfFdC7EQzglm2VpuAbsWMAWwY9z33jqfhL8dvKpIsEox4CXxMXXCXattSGMVdW9B284kbgkAOV4Hi2syikMKsUv7yJMbhYNTsf9KhShZNzzhv+h/TDIxADAkBix6F1tr8YVrz4rBM+n8lr85jmWWb2D5oQqYFaktIIB/po/A8Tl7YgarQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=dCRNMai18oICp1g78MOkm0i99zbDOHtAX7WyMRefru4=; b=j2V/2ZTz2JiSDou4owMmkZVYkUH8JPtcOvY0IwD6pWGS04Bg9iGdTFLE0aeNwXPwLJR+pRzXtezRaySG7MLg7+KjWo86yOhTHbVT44CjnOk99vI903eltTg4gDXsLNhPkXP+5P/ZrjLJ3GD8k6TWzuTbmBZZl4q63I90su4LVjGU1dN2n7J4g0017Kp/Ky7A6Rpk08Eax7rEDj6BBw5fgRWkFfWvqTTdT+F5iW37xg9pBETevfnxGP3hVlBJQjbTyJcqvFPkOyDKBKcLwKEobh4RNCUJCPfl4z1mOGNUaXcGS5Mfu/9+nI81ChGNcsE3l0TNJZe2mvHntWCiLSLNeA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=arm.com; dmarc=bestguesspass action=none header.from=arm.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=dCRNMai18oICp1g78MOkm0i99zbDOHtAX7WyMRefru4=; b=Z/VYTaApnlrkJ9dEuR4TgyEDloj18fO+yBiqrmiG1C7tdA43HGMjSJENMxelkwVLWsCqfS+GhDiQMTh5K5F+W75hXh+6Th85Y1/ZkUryoTs33V/hIi6a3RqKgjPqrBAXfjMntVNRVrMuUqR7a9ZGcohQhDP2fGPXCDAMmd7z7KQ= X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; lists.xenproject.org; dkim=none (message not signed) header.d=none;lists.xenproject.org; dmarc=bestguesspass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 40.67.248.234 as permitted sender) receiver=protection.outlook.com; client-ip=40.67.248.234; helo=nebula.arm.com; From: Wei Chen To: , , CC: , , , , Subject: [PATCH v2 2/2] xen/arm: Throw messages for unknown FP/SIMD implement ID Date: Mon, 24 Aug 2020 03:28:25 +0000 Message-ID: <20200824032825.18368-3-wei.chen@arm.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200824032825.18368-1-wei.chen@arm.com> References: <20200824032825.18368-1-wei.chen@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-Office365-Filtering-HT: Tenant X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: ca215c0f-ac23-4983-29b4-08d847ddd404 X-MS-TrafficTypeDiagnostic: AM6PR08MB5237:|AM7PR08MB5317: X-Microsoft-Antispam-PRVS: x-checkrecipientrouted: true NoDisclaimer: true X-MS-Oob-TLC-OOBClassifiers: OLM:820;OLM:820; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: BloRpppD5GedbW79R4Ao7vY0VsT6bbIeQJgQe2Cxrj3Vartgh8PcuTOLurmzmpraNsQBiZJYeTs3E1tTRxvsJnXStU9cRspi3IIz5Vd1NL8PXdUKItNkzWP/MOuIFSdop6tV5Q2cmI1IYCyjWo2MIRgVtzcMlfpWulAKbI245vTqwp1SpZBg2HQbUfVKs8dFNm5ILHhMKdVhcwuSKBUvolhC9I3UkPavbVIimHRvYParco6Qd66VsfxzBJ7T7tFpRSv+BL+i4FWr9IRYf/yvQE8E5UcDpaeuJyQM5pYuqhrEEjlj1n8sX28hIClnG+oY3fHKBz3kDprPMYPgl0n1T+6vA/RjxF5M+/8ZbKuxQ+gaR41dYK8zxff9QRTdIvQHCyYD407wUfQwv6bwGTA1yw== X-Forefront-Antispam-Report-Untrusted: CIP:40.67.248.234; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(4636009)(39850400004)(396003)(376002)(136003)(346002)(46966005)(110136005)(5660300002)(4326008)(54906003)(36756003)(2906002)(44832011)(478600001)(1076003)(6666004)(70586007)(70206006)(86362001)(356005)(2616005)(47076004)(336012)(26005)(186003)(15650500001)(82310400002)(83380400001)(8936002)(82740400003)(316002)(426003)(8676002)(81166007); DIR:OUT; SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR08MB5237 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DB5EUR03FT020.eop-EUR03.prod.protection.outlook.com X-MS-Office365-Filtering-Correlation-Id-Prvs: 5792733a-f070-4ee9-88d0-08d847ddcfc8 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: OwcySJ8QeOxz3l6OyVLgdpWycLDMxl5MMq2W2bsdBXDjuo6/N9J7w8ElULiM/ySvzkX28Fhkt8QtEnYcFcUY0L/MFV/Qj/jHYJ7zipetncZs1Va1VP1cfnU0mNv/KlapHQ7pvfrzFsHVjAVi45wwCaECu1cn4rPF9xrqzzhX5OtuFv+EZG1cSFE2/nbhg98yZYq56N+JSxOkeVz6wr21c9T5T8f/YSJCP/1axifS7p8mrgBG9LuvrTCpWkUNtHNiBYq+GeGzDq+lXbqaUOrCbZIqJWdp8yCv5jQGFNCVYZ3yWGXraRrsJ6HCoNaEmopsU9OGmF/suBY4MOJRexKWFcktzOxa+rrFn44mBmoOpC42dYxqmtkjfradwuBHAjIL700Qvm7vUDWv34RJBvF0Ig== X-Forefront-Antispam-Report: CIP:63.35.35.123; CTRY:IE; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:64aa7808-outbound-1.mta.getcheckrecipient.com; PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com; CAT:NONE; SFS:(4636009)(396003)(136003)(346002)(39850400004)(376002)(46966005)(4326008)(82740400003)(70586007)(82310400002)(2616005)(426003)(86362001)(6666004)(70206006)(83380400001)(44832011)(336012)(36756003)(5660300002)(8936002)(1076003)(8676002)(2906002)(186003)(316002)(81166007)(478600001)(26005)(47076004)(54906003)(110136005)(15650500001); DIR:OUT; SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 24 Aug 2020 03:28:54.3242 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: ca215c0f-ac23-4983-29b4-08d847ddd404 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[63.35.35.123]; Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: DB5EUR03FT020.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM7PR08MB5317 X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" X-ZohoMail-DKIM: pass (identity @armh.onmicrosoft.com) Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Arm ID_AA64PFR0_EL1 register provides two fields to describe CPU FP/SIMD implementations. Currently, we exactly know the meaning of 0x0, 0x1 and 0xf of these fields. Xen treats value < 8 as FP/SIMD features presented. If there is a value 0x2 bumped in the future, Xen behaviors for value <=3D 0x1 can also take effect. But what Xen done for value <=3D 0x1 may not always cover new value 0x2 required. We throw these messages to break the silence when Xen detected unknown FP/SIMD IDs to notice user to check. Signed-off-by: Wei Chen Reviewed-by: Bertrand Marquis --- xen/arch/arm/setup.c | 26 ++++++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/xen/arch/arm/setup.c b/xen/arch/arm/setup.c index 7968cee47d..c7802d0e49 100644 --- a/xen/arch/arm/setup.c +++ b/xen/arch/arm/setup.c @@ -99,6 +99,28 @@ static const char * __initdata processor_implementers[] = =3D { ['i'] =3D "Intel Corporation", }; =20 +static const char * __initdata fp_implements[] =3D { + "Floating-point", + "Floating-point + half-precision floating-point arithmetic", + "Floating-point Unknown ID 0x2", + "Floating-point Unknown ID 0x3", + "Floating-point Unknown ID 0x4", + "Floating-point Unknown ID 0x5", + "Floating-point Unknown ID 0x6", + "Floating-point Unknown ID 0x7", +}; + +static const char * __initdata advsimd_implements[] =3D { + "AdvancedSIMD", + "AdvancedSIMD + half-precision floating-point arithmetic", + "AdvancedSIMD Unknown ID 0x2", + "AdvancedSIMD Unknown ID 0x3", + "AdvancedSIMD Unknown ID 0x4", + "AdvancedSIMD Unknown ID 0x5", + "AdvancedSIMD Unknown ID 0x6", + "AdvancedSIMD Unknown ID 0x7", +}; + static void __init processor_id(void) { const char *implementer =3D "Unknown"; @@ -129,8 +151,8 @@ static void __init processor_id(void) cpu_has_el1_32 ? "64+32" : cpu_has_el1_64 ? "64" : "No", cpu_has_el0_32 ? "64+32" : cpu_has_el0_64 ? "64" : "No"); printk(" Extensions:%s%s%s\n", - cpu_has_fp ? " FloatingPoint" : "", - cpu_has_simd ? " AdvancedSIMD" : "", + cpu_has_fp ? fp_implements[boot_cpu_feature64(fp)] : "", + cpu_has_simd ? advsimd_implements[boot_cpu_feature64(simd)] : "= ", cpu_has_gicv3 ? " GICv3-SysReg" : ""); =20 printk(" Debug Features: %016"PRIx64" %016"PRIx64"\n", --=20 2.17.1