From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM12-MW2-obe.outbound.protection.outlook.com (NAM12-MW2-obe.outbound.protection.outlook.com [40.107.244.50]) by mx.groups.io with SMTP id smtpd.web09.20173.1661185278975405512 for ; Mon, 22 Aug 2022 09:21:19 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@nvidia.com header.s=selector2 header.b=f+L/Iu6X; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: nvidia.com, ip: 40.107.244.50, mailfrom: jbrasen@nvidia.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=euCyFMIRAaCqSDKLmb2MqVjlm+yL5xJO1/aMBJUT0Lum4vs5F/lHMQWCTJ2BqK3LHipRmmjV0U/BculgTcHEAC9mcN1ewgFd5LHPFXj3YWNupZZu+dVPcoCI3EIKC5mBTtZOGheYXFTA3Wn0BL4HDfunA5/2yARg1ZlS9ihbohNKknw9pM4hZdtnAHGxPE1D02kUm3X+9i1sLUBdFQMn4dyoMQ/9xcW4bfA77FNGntlsKvJ+EncJQqFYKVoo16c3yDuKWaPiIlxcHTfojLwoZrbV5Q+Bz0Gv++4+WevoPV33V5D4uS8V9t6hcV6VoB7GBCgLvrUi12D2HtQZYFCu+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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=W0t/SWhrCCh9oIVEiU1XjCJbZb1opTsVTtnFhJ3a+o4=; b=O9G5ndZ9zol79RJ39ECpqoM3xceu+INkIBtuvHiNqOqETp9+OMNmKcmgXZ8tZJdH2lc18t8JvBQXWg4i84MCe9odmmZMYbIYJxY0sVG3uG2CS+VGflZFohKu3vm3eKMXZkzq08j2QcV11liTOQ0j2b5QckBv4AfOyMF+S37nmnSvFr7Snbb7vPC94LUSKLAzQNwXfo3IIKgXtNRbJ6LPyyRXcteBTpuJ7giXUpBcWKN6hFJw35ED8tPlfvPWAELhG039Rt4iZYxquBFBEFfbLHcZZgc0upKveHaEG1WwOMRz/W46W1zCnwDwmj1eOWcWFFpUM0Qvmygw9lrOX1lWmw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 12.22.5.238) smtp.rcpttodomain=arm.com smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=W0t/SWhrCCh9oIVEiU1XjCJbZb1opTsVTtnFhJ3a+o4=; b=f+L/Iu6XiWWZApm+GZ6sPZE9s1gLZMJknRYMUJzT5LvzQ/WuMj0kt1A+o5GJRXVVoE64do1aoxwRDKefJ/Q/SDHJs8u75CfKOva7TdQ5CJcdn4VZesxuFYW/Hf/rfD4h13D8/aK18+Qq1fMe5rmset87qoWV9CwaDkWRGn5mRicuGTKFiYvVKIsui44TvTABDFuGGt6VGGnO4zwgoSuq3bJ0GIsBtTf8gbC1DvzMGbtNQ3oyWCtEz1e0op42ExYBo7VEgd6nvBPl8HyJvoYlDXWmh8L2zRdS1/As09XhELY+fLIRX7Ipt5NWW1dWOTTbA45evm1WDPWQdfqhmAO2Og== Received: from BN0PR08CA0004.namprd08.prod.outlook.com (2603:10b6:408:142::22) by DM5PR12MB1241.namprd12.prod.outlook.com (2603:10b6:3:72::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5546.22; Mon, 22 Aug 2022 16:21:17 +0000 Received: from BN8NAM11FT101.eop-nam11.prod.protection.outlook.com (2603:10b6:408:142:cafe::82) by BN0PR08CA0004.outlook.office365.com (2603:10b6:408:142::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5546.20 via Frontend Transport; Mon, 22 Aug 2022 16:21:16 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 12.22.5.238) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 12.22.5.238 as permitted sender) receiver=protection.outlook.com; client-ip=12.22.5.238; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (12.22.5.238) by BN8NAM11FT101.mail.protection.outlook.com (10.13.177.126) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.5546.7 via Frontend Transport; Mon, 22 Aug 2022 16:21:16 +0000 Received: from rnnvmail204.nvidia.com (10.129.68.6) by DRHQMAIL105.nvidia.com (10.27.9.14) with Microsoft SMTP Server (TLS) id 15.0.1497.38; Mon, 22 Aug 2022 16:20:52 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by rnnvmail204.nvidia.com (10.129.68.6) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.29; Mon, 22 Aug 2022 09:20:52 -0700 Received: from ed7fa55790ac.nvidia.com (10.127.8.9) by mail.nvidia.com (10.129.68.8) with Microsoft SMTP Server id 15.2.986.29 via Frontend Transport; Mon, 22 Aug 2022 09:20:51 -0700 From: "Jeff Brasen" To: CC: , , , , Jeff Brasen Subject: [PATCH] DynamicTablesPkg: AcpiSsdtPcieLibArm : Add UID to slot creation Date: Mon, 22 Aug 2022 10:21:01 -0600 Message-ID: <1dc8a5cb9e3965f6adb5b84a722401d70fe11d8e.1661185223.git.jbrasen@nvidia.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-NVConfidentiality: public Return-Path: jbrasen@nvidia.com X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 7194ee82-49b4-4b46-278a-08da845a56f9 X-MS-TrafficTypeDiagnostic: DM5PR12MB1241:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: gxpp737MWBygSj8+klWAudBAmVgWlkhsHXj8eFOWfBc5NE1iwgaddmHJF+0+eghKI98F/vL2zQ7NDDaZ79K6OVtLB4004IYEvBpJ6Lod3Qs03OFwCah/xhzmeqgyKDwPHowlmsH6JSnKsxxIeJVgjmC3kmhRxqunTaQ47/363DRsA2qutsLEJOYozA97lvWaNHBe8yfyZ6R0W8Z2g0FAXMqoQRvwA4ie5tJnfo7iehPF+x1luoAtXnfwwsxv4vbFswJqWXnbx05N7pLBR4WHv8yLlU9mh6Jz5p58y1RVb5fF0tfZf3frg+V3hVT/AHxpxDgrz5YY78Lhs9IjTcsYzx/hRiFjE1JQeg0j2p1eRqbYb0Pg9wq3eEDwKmkao/kL5C1yVjSAZ1tkUfXB26+Db/dE5zrQC8GQfH1Kg/+M1W0KLihqJ5bsSWo1csflYAYz7mMSAxbVKTTv/rT6dKIcWf0H4NUW1yLQ2BLg2PRcv4CUymXt1ZAO/rJxRUUOcRk7OyjpNP8lxOyo3dMOiJmhcGt9/t2Ktp65teMFAZ3aSvhyY3/yQ1cUp0whdFtkSaFrSPEstKuQeTEW4yMlTSALq+H+I0mnA8jv1x72/PZUW6VO0ezYHuiPeF8n0A30oI0/SoqjjO846zLQvmLvtnywZpT9S9o1NFfcVSOa/pmHbnoHLOIJTzIL1eJJjnZEM2edOi/mIr9+jTd2qpsI5FHQ6le5Ags03bfLmkhzVgj51OjXEmuOvf+V4GCG4atkmCwkGU55r5eYc2Qdm8Vie+WruvIR1bnJOQ5GmKpn4ZowNmHFy/lt98H5lKekMCS5+E8FApG5NRi2cOG2uXhCYYbHL6gGhvskxZ17MSy1S9Vz3RA5h13j3Ktxp7P9ZkwpbjmXyATH6MhmGXog0QTaCR6l9a7cBxxrvyCJ1ex4yqOAwDw= X-Forefront-Antispam-Report: CIP:12.22.5.238;CTRY:US;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:mail.nvidia.com;PTR:InfoNoRecords;CAT:NONE;SFS:(13230016)(4636009)(346002)(376002)(39860400002)(136003)(396003)(36840700001)(46966006)(40470700004)(426003)(336012)(186003)(2616005)(47076005)(40460700003)(36756003)(36860700001)(40480700001)(70206006)(70586007)(8676002)(4326008)(83380400001)(54906003)(6916009)(316002)(2906002)(86362001)(8936002)(5660300002)(7696005)(6666004)(107886003)(26005)(82310400005)(478600001)(41300700001)(966005)(82740400003)(356005)(81166007)(213903007)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Aug 2022 16:21:16.5720 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 7194ee82-49b4-4b46-278a-08da845a56f9 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a;Ip=[12.22.5.238];Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT101.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1241 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain Expose the UID value to GeneratePciSlots().=0D This is needed for some cases for example:=0D https://docs.microsoft.com/en-us/windows-hardware/drivers/pci/dsd-for-pcie-= root-ports#identifying-externally-exposed-pcie-root-ports=0D =0D Signed-off-by: Jeff Brasen =0D ---=0D DynamicTablesPkg/Include/Library/SsdtPcieSupportLib.h | 8 +++++---=0D .../Acpi/Arm/AcpiSsdtPcieLibArm/SsdtPcieGenerator.c | 5 ++++-=0D .../Common/SsdtPcieSupportLib/SsdtPcieSupportLib.c | 8 +++++---=0D 3 files changed, 14 insertions(+), 7 deletions(-)=0D =0D diff --git a/DynamicTablesPkg/Include/Library/SsdtPcieSupportLib.h b/Dynami= cTablesPkg/Include/Library/SsdtPcieSupportLib.h=0D index 85e283a994..4171dabc33 100644=0D --- a/DynamicTablesPkg/Include/Library/SsdtPcieSupportLib.h=0D +++ b/DynamicTablesPkg/Include/Library/SsdtPcieSupportLib.h=0D @@ -54,9 +54,10 @@ AddOscMethod (=0D used. It should be possible to enumerate them, but this is additional=0D information.=0D =0D - @param [in] PciInfo Pci device information.=0D - @param [in] MappingTable The mapping table structure.=0D - @param [in, out] PciNode Pci node to amend.=0D + @param [in] PciInfo Pci device information.=0D + @param [in] MappingTable The mapping table structure.=0D + @param [in] Uid Unique Id of the Pci device.=0D + @param [in, out] PciNode Pci node to amend.=0D =0D @retval EFI_SUCCESS Success.=0D @retval EFI_INVALID_PARAMETER Invalid parameter.=0D @@ -67,6 +68,7 @@ EFIAPI=0D GeneratePciSlots (=0D IN CONST CM_ARM_PCI_CONFIG_SPACE_INFO *PciInfo,=0D IN CONST MAPPING_TABLE *MappingTable,=0D + IN UINT32 Uid,=0D IN OUT AML_OBJECT_NODE_HANDLE PciNode=0D );=0D =0D diff --git a/DynamicTablesPkg/Library/Acpi/Arm/AcpiSsdtPcieLibArm/SsdtPcieG= enerator.c b/DynamicTablesPkg/Library/Acpi/Arm/AcpiSsdtPcieLibArm/SsdtPcieG= enerator.c=0D index ceffe2838c..24e074ea90 100644=0D --- a/DynamicTablesPkg/Library/Acpi/Arm/AcpiSsdtPcieLibArm/SsdtPcieGenerato= r.c=0D +++ b/DynamicTablesPkg/Library/Acpi/Arm/AcpiSsdtPcieLibArm/SsdtPcieGenerato= r.c=0D @@ -295,6 +295,7 @@ GeneratePciDeviceInfo (=0D @param [in] CfgMgrProtocol Pointer to the Configuration Manager=0D Protocol interface.=0D @param [in] PciInfo Pci device information.=0D + @param [in] Uid Unique Id of the Pci device.=0D @param [in, out] PciNode Pci node to amend.=0D =0D @retval EFI_SUCCESS The function completed successfully.=0D @@ -308,6 +309,7 @@ GeneratePrt (=0D IN ACPI_PCI_GENERATOR *Generator,= =0D IN CONST EDKII_CONFIGURATION_MANAGER_PROTOCOL *CONST CfgMgrProtoc= ol,=0D IN CONST CM_ARM_PCI_CONFIG_SPACE_INFO *PciInfo,=0D + IN UINT32 Uid,=0D IN OUT AML_OBJECT_NODE_HANDLE PciNode=0D )=0D {=0D @@ -416,7 +418,7 @@ GeneratePrt (=0D PrtNode =3D NULL;=0D =0D // Generate the Pci slots once all the device have been added.=0D - Status =3D GeneratePciSlots (PciInfo, &Generator->DeviceTable, PciNode);= =0D + Status =3D GeneratePciSlots (PciInfo, &Generator->DeviceTable, Uid, PciN= ode);=0D if (EFI_ERROR (Status)) {=0D ASSERT (0);=0D goto exit_handler;=0D @@ -687,6 +689,7 @@ GeneratePciDevice (=0D Generator,=0D CfgMgrProtocol,=0D PciInfo,=0D + Uid,=0D PciNode=0D );=0D if (EFI_ERROR (Status)) {=0D diff --git a/DynamicTablesPkg/Library/Common/SsdtPcieSupportLib/SsdtPcieSup= portLib.c b/DynamicTablesPkg/Library/Common/SsdtPcieSupportLib/SsdtPcieSupp= ortLib.c=0D index e5ab3a3ca8..b35fb6a7dd 100644=0D --- a/DynamicTablesPkg/Library/Common/SsdtPcieSupportLib/SsdtPcieSupportLib= .c=0D +++ b/DynamicTablesPkg/Library/Common/SsdtPcieSupportLib/SsdtPcieSupportLib= .c=0D @@ -41,9 +41,10 @@=0D used. It should be possible to enumerate them, but this is additional=0D information.=0D =0D - @param [in] PciInfo Pci device information.=0D - @param [in] MappingTable The mapping table structure.=0D - @param [in, out] PciNode Pci node to amend.=0D + @param [in] PciInfo Pci device information.=0D + @param [in] MappingTable The mapping table structure.=0D + @param [in] Uid Unique Id of the Pci device.=0D + @param [in, out] PciNode Pci node to amend.=0D =0D @retval EFI_SUCCESS Success.=0D @retval EFI_INVALID_PARAMETER Invalid parameter.=0D @@ -54,6 +55,7 @@ EFIAPI=0D GeneratePciSlots (=0D IN CONST CM_ARM_PCI_CONFIG_SPACE_INFO *PciInfo,=0D IN CONST MAPPING_TABLE *MappingTable,=0D + IN UINT32 Uid,=0D IN OUT AML_OBJECT_NODE_HANDLE PciNode=0D )=0D {=0D -- =0D 2.25.1=0D =0D