From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail03.groups.io (mail03.groups.io [45.79.227.220]) by spool.mail.gandi.net (Postfix) with ESMTPS id 267D6AC1411 for ; Fri, 12 Apr 2024 14:34:01 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=Us2HWdU2M0sqqpAiJK2n51Mi/Qd5JL/fImSZTvoEalA=; c=relaxed/simple; d=groups.io; h=Received-SPF:Received-SPF:From:To:CC:Subject:Date:Message-ID:In-Reply-To:References:MIME-Version:NoDisclaimer:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Resent-Date:Resent-From:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Type; s=20240206; t=1712932440; v=1; b=kkpfBka/5lvf7LQHDwuF65uBOVWXrukK/BmeazI52LQT7aAx9M2gCq/RsDjypQfvpjILJ+7E KBv2SA3er61kWd1+5Tr5gWT+xEgpX+N9ChUn+pQth1Nnli1xqgYnm44Dro9vzFJ/VzlEVXUVZml K53FIjus5+B7vSeDOfS5K0wECT4OKb7liYb+1T9cWmNbkZDMv4AbjHaYAZSU94TthBORRFt20ZX snQ7jIGx9N65i6RsU3ozAiUTx/fPwuNeInNMivUAxMY9YdA8du0Jp7xWEMH5pN3b1Qe4cKIRW/o 9ij69ls1+C3aIr4QxM2hVxbsFAGMrOlgcO8vZAHtATb4g== X-Received: by 127.0.0.2 with SMTP id FgoyYY7687511xkXNQzaW4v6; Fri, 12 Apr 2024 07:34:00 -0700 X-Received: from EUR04-DB3-obe.outbound.protection.outlook.com (EUR04-DB3-obe.outbound.protection.outlook.com [40.107.6.61]) by mx.groups.io with SMTP id smtpd.web10.48539.1712932433804593194 for ; Fri, 12 Apr 2024 07:33:54 -0700 X-Received: from DUZPR01CA0088.eurprd01.prod.exchangelabs.com (2603:10a6:10:46a::14) by AM0PR08MB5364.eurprd08.prod.outlook.com (2603:10a6:208:186::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.55; Fri, 12 Apr 2024 14:33:50 +0000 X-Received: from DU2PEPF0001E9C2.eurprd03.prod.outlook.com (2603:10a6:10:46a:cafe::72) by DUZPR01CA0088.outlook.office365.com (2603:10a6:10:46a::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7472.26 via Frontend Transport; Fri, 12 Apr 2024 14:33:50 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;dmarc=pass action=none header.from=arm.com; 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; pr=C X-Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by DU2PEPF0001E9C2.mail.protection.outlook.com (10.167.8.71) with Microsoft SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.7452.22 via Frontend Transport; Fri, 12 Apr 2024 14:33:50 +0000 X-Received: ("Tessian outbound e14047529286:v313"); Fri, 12 Apr 2024 14:33:50 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: e47051892c3e9dcb X-CR-MTA-TID: 64aa7808 X-Received: from 50ae5e3951f2.2 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 42A17D5C-ED50-4FDA-B528-1C47687FB548.1; Fri, 12 Apr 2024 14:33:38 +0000 X-Received: from EUR05-DB8-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 50ae5e3951f2.2 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Fri, 12 Apr 2024 14:33:38 +0000 X-Received: from DB8P191CA0021.EURP191.PROD.OUTLOOK.COM (2603:10a6:10:130::31) by GVXPR08MB10713.eurprd08.prod.outlook.com (2603:10a6:150:14c::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.47; Fri, 12 Apr 2024 14:33:36 +0000 X-Received: from DU6PEPF00009529.eurprd02.prod.outlook.com (2603:10a6:10:130:cafe::da) by DB8P191CA0021.outlook.office365.com (2603:10a6:10:130::31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7452.36 via Frontend Transport; Fri, 12 Apr 2024 14:33:35 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; dkim=none (message not signed) header.d=none;dmarc=pass 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; pr=C X-Received: from nebula.arm.com (40.67.248.234) by DU6PEPF00009529.mail.protection.outlook.com (10.167.8.10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.7452.22 via Frontend Transport; Fri, 12 Apr 2024 14:33:35 +0000 X-Received: from AZ-NEU-EX04.Arm.com (10.251.24.32) by AZ-NEU-EX04.Arm.com (10.251.24.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Fri, 12 Apr 2024 14:33:33 +0000 X-Received: from E114225.Arm.com (10.1.196.56) by mail.arm.com (10.251.24.32) with Microsoft SMTP Server id 15.1.2507.35 via Frontend Transport; Fri, 12 Apr 2024 14:33:33 +0000 From: "Sami Mujawar" To: CC: Sami Mujawar , , , , , , , Subject: [edk2-devel] [PATCH v2 17/45] ArmVirtPkg: Xen: Add a NULL implementation of ArmCcaConfigureMmio Date: Fri, 12 Apr 2024 15:32:54 +0100 Message-ID: <20240412143322.5244-18-sami.mujawar@arm.com> In-Reply-To: <20240412143322.5244-1-sami.mujawar@arm.com> References: <20240412143322.5244-1-sami.mujawar@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DU6PEPF00009529:EE_|GVXPR08MB10713:EE_|DU2PEPF0001E9C2:EE_|AM0PR08MB5364:EE_ X-MS-Office365-Filtering-Correlation-Id: eceb8456-4765-4299-ec89-08dc5afd922d x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: 1rkVSEu6hhCpSPwwtkMwFc/ev4Ul5NCaRHKKe2HbfaRLLR6r0g15wAFIDHaVg6puvXOF9/P5r++c+cwdT47rNodpqyV0DNm8sWTQmwqhUCzWxGyVASH4M2CANYg0QqNbgFWDGuwBf+tt3Je15OHR7EQs/ncJ33vnzGeSBcqFUV5SnwURXFp27JlM9qsjEEpYuKcS8RRP+HZOsgiY1XOC84WRMpiCWC17Vtz+aXTa0v6CBga+tztM+Eh3eDqRNX9aGIROaa/oA0wbCbHsvMNl6GZ10t8o+DiWZg8/fdR1cSTwneFiINtNEIojbR7+yoXpdLLZ2ecOnPIQDxqP24KUtef8kk/wdxU1OsO0tcUefALgEmDpUezARpt2mLwX0OIK34mDo33WEX2n2Doo7rUfzfZlIBvyz3u8rIjV/ENfLp6s3KaaKMDFH35I8fORR0SLO/+HHRxYkCFd8R7AobLHtRyYd5HLtXSPL40InvH5PTFVFSzbIbtHA3XxnJVXS6ydDQe1dT5yhdgAe0bvm4D7Qzy5PIGSURHTN+FH3OBBLK1vOrx4xQYA7dDKZIZs7mM1p/0h1NiYtnWGifb6vVCKms8Q/FmwYoUhLc4UjpIHe2Sn11CvG/+VczhaJ17Y9SKGjDCleR/atwNahwpR/+OA2iS5SxnP+SNguoIdU+4gZtgnuJdQ0S5EhrFN8m3aJ6xgB2sASwf91bQtFBFPKl4LY7HDAetYlVqSOesEkhwFRfBhBaQJfFfDwKBmMbWRVh6k 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:(13230031)(1800799015)(376005)(36860700004)(82310400014);DIR:OUT;SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: GVXPR08MB10713 X-MS-Exchange-Transport-CrossTenantHeadersStripped: DU2PEPF0001E9C2.eurprd03.prod.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 554b2c63-cb6c-4668-782c-08dc5afd895f X-Microsoft-Antispam-Message-Info: mietJTKd4Xw8vUNbHnvZhkSTT/I+JX8PBFDb/mfbyxOJ+u70ulAESchqvEK9AaTwfqHm9pBZ3mUVn1/MjvhxlZGamXb1jX0MwiEd/kHYy18Ez3fGDvWn/6LYkkOzsWcEcptNWwomU710LsTXkKJ8/DxkK3PmgbQ2+PdYqo112tozOhtI9RMueQ9hGMuL7s60/7DCy10wBl4tP2hKHeAaE7eahRj/Ba74K3ZZ/Fw8AliW36CRHOoVeKi2FFFL6J6aoIryowbXMG4VqfDDCaJO4fn7MT9sz5mIjjiKCjfYhy0YhC2nxauidUZMKTt8XchdRcW10TMCkCt8Jci6kpqGEpOa2ZXPXlzkXY9c2pyE+If1sS/th+mP9YbifLewWAISkUYCnwLcpXifv1UOg/BOU0wHT6q8eaHIL4zf6EAGS1SwtHzyCBFmFZ0fNrXIFRKuuafc/4OxepqZG2vG8s1Jzlq4OqqU2+sqxWW690Osu0XAkmGrvGdGoJ2QeIUb4KrJKSy3lkDkQEgpsQ/k8KCsSJWB96aE8bRMl182urIzK1LnrEJ5hY1uY9jbQ/5lxzX6pEoelAT/hkChs4x2H4xz0LxrLFrChq3rWuiPQLYi1ux6/LkNkAwTOR0PSJdikr+eXWGQPx85ky1sbN47XbilWKvnFypoUaxMZiJyo0aIcrqho246lCcrZOyk+jVFv80V28RtmKO3X23138wB+M5uI8VQ7qsQ08cPI7h04Y5OmpGG0592hjUV8XOrPLbkKXot X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 12 Apr 2024 14:33:50.5476 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: eceb8456-4765-4299-ec89-08dc5afd922d 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: DU2PEPF0001E9C2.eurprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM0PR08MB5364 Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Resent-Date: Fri, 12 Apr 2024 07:33:54 -0700 Resent-From: sami.mujawar@arm.com Reply-To: devel@edk2.groups.io,sami.mujawar@arm.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: 4yIloLvQm9Kpb6IdHPwcANStx7686176AA= Content-Type: text/plain X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20240206 header.b="kkpfBka/"; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=arm.com (policy=none); spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 45.79.227.220 as permitted sender) smtp.mailfrom=bounce@groups.io To support Arm CCA, a hook function ArmCcaConfigureMmio () has been added to the ArmVirtMemInfoLib library. Since, Arm CCA has not been enabled for the Xen guest firmware, update the XenVirtMemInfoLib library to add a NULL implementation for ArmCcaConfigureMmio () that returns RETURN_UNSUPPORTED. Cc: Ard Biesheuvel Cc: Leif Lindholm Cc: Gerd Hoffmann Signed-off-by: Sami Mujawar --- ArmVirtPkg/Library/XenVirtMemInfoLib/XenVirtMemInfoLib.c | 21 ++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/ArmVirtPkg/Library/XenVirtMemInfoLib/XenVirtMemInfoLib.c b/ArmVirtPkg/Library/XenVirtMemInfoLib/XenVirtMemInfoLib.c index ac0c75aecfe54090788836f2eea097f4abb112a3..8a9f6e1e1eee91ec2fc1418b342c0966548e8a6c 100644 --- a/ArmVirtPkg/Library/XenVirtMemInfoLib/XenVirtMemInfoLib.c +++ b/ArmVirtPkg/Library/XenVirtMemInfoLib/XenVirtMemInfoLib.c @@ -1,6 +1,7 @@ /** @file Copyright (c) 2014-2017, Linaro Limited. All rights reserved. + Copyright (c) 2023, Arm Limited. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent @@ -55,3 +56,23 @@ ArmVirtGetMemoryMap ( *VirtualMemoryMap = mVirtualMemoryTable; } + +/** + Configure the MMIO regions as shared with the VMM. + + Set the protection attribute for the MMIO regions as Unprotected IPA. + + @param[in] IpaWidth IPA width of the Realm. + + @retval RETURN_SUCCESS Success. + @retval RETURN_INVALID_PARAMETER A parameter is invalid. + @retval RETURN_UNSUPPORTED The execution context is not in a Realm. +**/ +EFI_STATUS +EFIAPI +ArmCcaConfigureMmio ( + IN UINT64 IpaWidth + ) +{ + return RETURN_UNSUPPORTED; +} -- 'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)' -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#117685): https://edk2.groups.io/g/devel/message/117685 Mute This Topic: https://groups.io/mt/105483424/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=-