From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM11-CO1-obe.outbound.protection.outlook.com (NAM11-CO1-obe.outbound.protection.outlook.com [40.107.220.83]) by mx.groups.io with SMTP id smtpd.web11.30706.1681880636567187720 for ; Tue, 18 Apr 2023 22:03:56 -0700 Authentication-Results: mx.groups.io; dkim=fail reason="body hash did not verify" header.i=@amd.com header.s=selector1 header.b=2zF2wDcV; spf=permerror, err=parse error for token &{10 18 %{i}._ip.%{h}._ehlo.%{d}._spf.vali.email}: invalid domain name (domain: amd.com, ip: 40.107.220.83, mailfrom: abner.chang@amd.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=KW+rf1e5ybUbvTNKwO4XRQbN/LsbzKhgKngYTCEm0g6F9gMuDfHEUhU9VgTyB6Hb6PNqxl8C/ShP2yI+WFn1eiKLys59hluP4MKzbhcoC3pV8AaVTBYjHyizUTWZQfSwYakF207to/tHyx2+BXG0ixebh+iQjAGt1xPXet9/jlgDOCNCfhT/RgS/EMzlrQ7EuH2zAYngTHeO4S+Yve/XcRpaC+ARyLqOWhbjKcM4/dY43dJUf0M6xD4rcmgcB7IYNtZbYvAzTunDYSGkAxMQDiwlfqRDNhLtxnUd3EwnDZM93GeXO024/Yb1zgR+3km/mFIAuhtW8WSQLxB8RdkmVg== 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=5sjAh6H4aDZhuqTmWH8kLnRX+YeJoDrXWd3wErkYNZQ=; b=WquprGOtZX1H28cZldwqGxHoqJhZBt+o/WmvTrk6z2yH8UNEOGv4/cS6Ahz9O6uS3vqgSPyFOKbHisHlu1tsMblVRYoXMV9cnHkyvCrcJfvYs3Y119Oq63BXiNode2APnKoePnHQLIdtGTF39CmmuPk61FUweo6yhAZyT6A1UQK55zTA4Q087oiCJvQDMAUnPFP0k4QStorLs0k15psXrDVtHtxFC/9oc4ulpZMMKsPYpRbXOGrklAIXTRisBe/m6YKKA7ds44SLvxhZdBdbOxLp04st5ahJh9JkM4agHfojgG9G3ZOCrTVP/dZWyvQwqASJjAyMOSXNvKKbrTlCuw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=edk2.groups.io smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=5sjAh6H4aDZhuqTmWH8kLnRX+YeJoDrXWd3wErkYNZQ=; b=2zF2wDcVlBLfw6mW60rTahln7IQ0bU+ZPuurnpnP3QUUdmcjIVlJVZzAc0pxSyFDrdtpVzF5Gaxgrx9gwP3TV7aRTc+byW40qOM1nbSwOYQa18EvLPYduC8sErNNOVW9M05YwNEvUSF2e3SMKJxo+hNj7dlrpiY9XzL+Wid/2Y8= Received: from DM6PR06CA0049.namprd06.prod.outlook.com (2603:10b6:5:54::26) by MN2PR12MB4584.namprd12.prod.outlook.com (2603:10b6:208:24e::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6319.20; Wed, 19 Apr 2023 05:03:54 +0000 Received: from DM6NAM11FT075.eop-nam11.prod.protection.outlook.com (2603:10b6:5:54:cafe::c0) by DM6PR06CA0049.outlook.office365.com (2603:10b6:5:54::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6319.20 via Frontend Transport; Wed, 19 Apr 2023 05:03:54 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by DM6NAM11FT075.mail.protection.outlook.com (10.13.173.42) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6319.22 via Frontend Transport; Wed, 19 Apr 2023 05:03:53 +0000 Received: from TPE-L1-ABNCHANG.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Wed, 19 Apr 2023 00:03:41 -0500 From: "Chang, Abner" To: CC: Michael D Kinney , Liming Gao , Zhiguang Liu , "Nickle Wang" , Igor Kulchytskyy , Isaac Oram , Abdul Lateef Attar Subject: [PATCH V2] MdePkg/Include: Add DMTF PLDM SMBIOS definitions Date: Wed, 19 Apr 2023 13:03:24 +0800 Message-ID: <20230419050324.417-1-abner.chang@amd.com> X-Mailer: git-send-email 2.37.1.windows.1 MIME-Version: 1.0 Return-Path: Abner.Chang@amd.com X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB04.amd.com (10.181.40.145) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DM6NAM11FT075:EE_|MN2PR12MB4584:EE_ X-MS-Office365-Filtering-Correlation-Id: 8b0a9c7b-02e3-4638-8bbc-08db40937926 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: z9XYoSqyC/RX5xUjxlTgFmm10taurbFaPTQZbtq42KuhR+K/oMPAS8MRJ+dl0Jsq+hlEN/W8ekMmwWlaCzDXIerL2RDyoLHX2Gp9QFAIoLPczgS/AUceCBYZSFQTqNFJzFPXO9v7upL0eJAOiQttQiRyKRH8u7WN3Mk2Erc5eDZLdooBGKShMrFV2G58gAwiMZZInhamsOMGS7WYDbo1OFzbxKpsKP82gTKke6MCSvU1yAxUVM6pQ+OIq17qjDdc4CsHDMRMT50QrzubUqnmhdGkXKhR4WtoLsu/JrVpD3NawkZnofEfwwMPbow9+Bcvd7UQHh1t/vioEm1sv/nghVlNWo83OSA0MPoiIiVV1H0DvuF4MMGBSJetWZ9MNXa/QEHhIGQsNdET01qYaSY1Xdl80kHSy2lxSCmDf/YXFEPR9umJCvW3TaPU5H3ii0Naaan15QdPgw/DWAJmpuVPgKZlAUfmBAA96OF+7DtVSw2hwZxpIiy31qx8qp5mIRF7CxSfBNX7accZrgahnzLSqWvAdQAdJNYXlAuCsGYJuTiEaqSKKrloQlb4WhytgIT98gSBNoK0kIyEqWiqhizRut/gDldgIi1jcAzLLtK7NO9hj4J8ew5RMeusi6qVyKkTa54uYY+fAZNwK7x1ND4qudu0Bu6naei+urSu8mkDFpBgieGUQIF7S6nslgORQnFrp9xMR7ce6ZhL6X2ZMwtFh+WZEH4nLqfmB3RA00Dq3iQ= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230028)(4636009)(136003)(346002)(39860400002)(396003)(376002)(451199021)(36840700001)(46966006)(40470700004)(40480700001)(40460700003)(81166007)(316002)(4326008)(70206006)(70586007)(6916009)(478600001)(41300700001)(54906003)(82740400003)(8676002)(8936002)(5660300002)(356005)(186003)(47076005)(36860700001)(16526019)(336012)(426003)(83380400001)(2616005)(7696005)(6666004)(1076003)(966005)(26005)(86362001)(82310400005)(36756003)(2876002)(2906002)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Apr 2023 05:03:53.9059 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 8b0a9c7b-02e3-4638-8bbc-08db40937926 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT075.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR12MB4584 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain From: Abner Chang BZ #4396 This change adds definitions for DMTF PLDM SMBIOS Transfer specification. Spec ref: https://www.dmtf.org/sites/default/files/standards/documents/DSP0246_1.0.1.= pdf Signed-off-by: Abner Chang Cc: Michael D Kinney Cc: Liming Gao Cc: Zhiguang Liu Cc: Nickle Wang Cc: Igor Kulchytskyy Cc: Isaac Oram Cc: Abdul Lateef Attar --- .../IndustryStandard/PldmSmbiosTransfer.h | 182 ++++++++++++++++++ 1 file changed, 182 insertions(+) create mode 100644 MdePkg/Include/IndustryStandard/PldmSmbiosTransfer.h diff --git a/MdePkg/Include/IndustryStandard/PldmSmbiosTransfer.h b/MdePkg/= Include/IndustryStandard/PldmSmbiosTransfer.h new file mode 100644 index 00000000000..e31bf30cfa8 --- /dev/null +++ b/MdePkg/Include/IndustryStandard/PldmSmbiosTransfer.h @@ -0,0 +1,182 @@ +/** + The definitions of DMTF Platform Level Data Model (PLDM) + SMBIOS Transfer Specification. + + Copyright (C) 2023 Advanced Micro Devices, Inc. All rights reserved. + SPDX-License-Identifier: BSD-2-Clause-Patent + + @par Revision Reference: + DMTF Platform Level Data Model (PLDM) SMBIOS Transfer Specification + Version 1.0.1 + https://www.dmtf.org/sites/default/files/standards/documents/DSP0246_1.0= .1.pdf + +**/ + +#ifndef PLDM_SMBIOS_TRANSFER_H_ +#define PLDM_SMBIOS_TRANSFER_H_ + +#include + +#pragma pack(1) + +/// +/// Smbios-related definitions from PLDM for SMBIOS Transfer +/// Specification (DMTF DSP0246) +/// +#define PLDM_GET_SMBIOS_STRUCTURE_TABLE_METADATA_COMMAND_CODE 0x01 +#define PLDM_SET_SMBIOS_STRUCTURE_TABLE_METADATA_COMMAND_CODE 0x02 +#define PLDM_GET_SMBIOS_STRUCTURE_TABLE_COMMAND_CODE 0x03 +#define PLDM_SET_SMBIOS_STRUCTURE_TABLE_COMMAND_CODE 0x04 +#define PLDM_GET_SMBIOS_STRUCTURE_BY_TYPE_COMMAND_CODE 0x05 +#define PLDM_GET_SMBIOS_STRUCTURE_BY_HANDLE_COMMAND_CODE 0x06 + +/// +/// PLDM SMBIOS transfer command specific completion code. +/// +#define PLDM_COMPLETION_CODE_INVALID_DATA_TRANSFER_HANDLE 0x80 +#define PLDM_COMPLETION_CODE_INVALID_TRANSFER_OPERATION_FLAG 0x81 +#define PLDM_COMPLETION_CODE_INVALID_TRANSFER_FLAG 0x82 +#define PLDM_COMPLETION_CODE_NO_SMBIOS_STRUCTURE_TABLE_METADATA 0x83 +#define PLDM_COMPLETION_CODE_INVALID_DATA_INTEGRITY_CHECK 0x84 +#define PLDM_COMPLETION_CODE_SMBIOS_STRUCTURE_TABLE_UNAVAILABLE 0x85 + +/// +/// Get SMBIOS Structure Table Metadata Response. +/// +typedef struct { + UINT8 SmbiosMajorVersion; + UINT8 SmbiosMinorVersion; + UINT16 MaximumStructureSize; + UINT16 SmbiosStructureTableLength; + UINT16 NumberOfSmbiosStructures; + UINT32 SmbiosStructureTableIntegrityChecksum; +} PLDM_SMBIOS_STRUCTURE_TABLE_METADATA; + +typedef struct { + PLDM_RESPONSE_HEADER ResponseHeader; + PLDM_SMBIOS_STRUCTURE_TABLE_METADATA SmbiosStructureTableMetadata; +} PLDM_GET_SMBIOS_STRUCTURE_TABLE_METADATA_RESPONSE_FORMAT; + +/// +/// Set SMBIOS Structure Table Metadata Request. +/// +typedef struct { + PLDM_REQUEST_HEADER RequestHeader; + PLDM_SMBIOS_STRUCTURE_TABLE_METADATA SmbiosStructureTableMetadata; +} PLDM_SET_SMBIOS_STRUCTURE_TABLE_METADATA_REQUEST_FORMAT; + +/// +/// Set SMBIOS Structure Table Metadata Response. +/// +typedef struct { + PLDM_RESPONSE_HEADER ResponseHeader; +} PLDM_SET_SMBIOS_STRUCTURE_TABLE_METADATA_RESPONSE_FORMAT; + +/// +/// Get SMBIOS Structure Table Request. +/// +typedef struct { + UINT32 DataTransferHandle; + UINT8 TransferOperationFlag; +} PLDM_GET_SMBIOS_STRUCTURE_TABLE_REQUEST; + +typedef struct { + PLDM_REQUEST_HEADER RequestHeader; + PLDM_GET_SMBIOS_STRUCTURE_TABLE_REQUEST GetSmbiosStructureTableReques= t; +} PLDM_GET_SMBIOS_STRUCTURE_TABLE_REQUEST_FORMAT; + +/// +/// Get SMBIOS Structure Table Response. +/// +typedef struct { + UINT32 NextDataTransferHandle; + UINT8 TransferFlag; + UINT8 Table[0]; +} PLDM_GET_SMBIOS_STRUCTURE_TABLE_RESPONSE; + +typedef struct { + PLDM_RESPONSE_HEADER ResponseHeader; + PLDM_GET_SMBIOS_STRUCTURE_TABLE_RESPONSE GetSmbiosStructureTableRespo= nse; +} PLDM_GET_SMBIOS_STRUCTURE_TABLE_RESPONSE_FORMAT; + +/// +/// Set SMBIOS Structure Table Request. +/// +typedef struct { + UINT32 DataTransferHandle; + UINT8 TransferFlag; + UINT8 Table[0]; +} PLDM_SET_SMBIOS_STRUCTURE_TABLE_REQUEST; + +typedef struct { + PLDM_REQUEST_HEADER RequestHeader; + PLDM_SET_SMBIOS_STRUCTURE_TABLE_REQUEST SetSmbiosStructureTableReques= t; +} PLDM_SET_SMBIOS_STRUCTURE_TABLE_REQUEST_FORMAT; + +/// +/// Set SMBIOS Structure Table Response. +/// +typedef struct { + PLDM_RESPONSE_HEADER ResponseHeader; + UINT32 NextDataTransferHandle; +} PLDM_SET_SMBIOS_STRUCTURE_TABLE_RESPONSE_FORMAT; + +/// +/// Get SMBIOS Structure by Type Request. +/// +typedef struct { + UINT32 DataTransferHandle; + UINT8 TransferOperationFlag; + UINT8 Type; + UINT16 StructureInstanceId; +} PLDM_GET_SMBIOS_STRUCTURE_BY_TYPE_REQUEST; + +typedef struct { + PLDM_REQUEST_HEADER RequestHeader; + PLDM_GET_SMBIOS_STRUCTURE_BY_TYPE_REQUEST GetSmbiosStructureByTypeReq= uest; +} PLDM_GET_SMBIOS_STRUCTURE_BY_TYPE_REQUEST_FORMAT; + +/// +/// Get SMBIOS Structure by Type Response. +/// +typedef struct { + UINT32 NextDataTransferHandle; + UINT8 TransferFlag; + UINT8 Table[0]; +} PLDM_GET_SMBIOS_STRUCTURE_BY_TYPE_RESPONSE; + +typedef struct { + PLDM_RESPONSE_HEADER ResponseHeader; + PLDM_GET_SMBIOS_STRUCTURE_BY_TYPE_RESPONSE GetSmbiosStructureByTypeRe= sponse; +} PLDM_GET_SMBIOS_STRUCTURE_BY_TYPE_RESPONSE_FORMAT; + +/// +/// Get SMBIOS Structure by Handle Request. +/// +typedef struct { + UINT32 DataTransferHandle; + UINT8 TransferOperationFlag; + UINT16 Handle; +} PLDM_GET_SMBIOS_STRUCTURE_BY_HANDLE_REQUEST; + +typedef struct { + PLDM_REQUEST_HEADER RequestHeader; + PLDM_GET_SMBIOS_STRUCTURE_BY_HANDLE_REQUEST GetSmbiosStructureByHandl= eRequest; +} PLDM_GET_SMBIOS_STRUCTURE_BY_HANDLE_REQUEST_FORMAT; + +/// +/// Get SMBIOS Structure by Handle Response. +/// +typedef struct { + UINT32 NextDataTransferHandle; + UINT8 TransferFlag; + UINT8 Table[0]; +} PLDM_GET_SMBIOS_STRUCTURE_BY_HANDLE_RESPONSE; + +typedef struct { + PLDM_RESPONSE_HEADER ResponseHeader; + PLDM_GET_SMBIOS_STRUCTURE_BY_HANDLE_RESPONSE GetSmbiosStructureByType= Response; +} PLDM_GET_SMBIOS_STRUCTURE_BY_HANDLE_RESPONSE_FORMAT; +#pragma pack() + +#endif // PLDM_SMBIOS_TRANSFER_H_ --=20 2.37.1.windows.1