From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by spool.mail.gandi.net (Postfix) with ESMTPS id 6189174003B for ; Tue, 24 Oct 2023 02:44:16 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=VV9Y3I6eF7/RovasWQ/3ZfgMgEbX3jycI5sq2/4uJXc=; c=relaxed/simple; d=groups.io; h=ARC-Seal:ARC-Message-Signature:ARC-Authentication-Results:From:To:CC:Subject:Thread-Topic:Thread-Index:Date:Message-ID:References:In-Reply-To:Accept-Language:msip_labels:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Language:Content-Type:Content-Transfer-Encoding; s=20140610; t=1698115455; v=1; b=NxYJXWu1cZEzL9LWW6r2yqTQMZ7Cg2CK6lpBogsh7TEXHuatc3qIKLdx1e8bt+Ot4UQOF0+F 3gZVo3xJlUqEWEAbIZOQVWVxDW2vRw87rOzTDIaMpEBLalhyAu3oMifkPUKpscy0avCLvJTrT9I 5kp8FzaN9R1+R7kb/N4d3Bs8= X-Received: by 127.0.0.2 with SMTP id 41N8YY7687511xAAxiRkTbOe; Mon, 23 Oct 2023 19:44:15 -0700 X-Received: from NAM10-BN7-obe.outbound.protection.outlook.com (NAM10-BN7-obe.outbound.protection.outlook.com [40.107.92.89]) by mx.groups.io with SMTP id smtpd.web10.139701.1698115454126419979 for ; Mon, 23 Oct 2023 19:44:14 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Wz3CLZwCephWPg8OFR6PkBDIPoLtO/77moJ5VsGTB+AQ47vSpdjZQQ/lPy0vNh7tgdWP3t5N96dkfWUxqwRxhLXJcwt+WzBAtjWr7Zi4BM3pTaWkGr06r9pyJmanPHRQKwn74ReVfH/PpsJ7ImNYhurKQb3axzGoSrWWlvU29igmfLK+GIyzpspp/frHeckAwqLap+mTsCocsbNcBYFouHxHvclegoLNz7nWcfAfU2Jvz3uVM6BZIUwp/3g7FypZXrZZNzkRMybelpn6yuyC0OK+IVyKkwwxeZ18wcdTIStAkv+1RhpLyOIUttd+1H4qYEqB8X6xeXduVYTbAoVmFw== 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=dlDTtCx2Nr3zPOf0dO3NzCengjgZjmIWVJLNlwHn4iw=; b=ZvkEsffG+RnAsQusCPflaUhhPCmTAes2TV2VizYmIqUAfUUhWjbpkz+Yz5met2514oIuTUfjfcjHXUuzCsycjDWOSQAF9HNu0eB/HTyhF1bQmEdTbJ87CiDpdGKiJONxV2aXxMN6tHUgVhEfi9MqAyw5dTA6wZgUeVWJMuARPS5WolxLpuZPcziBcvW8/8aY4Z+rB1U53jABDLM8AZXwUhzBkmPZZJxCW60ZN7k0iSR4kkBeQzbfqf1jDdmuATnZYkf2A//kjpDVVyQjoauI6t2T4YwByAXSajaWUM9o3nKUAgnk4SwuS+egIJ9mxOOijWZuN3nuMWcOMKDYeruOKQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none X-Received: from MN2PR12MB3966.namprd12.prod.outlook.com (2603:10b6:208:165::18) by MN0PR12MB5905.namprd12.prod.outlook.com (2603:10b6:208:379::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6907.33; Tue, 24 Oct 2023 02:44:11 +0000 X-Received: from MN2PR12MB3966.namprd12.prod.outlook.com ([fe80::345a:6816:7343:3e6b]) by MN2PR12MB3966.namprd12.prod.outlook.com ([fe80::345a:6816:7343:3e6b%6]) with mapi id 15.20.6907.025; Tue, 24 Oct 2023 02:44:11 +0000 From: "Chang, Abner via groups.io" To: Konstantin Aladyshev , "devel@edk2.groups.io" CC: "Attar, AbdulLateef (Abdul Lateef)" , "nicklew@nvidia.com" Subject: Re: [edk2-devel] [PATCH edk2-platforms v3 00/16] MTCP-over-KCS support Thread-Topic: [PATCH edk2-platforms v3 00/16] MTCP-over-KCS support Thread-Index: AQHaBbGU+a9whfjsFECc0pszYz6JzrBYO1vA Date: Tue, 24 Oct 2023 02:44:10 +0000 Message-ID: References: <20231023130511.4521-1-aladyshev22@gmail.com> In-Reply-To: <20231023130511.4521-1-aladyshev22@gmail.com> Accept-Language: en-US, zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_ActionId=6227ce01-fd3a-4603-95a6-8231d3e29f57;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_ContentBits=0;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Enabled=true;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Method=Standard;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_Name=General;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_SetDate=2023-10-24T02:39:55Z;MSIP_Label_4342314e-0df4-4b58-84bf-38bed6170a0f_SiteId=3dd8961f-e488-4e60-8e11-a82d994e183d; x-ms-publictraffictype: Email x-ms-traffictypediagnostic: MN2PR12MB3966:EE_|MN0PR12MB5905:EE_ x-ms-office365-filtering-correlation-id: 12660ea7-6fba-49e9-1f3c-08dbd43b1a1f x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam-message-info: H56/Oujf4K5/zVOU29fqz0rbJ00FWE2jGSe+Hbur1eUmJc+scurk1sYjmvtGYPpBlqL5HWXn1KKyJkeh7qCDwij46IOmCS0jzb/bvGscs9LoZEx8nZ0wSm1aPnSjwHGdkj0h9bl9x1bZuKbJATZcIvB5joowBKKRl1T4x+aGcOl0LBY+PXVRPAPrWgj03QTNar9Q9a5/Wp7y11GhHhys/9EFHKh4K5e/S7xnj5r4ABnFMBxctoCrD1bnMZnVbGtYNeW7qP0Hb7pWK85sfsmRtdKAORqw32Fz2i93T0QLL5Eu6rPuZhbl/ZCZLXxyWL66yIzkXMsEGaLfAUz968xQUH982kgDpe+7ejR64BCjnBbS/ZiWGxN1tWHeOVBYAGEH8hUlHWoknmx1FC2HkWyyLmPTAL63mYB9zBg/LeR5Ssb8WsoisL5vHRjmmX6Y7eMeF0xRBrkwSDfmGezuhG60KrfJJI/tSobzKMIefjvfaONyOgdnuJjNBVuv6cD+mOuO+m/GxdRfTrcxIb/leboq6Q/TFSl9rYL5RBPL63dm4ns/+bj1BVTRxdoHE7oyNDVvPQP4hnYbU5FLiKylU6W9OpBgSyA2qeR6sBc4+UvW0BFgaFaKu0sVVqHinpqxl0sWFPkzcITna61eE2QfnFQtXw== x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?aaxp2I1R15MH5Ooh4/qVYq/mv7TmjR+gpCy3uxjvDs9wzPBaK8ciRHmTJUUm?= =?us-ascii?Q?MUBO2wpRQUv/HIsteajA7pmP1aAE93bFTVjXrpDe0FIMESevBm8TrHaSU+An?= =?us-ascii?Q?Ky3ni/dbFyLFIJloc88NN2fK7ODGWer3MSfi1j+KR00SaVACvLxj6TIw2PYo?= =?us-ascii?Q?Qy/GEcBTLv1J47JpyubU81uFNnBaL+m+mcRqBDs9cscx47R8ri1mOHCVzGML?= =?us-ascii?Q?T1ymaxNWaPuCTiSG/tWoHQ1wlId6k+u2pz3QYLClt1T/fclYdQ5Hlg1PAS6P?= =?us-ascii?Q?pygGumttqF5trVpxPrAjp1OE7DSAphg75HeKxO6KAIHsmeifojfyH0zekJ5T?= =?us-ascii?Q?MDXjuZaz4CxUk0lyVBOG8Jq1KNswzuAEdABnE9hJrBhdy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WZGHRlOYTA3RoGs8ypyq28a4jYXpYvgNu56Vq5jo6vVM5+tJ?= =?us-ascii?Q?xmo9YKDumOhZhgV+ZBZt5+KqW9dcxSxekItW30Cb9vvve1ywFXiaJsy25JVm?= =?us-ascii?Q?gXb4VDw8+lc4Q8PM04Evygbd56a45bcwPTnHRLLihKYGB2iD/wNjvpEu4RIC?= =?us-ascii?Q?DPiLduF0a+LuGJ0NSV4oW/XjTYW78a6p3pHWTXyKVJNn7V2ViFp8ls9ic4w1?= =?us-ascii?Q?SRWeC8PzWU2/TXznH/EKLkJj5bmEiqokWMNmitK2+QCbAgpqiKMSqBXQUnfR?= =?us-ascii?Q?8pYYtGdA/jSJjSPmGaVF8M3kpEJDBV7SAqxW+sFg?= MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MN2PR12MB3966.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 12660ea7-6fba-49e9-1f3c-08dbd43b1a1f X-MS-Exchange-CrossTenant-originalarrivaltime: 24 Oct 2023 02:44:10.8923 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: Cn2ivlytkd1u0hd6lZTfaadWa8xHQ8BX3oRGfSABCAu7iOtVWKCc6NATuR3+FZRxlVR2Xhiv7lkCnYLqwB16pg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN0PR12MB5905 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 Reply-To: devel@edk2.groups.io,abner.chang@amd.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: uCYwgbaojHfXNgNxund90tNJx7686176AA= Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20140610 header.b=NxYJXWu1; dmarc=none; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io; arc=reject ("signature check failed: fail, {[1] = sig:microsoft.com:reject}") [AMD Official Use Only - General] For entire V3 and the additional patch 16/16, Reviewed-by: Abner Chang I will do the Uncrustify check and merge this patch set once the correspond= ing edk2 changes are merged. Thanks Abner > -----Original Message----- > From: Konstantin Aladyshev > Sent: Monday, October 23, 2023 9:05 PM > To: devel@edk2.groups.io > Cc: Chang, Abner ; Attar, AbdulLateef (Abdul > Lateef) ; nicklew@nvidia.com; Konstantin > Aladyshev > Subject: [PATCH edk2-platforms v3 00/16] MTCP-over-KCS support > > Caution: This message originated from an External Source. Use proper caut= ion > when opening attachments, clicking links, or responding. > > > The Manageability KCS transport library needs to support requests both > from MCTP and IPMI transports. Currently the code only handles IPMI > case correctly. > In the MCTP case the communication should be based on the MCTP-over-KCS > specification (DSP0254). This specification defines a special KCS > binding header and trailer structures that need to be present in every > MCTP message. > The header structure contains a length field, therefore response packet > size is not needed to be known beforehand. > The trailer structure contains a PEC checksum that can be used to check > itegrity of the response message. > Modify Manageability KCS transport library code to check which message > is processed (IPMI or MCTP) and handle each case correctly based on its > own specification. > This patch is a result of a joint effort from the Konstantin Aladyshev > and Abner Chang . > > Tested: > PLDM communication between the HOST and BMC was tested with both > components implemented via open-source software: > - The HOST (UEFI firmware) part was based one the edk2 [1] and > edk2-platforms [2] code, > - The BMC part was based on the openbmc [3] distribution. > > The testing process and all the necessary utilities are described in > the [4] repository. > > The provided changes keep IPMI over KCS stack working as reported by > Abner Chang. > > [1]: https://github.com/tianocore/edk2 > [2]: https://github.com/tianocore/edk2-platforms > [3]: https://github.com/openbmc/openbmc > [4]: https://github.com/Kostr/PLDM > > Changes v2 -> v3: > - Add new patch that adds PLDM completion code check > > Changes v1 -> v2: > - Add new patches with corrections for the PLDM protocol. The > resulting communication via EDKII_PLDM_PROTOCOL was successfully > tested. > > Abner Chang (4): > ManageabilityPkg: Add PLDM terminus PCDs > PldmProtocolDxe: Correct TID argument usage > ManageabilityPkg/PldmProtocol: Remove PLDM command table > PldmSmbiosTransferDxe: Implement Set PLDM terminus ID API > > Konstantin Aladyshev (12): > ManageabilityPkg: Add definition for the MCTP KCS TRAILER structure > ManageabilityPkg: Check MCTP EIDs for reserved values > ManageabilityPkg: Support both MCTP and IPMI in KCS tranport library > ManageabilityPkg: Check header fields in the MCTP response > ManageabilityPkg: Correct typo in MCTP destination EID field > ManageabilityPkg: Update the algorithm of using MCTP endpoint ID PCD > ManageabilityPkg: Correct value for the MCTP TAG_OWNER response bit > ManageabilityPkg: Don't check MCTP header fields if transfer has > failed > ManageabilityPkg: Use correct constants for PLDM header checks > ManageabilityPkg: Return error on multiple-packet MCTP responses > ManageabilityPkg: Return error on PLDM header check fails > ManageabilityPkg: Check PLDM completion code > > .../Include/Library/BasePldmProtocolLib.h | 16 + > .../Library/ManageabilityTransportMctpLib.h | 9 +- > .../Include/Protocol/MctpProtocol.h | 12 +- > .../Include/Protocol/PldmProtocol.h | 18 +- > .../Protocol/PldmSmbiosTransferProtocol.h | 26 ++ > .../Common/KcsCommon.c | 284 +++++++++++++++--- > .../Dxe/ManageabilityTransportMctp.c | 4 +- > .../PldmProtocolLibrary/Dxe/PldmProtocolLib.c | 49 ++- > .../Dxe/PldmProtocolLib.inf | 6 +- > .../ManageabilityPkg/ManageabilityPkg.dec | 6 + > .../MctpProtocol/Common/MctpProtocolCommon.c | 129 +++++++- > .../Universal/MctpProtocol/Dxe/MctpProtocol.c | 51 +++- > .../PldmProtocol/Common/PldmProtocolCommon.c | 148 +++------ > .../PldmProtocol/Common/PldmProtocolCommon.h | 25 +- > .../Universal/PldmProtocol/Dxe/PldmProtocol.c | 69 ++++- > .../PldmProtocol/Dxe/PldmProtocolDxe.inf | 4 - > .../PldmSmbiosTransferDxe.c | 28 ++ > 17 files changed, 690 insertions(+), 194 deletions(-) > > -- > 2.34.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#109980): https://edk2.groups.io/g/devel/message/109980 Mute This Topic: https://groups.io/mt/102134646/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-