From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from EUR05-VI1-obe.outbound.protection.outlook.com (EUR05-VI1-obe.outbound.protection.outlook.com [40.107.21.49]) by mx.groups.io with SMTP id smtpd.web12.10211.1657817467311074588 for ; Thu, 14 Jul 2022 09:51:08 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=lWpyeufN; spf=pass (domain: arm.com, ip: 40.107.21.49, mailfrom: sami.mujawar@arm.com) ARC-Seal: i=2; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=pass; b=i32jLGHhFW5kgVN1RNP5djXDBptr7gJsZBJuPMc1nvWmKJQP+Lm6uZZbPue4pnVstPYpeQy0jS9V/ckN8PjYOVHNLF8yTEPkzUw6CULdQFMUhfFogAwdnnFB4EMfOf+dfmmc1YjNXHyX3wOrfkIPw9tw+aik1aVXijp8Up5zAzVaFFUAIx8Gi4ZfDNXKsMPQDz/Qx2Fx4zm19dDTl9LlDPNWmt6Tea88KYjYxB/mimhvILtVIxm2JLYYwgMymKzch17rTtDZ+fcBPvurJ66w0uYempYqyi/TFh7Puh9BRl171dbpEz6s11q9W0xefZdvbApRfNxDmP9u6c+4MF4bUg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=n8vBl9txkyUIHA2mpg9lyKACfgYX5N7XwLZ7SZYlvT4=; b=eu4N7piFpzX+NERArPY6PTZB0teiOb7mrKspGxKuRS6mpzG2yXDmxLvOGu+76Zxvam3T47MtHuHqNvn3Y4bTFw72x2Na21AAUbtEO9Xz9E8fVSB+sa0R4QcbeVWpZQU8x7NAc8sI5d34W8FJYicTCw8gwjeGPmjyY2iLW4K6rkpGCvm+wf3PkvOQ6NGebzVFAHa8aVeESVEyTId9SlQBFmC/vH9k1QqZ2dHOVRUUi5Hud/OQMwB+yx8gro0WntaTc0iMpgV7C7vQX3LgDsNRJfWf9rCKT0J4/d6Y3xriJ7OEJku4jpvd3x4ayD7YSSK8D/HyBoOGWohqlDKgEI/Avg== ARC-Authentication-Results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 63.35.35.123) smtp.rcpttodomain=edk2.groups.io smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dmarc=[1,1,header.from=arm.com]) 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=n8vBl9txkyUIHA2mpg9lyKACfgYX5N7XwLZ7SZYlvT4=; b=lWpyeufNxQ5kZW+IDgjToMpRvvvx52PIu27ZF3sxKlfuooh7fbLsxdvsGgxvRonjJowrJkVQugDLqrfLxFVIggjDKR2bDz6av6nKhhlNRJTVf8CZaJxOdNHdRzRaNqXBWRFuV95PKYB5FR+fgIxa+Nv+5CMRmQ2ABbpqbgU78GQ= Received: from AS8PR04CA0043.eurprd04.prod.outlook.com (2603:10a6:20b:312::18) by AM6PR08MB4309.eurprd08.prod.outlook.com (2603:10a6:20b:bb::12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5417.25; Thu, 14 Jul 2022 16:51:03 +0000 Received: from VE1EUR03FT022.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:312:cafe::58) by AS8PR04CA0043.outlook.office365.com (2603:10a6:20b:312::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5438.14 via Frontend Transport; Thu, 14 Jul 2022 16:51:03 +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 Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by VE1EUR03FT022.mail.protection.outlook.com (10.152.18.64) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5417.15 via Frontend Transport; Thu, 14 Jul 2022 16:51:02 +0000 Received: ("Tessian outbound e5f49c5d38f9:v122"); Thu, 14 Jul 2022 16:51:01 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: 7ac79a9e7dc744a6 X-CR-MTA-TID: 64aa7808 Received: from 58c20011c0fa.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 856F3DC2-90BD-4696-9100-CF523A5939AB.1; Thu, 14 Jul 2022 16:50:56 +0000 Received: from EUR05-DB8-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 58c20011c0fa.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Thu, 14 Jul 2022 16:50:56 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=AI6K2BgMlVaI2lPEJGXWnIEj/CpBDmPC85+BDH2txSylkR+0oB+9IY7b6d6BTCZQst7dSJczwuD735Xq1XVRWCTU9uQscp7Tm2HY0S23xkq2d9h0vOuCGtiV4nowCpzlZrxT4XTeDQNdCPlLjciwTZ8T45lzt8t5YElNZou1ypiOo/cT+7KiMXqKxiVxtwxHp7Tt4NMSuJwZ0RSCUz+lXAIw+EDTeLorcE7DiZP/AsWA5Er2mW/armS9hxvN9ZRzcbviRFDXwboM8R5bOJKAMog+clOiRnSEzctd1VC/Nj2wNtGc3EOBaj76/LIJ3GxtO3DFshSAPCa+wrdtEfZe7g== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=n8vBl9txkyUIHA2mpg9lyKACfgYX5N7XwLZ7SZYlvT4=; b=Zt2JSMgxW3X5KOHAZ0BffyAVLVtMSzTw4aVkCVW2eWxkjq8zVi9ZB+qYKQz1SFxUOOsjGotjvL2Z81mdeopc6Fdmu9fZHpelolszMtYlwKaFJRcxF96z1QGTpgRFewfnMI436Rg1CvM0WIx74haMnIniFWS1wy5UrUqapmR+ds0v9Im3frRtes2pna5xWrstXn1l5rx+SNhBZoSPcIWRWdLNktuNWPvSPNh2irmaPCk3WszLdTbnslnvLZM1P+mEZhcw9J1uP2yJ3ZAVVgzIK3HPBEVkC2tRche3CQoU8YnUKSE7rFF2bNWEj3ryOrYXkLtPdGLQ6AqcPsPBQe044A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=edk2.groups.io smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) 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=n8vBl9txkyUIHA2mpg9lyKACfgYX5N7XwLZ7SZYlvT4=; b=lWpyeufNxQ5kZW+IDgjToMpRvvvx52PIu27ZF3sxKlfuooh7fbLsxdvsGgxvRonjJowrJkVQugDLqrfLxFVIggjDKR2bDz6av6nKhhlNRJTVf8CZaJxOdNHdRzRaNqXBWRFuV95PKYB5FR+fgIxa+Nv+5CMRmQ2ABbpqbgU78GQ= Received: from AS9PR06CA0588.eurprd06.prod.outlook.com (2603:10a6:20b:486::28) by DB8PR08MB5322.eurprd08.prod.outlook.com (2603:10a6:10:114::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5417.20; Thu, 14 Jul 2022 16:50:54 +0000 Received: from AM5EUR03FT012.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:486:cafe::d9) by AS9PR06CA0588.outlook.office365.com (2603:10a6:20b:486::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5438.17 via Frontend Transport; Thu, 14 Jul 2022 16:50:53 +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 Received: from nebula.arm.com (40.67.248.234) by AM5EUR03FT012.mail.protection.outlook.com (10.152.16.161) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.5417.15 via Frontend Transport; Thu, 14 Jul 2022 16:50:53 +0000 Received: from AZ-NEU-EX01.Emea.Arm.com (10.251.26.4) by AZ-NEU-EX03.Arm.com (10.251.24.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.2507.9; Thu, 14 Jul 2022 16:50:41 +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.2507.9; Thu, 14 Jul 2022 16:50:41 +0000 Received: from E114225.Arm.com (10.1.196.36) by mail.arm.com (10.251.24.32) with Microsoft SMTP Server id 15.1.2507.9 via Frontend Transport; Thu, 14 Jul 2022 16:50:40 +0000 From: "Sami Mujawar" To: CC: Sami Mujawar , , , , , , , , , , , , , , , Subject: [PATCH v6 5/8] MdePkg: IORT header update for IORT Rev E.d spec Date: Thu, 14 Jul 2022 17:50:28 +0100 Message-ID: <20220714165031.42640-6-sami.mujawar@arm.com> X-Mailer: git-send-email 2.16.2.windows.1 In-Reply-To: <20220714165031.42640-1-sami.mujawar@arm.com> References: <20220714165031.42640-1-sami.mujawar@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-Office365-Filtering-Correlation-Id: 8e1cc33e-9707-4c0f-02ea-08da65b9093c X-MS-TrafficTypeDiagnostic: DB8PR08MB5322:EE_|VE1EUR03FT022:EE_|AM6PR08MB4309:EE_ 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: K3lzQRqFa5TuE1u77D34oKaBod436qYW6t6YAMREoAPBvWDSD66RvPuWGlIH3jg6QVWMPMsadTs2kBz+3hrgJInef5PtO//+abORhEFzAsh3B97LT4UM9aYFjg9+g2Spw4qB6tFIvpWsb7CbJeuedyhLZzXIWhre3BpvPdxM+6cPTzwVGmBHoGpqOSf4JbhWm0lbyi6XYtXWDztOcbYmA0FGIoF5QenL+uGHN7yk7tn4hJBzVhwyxJpSIZLtC0WBbdIgS3AmkYSD739VaH2y8LB0nICZSRbiVSd3mbCFNDLGmya4HcJRjZx8H3elHQEa/w9Qgsn5A+CX8fTP53R7+Cr/+ApFsi4x1SrS895+y/0pRZYJI5IcJpEQNkej7eE0guk1kSoQHdVhdtV3oH1GUCXOjUOtGisi6IqIZn98jA5tcNhwz/pvDn8x8T5RdbyxrC8DlKrTgZW9sYfjyzTXpw0cbk9qjm3SMJoft8j1duhfiI7HLRYUVVZSWiVxoslPEUTsqEe/RcCAZufCXZVeIjDgkxZn2gGPFMZWvoOS1Y5Rc50P/1t2HUr03oj/e00yZnuICeH9+JvxNX+uYIDnJxLQvLKAG5BUlbu/dvQSQEUjQBESAfYonGOXEWASM+qOxpFtOWdtUFAoMaJKArMeI3x6URNg9hmr3tVafatQV7oHtEczF30Zun2SRGmrRuaG37Z273IrU1c4kLxlFoTRH48fq15gyKZL1FxHf7yvFO7dBbqpStOU1maDmhzjeETTikcir41SN+a4eaG7eD9FBKRKFNf38IL5FzOR4sJ2ruqzE6TZbgyj243NMiaGqFEwpeB1I2ioVecueivAgz39bvCSXAuDzeuTueoJ2oQbD7PriqRLWgE8FVl2Ry74zERIHy2qdxwitOzHW3Jyl9b2MR0UJScQwIOkNFtcHGRsBgs= 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:(13230016)(4636009)(136003)(39860400002)(376002)(396003)(346002)(46966006)(40470700004)(36840700001)(30864003)(47076005)(336012)(44832011)(15650500001)(8936002)(82310400005)(2906002)(356005)(26005)(40480700001)(40460700003)(86362001)(5660300002)(83380400001)(82740400003)(36860700001)(36756003)(6916009)(426003)(41300700001)(54906003)(316002)(70586007)(478600001)(81166007)(966005)(7696005)(8676002)(1076003)(4326008)(186003)(6666004)(2616005)(70206006)(36900700001);DIR:OUT;SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB8PR08MB5322 Return-Path: Sami.Mujawar@arm.com X-MS-Exchange-Transport-CrossTenantHeadersStripped: VE1EUR03FT022.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: 0906e140-92e2-454b-be77-08da65b903fb X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: sqZwK4sWCw9cEEe7cBYUpvaFN5g8mQIBkWFO4JYxz3BaT+shRBckrD2WlULFoQG6zIYdcUA9AasskGDwvx1AtMR8tdWknVacXaIcXsOrzeJXasRkDaRVfOgTfZUoVZPnH7mEdN0Rzip7MvQpY7YZBW2hnliN1KpTQgPmaa9C/PmyTvgtSMZnl47xOzVF79U4oe4i6isfdnHWq2oqg3I5Oc4zTrGyz9fkJhFgQDsCVG5bE8yRMuBmRrbsnlok6sXxln8fAO3AxF+41ZEg6nGBSzK6Eb09if7pR6A68NwIa0J3QDW8A9KdUn3OviKol5CUL68LnuohcNLgwhxIaoBBBRpLeAuhNl39k/csyGuONARXNA6PSGODYaq69vRhWz3jtlo1RML+i+XdFceHv4vjcBZHP+2fHhUPmTNU3Yq1RQByy9epXUNrJBoe8QbUh+k2tCh8IRdz1jpgmGyQlquPalYbHjuBwTaLrkahZjgger7mZgnLLsToGrHMWR//z8lXiibf1TMZfw8rqSu1dR9E8dIW0ToPQAatCHd8E1JwqLCZIN4+L+/w2iCRsrnrJJRAB8B4qoeZ0F59WpIH+UxLJ9Q4ayh0ztjECWjh5zFwLIUOmhXzcARvsyHlptloiKBOy8Y66OW/OTOLcP6TWPIk/kbCUJ9i0uNgE0tzlyHBIJzfJ5ZvU3S9yIstLy+MU9K3gmItZFdpJOEwsM92QnwhlXrtvoAzOaVmVvu2dtXq2mqauzNKB6deROCRA6VV1dO/3yIxPHZt4iMBB1s4bl7Gm+vBLJgJ3cFx6ovelkNC9IGdewQGEigGl9vtx8/hCFd3f6UBmXzDmF9kbra+MK/lGcBMNhmaYbxunQYrRbL9ePKWELH/1pOd8qV94QXFn+kj 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:(13230016)(4636009)(396003)(39860400002)(346002)(376002)(136003)(46966006)(36840700001)(40470700004)(82740400003)(6916009)(1076003)(26005)(6666004)(15650500001)(2616005)(316002)(44832011)(966005)(2906002)(8676002)(70206006)(81166007)(478600001)(4326008)(40460700003)(7696005)(54906003)(41300700001)(70586007)(40480700001)(5660300002)(36756003)(8936002)(86362001)(30864003)(336012)(82310400005)(426003)(36860700001)(83380400001)(186003)(47076005);DIR:OUT;SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Jul 2022 16:51:02.3223 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 8e1cc33e-9707-4c0f-02ea-08da65b9093c 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: VE1EUR03FT022.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR08MB4309 Content-Type: text/plain Bugzilla: 3458 - Add support IORT Rev E.d specification updates (https://bugzilla.tianocore.org/show_bug.cgi?id=3458) The IO Remapping Table, Platform Design Document, Revision E.d, Feb 2022 (https://developer.arm.com/documentation/den0049/) introduces the following updates, collectively including the updates and errata fixes to Rev E, Rev E.a, Rev E.b, Rev E.c: - increments the IORT table revision to 5. - updates the node definition to add an 'Identifier' field. - adds definition of node type 6 - Reserved Memory Range node. - adds definition for Memory Range Descriptors. - adds flag to indicate PRI support for root complexes. - adds flag to indicate if the root complex supports forwarding of PASID information on translated transactions to the SMMU. - adds flag to indicate if the root complex supports PASID. - adds flags to define access privilege and attributes for the memory ranges. Therefore, update the IORT header file to reflect these changes, and also rename the EFI_ACPI_IO_REMAPPING_TABLE_REVISION macro to EFI_ACPI_IO_REMAPPING_TABLE_REVISION_00. Also update the IORT generator in DynamicTablesPkg to fix the compilation errors so that Git Bisect can work. Signed-off-by: Sami Mujawar Reviewed-by: Liming Gao --- Notes: v6: - Add definition for IORT Rev 4 and RMR Node Rev 2. [PIERRE] - Added definition for IORT Rev 4 and RMR Node 2 so that [SAMI] appropriate checks can be performed for deprecated table/node revisions. v5: - Change IORT revision macro name to make it similar to [THOMAS] macro names for other ACPI tables. - Updated IORT revision macros from [SAMI] EFI_ACPI_IO_REMAPPING_TABLE_REVx to EFI_ACPI_IO_REMAPPING_TABLE_REVISION_0x Ref: https://edk2.groups.io/g/devel/message/91119 - Keep EFI_ACPI_IO_REMAPPING_TABLE_REVISION and set to [LIMING] EFI_ACPI_IO_REMAPPING_TABLE_REVISION_05. Ref: https://edk2.groups.io/g/devel/message/91137 - Added EFI_ACPI_IO_REMAPPING_TABLE_REVISION and set it [SAMI] to the latest IORT revision. - Updated IORT generator in DynamicTablesPkg and included [SAMI] in this patch so that Git bisect does not break. v4: - Updated patch series to IORT specification revision E.d. [SAMI] - Add flag to indicate if the root complex supports PASID. [SAMI] - Add flags to define access privilege and attributes for [SAMI] the memory ranges. v3: - Submit patch series to update platform code to use the [LIMING] EFI_ACPI_IO_REMAPPING_TABLE_REV0 macro. Ref: https://edk2.groups.io/g/devel/topic/83618423#76799 - Removed definition of EFI_ACPI_IO_REMAPPING_TABLE_REVISION [SAMI] as EFI_ACPI_IO_REMAPPING_TABLE_REV0 has been provided for representing Rev 0. Also, a corresponding patch series for updating the platforms in edk2-platforms repository shall be submitted to the edk2 mailing list. - Include r-b received from v2 series. [SAMI] Ref: https://edk2.groups.io/g/devel/topic/83600724#76660 v2: - Set EFI_ACPI_IO_REMAPPING_TABLE_REVISION to Rev 0 as [SAMI] setting to Rev 3 will break existing platforms. The problem is that existing code would not be populating the Identifier field in the nodes. This can lead to non-unique values in the Identifier field. DynamicTablesPkg/Library/Acpi/Arm/AcpiIortLibArm/IortGenerator.c | 19 ++--- MdePkg/Include/IndustryStandard/IoRemappingTable.h | 86 ++++++++++++++++++-- 2 files changed, 87 insertions(+), 18 deletions(-) diff --git a/DynamicTablesPkg/Library/Acpi/Arm/AcpiIortLibArm/IortGenerator.c b/DynamicTablesPkg/Library/Acpi/Arm/AcpiIortLibArm/IortGenerator.c index abef9e5a7f90a38e1d697227d3cd2c110db364a4..63381441e2d6515a7cc9731c89b9739a12c65599 100644 --- a/DynamicTablesPkg/Library/Acpi/Arm/AcpiIortLibArm/IortGenerator.c +++ b/DynamicTablesPkg/Library/Acpi/Arm/AcpiIortLibArm/IortGenerator.c @@ -766,7 +766,7 @@ AddItsGroupNodes ( ItsGroupNode->Node.Type = EFI_ACPI_IORT_TYPE_ITS_GROUP; ItsGroupNode->Node.Length = (UINT16)NodeLength; ItsGroupNode->Node.Revision = 0; - ItsGroupNode->Node.Reserved = EFI_ACPI_RESERVED_DWORD; + ItsGroupNode->Node.Identifier = EFI_ACPI_RESERVED_DWORD; ItsGroupNode->Node.NumIdMappings = 0; ItsGroupNode->Node.IdReference = 0; @@ -872,7 +872,7 @@ AddNamedComponentNodes ( NcNode->Node.Type = EFI_ACPI_IORT_TYPE_NAMED_COMP; NcNode->Node.Length = (UINT16)NodeLength; NcNode->Node.Revision = 2; - NcNode->Node.Reserved = EFI_ACPI_RESERVED_DWORD; + NcNode->Node.Identifier = EFI_ACPI_RESERVED_DWORD; NcNode->Node.NumIdMappings = NodeList->IdMappingCount; ObjectNameLength = AsciiStrLen (NodeList->ObjectName) + 1; @@ -1005,7 +1005,7 @@ AddRootComplexNodes ( RcNode->Node.Type = EFI_ACPI_IORT_TYPE_ROOT_COMPLEX; RcNode->Node.Length = (UINT16)NodeLength; RcNode->Node.Revision = 1; - RcNode->Node.Reserved = EFI_ACPI_RESERVED_DWORD; + RcNode->Node.Identifier = EFI_ACPI_RESERVED_DWORD; RcNode->Node.NumIdMappings = NodeList->IdMappingCount; RcNode->Node.IdReference = (NodeList->IdMappingCount == 0) ? 0 : sizeof (EFI_ACPI_6_0_IO_REMAPPING_RC_NODE); @@ -1018,9 +1018,8 @@ AddRootComplexNodes ( RcNode->AtsAttribute = NodeList->AtsAttribute; RcNode->PciSegmentNumber = NodeList->PciSegmentNumber; RcNode->MemoryAddressSize = NodeList->MemoryAddressSize; + RcNode->PasidCapabilities = EFI_ACPI_RESERVED_WORD; RcNode->Reserved1[0] = EFI_ACPI_RESERVED_BYTE; - RcNode->Reserved1[1] = EFI_ACPI_RESERVED_BYTE; - RcNode->Reserved1[2] = EFI_ACPI_RESERVED_BYTE; if (NodeList->IdMappingCount > 0) { if (NodeList->IdMappingToken == CM_NULL_TOKEN) { @@ -1188,7 +1187,7 @@ AddSmmuV1V2Nodes ( SmmuNode->Node.Type = EFI_ACPI_IORT_TYPE_SMMUv1v2; SmmuNode->Node.Length = (UINT16)NodeLength; SmmuNode->Node.Revision = 0; - SmmuNode->Node.Reserved = EFI_ACPI_RESERVED_DWORD; + SmmuNode->Node.Identifier = EFI_ACPI_RESERVED_DWORD; SmmuNode->Node.NumIdMappings = NodeList->IdMappingCount; SmmuNode->Node.IdReference = (NodeList->IdMappingCount == 0) ? 0 : (sizeof (EFI_ACPI_6_0_IO_REMAPPING_SMMU_NODE) + @@ -1387,7 +1386,7 @@ AddSmmuV3Nodes ( SmmuV3Node->Node.Type = EFI_ACPI_IORT_TYPE_SMMUv3; SmmuV3Node->Node.Length = (UINT16)NodeLength; SmmuV3Node->Node.Revision = 2; - SmmuV3Node->Node.Reserved = EFI_ACPI_RESERVED_DWORD; + SmmuV3Node->Node.Identifier = EFI_ACPI_RESERVED_DWORD; SmmuV3Node->Node.NumIdMappings = NodeList->IdMappingCount; SmmuV3Node->Node.IdReference = (NodeList->IdMappingCount == 0) ? 0 : sizeof (EFI_ACPI_6_0_IO_REMAPPING_SMMU3_NODE); @@ -1518,7 +1517,7 @@ AddPmcgNodes ( PmcgNode->Node.Type = EFI_ACPI_IORT_TYPE_PMCG; PmcgNode->Node.Length = (UINT16)NodeLength; PmcgNode->Node.Revision = 1; - PmcgNode->Node.Reserved = EFI_ACPI_RESERVED_DWORD; + PmcgNode->Node.Identifier = EFI_ACPI_RESERVED_DWORD; PmcgNode->Node.NumIdMappings = NodeList->IdMappingCount; PmcgNode->Node.IdReference = (NodeList->IdMappingCount == 0) ? 0 : sizeof (EFI_ACPI_6_0_IO_REMAPPING_PMCG_NODE); @@ -2258,9 +2257,9 @@ ACPI_IORT_GENERATOR IortGenerator = { // ACPI Table Signature EFI_ACPI_6_2_IO_REMAPPING_TABLE_SIGNATURE, // ACPI Table Revision supported by this Generator - EFI_ACPI_IO_REMAPPING_TABLE_REVISION, + EFI_ACPI_IO_REMAPPING_TABLE_REVISION_00, // Minimum supported ACPI Table Revision - EFI_ACPI_IO_REMAPPING_TABLE_REVISION, + EFI_ACPI_IO_REMAPPING_TABLE_REVISION_00, // Creator ID TABLE_GENERATOR_CREATOR_ID_ARM, // Creator Revision diff --git a/MdePkg/Include/IndustryStandard/IoRemappingTable.h b/MdePkg/Include/IndustryStandard/IoRemappingTable.h index 79a34678681d45b2982dc8573db6bd447f42e429..f48a4a95cd71a147098dff33eff3096b52021990 100644 --- a/MdePkg/Include/IndustryStandard/IoRemappingTable.h +++ b/MdePkg/Include/IndustryStandard/IoRemappingTable.h @@ -1,12 +1,19 @@ /** @file - ACPI IO Remapping Table (IORT) as specified in ARM spec DEN0049D - - http://infocenter.arm.com/help/topic/com.arm.doc.den0049d/DEN0049D_IO_Remapping_Table.pdf + ACPI IO Remapping Table (IORT) definitions. Copyright (c) 2017, Linaro Limited. All rights reserved.
- Copyright (c) 2018, ARM Limited. All rights reserved.
+ Copyright (c) 2018 - 2022, Arm Limited. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent + + @par Reference(s): + - IO Remapping Table, Platform Design Document, Revision E.d, Feb 2022 + (https://developer.arm.com/documentation/den0049/) + + @par Glossary: + - Ref : Reference + - Mem : Memory + - Desc : Descriptor **/ #ifndef __IO_REMAPPING_TABLE_H__ @@ -14,7 +21,9 @@ #include -#define EFI_ACPI_IO_REMAPPING_TABLE_REVISION 0x0 +#define EFI_ACPI_IO_REMAPPING_TABLE_REVISION_00 0x0 +#define EFI_ACPI_IO_REMAPPING_TABLE_REVISION_04 0x4 // Deprecated +#define EFI_ACPI_IO_REMAPPING_TABLE_REVISION_05 0x5 #define EFI_ACPI_IORT_TYPE_ITS_GROUP 0x0 #define EFI_ACPI_IORT_TYPE_NAMED_COMP 0x1 @@ -22,6 +31,7 @@ #define EFI_ACPI_IORT_TYPE_SMMUv1v2 0x3 #define EFI_ACPI_IORT_TYPE_SMMUv3 0x4 #define EFI_ACPI_IORT_TYPE_PMCG 0x5 +#define EFI_ACPI_IORT_TYPE_RMR 0x6 #define EFI_ACPI_IORT_MEM_ACCESS_PROP_CCA BIT0 @@ -55,10 +65,34 @@ #define EFI_ACPI_IORT_SMMUv3_MODEL_CAVIUM_CN99XX 0x2 #define EFI_ACPI_IORT_ROOT_COMPLEX_ATS_UNSUPPORTED 0x0 -#define EFI_ACPI_IORT_ROOT_COMPLEX_ATS_SUPPORTED 0x1 +#define EFI_ACPI_IORT_ROOT_COMPLEX_ATS_SUPPORTED BIT0 + +#define EFI_ACPI_IORT_ROOT_COMPLEX_PRI_UNSUPPORTED 0x0 +#define EFI_ACPI_IORT_ROOT_COMPLEX_PRI_SUPPORTED BIT1 + +#define EFI_ACPI_IORT_ROOT_COMPLEX_PASID_FWD_UNSUPPORTED 0x0 +#define EFI_ACPI_IORT_ROOT_COMPLEX_PASID_FWD_SUPPORTED BIT2 + +#define EFI_ACPI_IORT_ROOT_COMPLEX_PASID_UNSUPPORTED 0x0 +#define EFI_ACPI_IORT_ROOT_COMPLEX_PASID_SUPPORTED BIT1 + +#define EFI_ACPI_IORT_RMR_REMAP_NOT_PERMITTED 0x0 +#define EFI_ACPI_IORT_RMR_REMAP_PERMITTED BIT0 + +#define EFI_ACPI_IORT_RMR_ACCESS_REQ_NOT_PRIVILEGED 0x0 +#define EFI_ACPI_IORT_RMR_ACCESS_REQ_PRIVILEGED BIT1 + +#define EFI_ACPI_IORT_RMR_ACCESS_ATTRIB_DEV_NGNRNE 0x0 +#define EFI_ACPI_IORT_RMR_ACCESS_ATTRIB_DEV_NGNRE 0x1 +#define EFI_ACPI_IORT_RMR_ACCESS_ATTRIB_DEV_NGRE 0x2 +#define EFI_ACPI_IORT_RMR_ACCESS_ATTRIB_DEV_GRE 0x3 +#define EFI_ACPI_IORT_RMR_ACCESS_ATTRIB_NORM_IN_NC_OUT_NC 0x4 +#define EFI_ACPI_IORT_RMR_ACCESS_ATTRIB_NORM_IN_WB_OUT_WB_ISH 0x5 #define EFI_ACPI_IORT_ID_MAPPING_FLAGS_SINGLE BIT0 +#define EFI_ACPI_IORT_RMR_NODE_REVISION_02 0x2 // Deprecated + #pragma pack(1) /// @@ -89,7 +123,7 @@ typedef struct { UINT8 Type; UINT16 Length; UINT8 Revision; - UINT32 Reserved; + UINT32 Identifier; UINT32 NumIdMappings; UINT32 IdReference; } EFI_ACPI_6_0_IO_REMAPPING_NODE; @@ -118,7 +152,9 @@ typedef struct { UINT32 AtsAttribute; UINT32 PciSegmentNumber; UINT8 MemoryAddressSize; - UINT8 Reserved1[3]; + UINT16 PasidCapabilities; + UINT8 Reserved1[1]; + UINT32 Flags; } EFI_ACPI_6_0_IO_REMAPPING_RC_NODE; /// @@ -198,6 +234,40 @@ typedef struct { // EFI_ACPI_6_0_IO_REMAPPING_ID_TABLE OverflowInterruptMsiMapping[1]; } EFI_ACPI_6_0_IO_REMAPPING_PMCG_NODE; +/// +/// Memory Range Descriptor. +/// +typedef struct { + /// Base address of Reserved Memory Range, + /// aligned to a page size of 64K. + UINT64 Base; + + /// Length of the Reserved Memory range. + /// Must be a multiple of the page size of 64K. + UINT64 Length; + + /// Reserved, must be zero. + UINT32 Reserved; +} EFI_ACPI_6_0_IO_REMAPPING_MEM_RANGE_DESC; + +/// +/// Node type 6: Reserved Memory Range (RMR) node +/// +typedef struct { + EFI_ACPI_6_0_IO_REMAPPING_NODE Node; + + /// RMR flags + UINT32 Flags; + + /// Memory range descriptor count. + UINT32 NumMemRangeDesc; + + /// Offset of the memory range descriptor array. + UINT32 MemRangeDescRef; + // EFI_ACPI_6_0_IO_REMAPPING_ID_TABLE IdMapping[1]; + // EFI_ACPI_6_0_IO_REMAPPING_MEM_RANGE_DESC MemRangeDesc[1]; +} EFI_ACPI_6_0_IO_REMAPPING_RMR_NODE; + #pragma pack() #endif -- 'Guid(CE165669-3EF3-493F-B85D-6190EE5B9759)'