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 DF1CFAC0E6B for ; Thu, 4 Apr 2024 09:11:21 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=8JLkKBL//s8iZw3RwmFBIXnN3z+i2ldA+W0meECjHso=; c=relaxed/simple; d=groups.io; h=Received-SPF:From:To:CC:Subject:Date:Message-ID:In-Reply-To:References:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Resent-Date:Resent-From:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Transfer-Encoding:Content-Type; s=20240206; t=1712221880; v=1; b=q44E/lJ25uM0F1xRZmShjndhZ/dsMOunmDMTRzakKGOBgxIWIsJiPYs141G60PFHLL97Tp5B OHIsGXUBEkHfKN0E0Mg5ww6dIsr9rVSejz2BTK6waaJQTmAN/zB5u/x5x7Pu8ea+YqZMdQmKe/4 mvGKxkdToKzE7tHG6GEBxJbPS8EzTaatw+9vhMAFRinRvYFzJeb3wltKV3Ey6dGe+nrGeib5ewn V2MgmP1dyPhhPBY8A/XJlElDgMGy7H+U2QghNSxKFbSSom9PzJz6RZdo/KCynMYDzDuyLcN/IYJ Sg+MxVyIxZSiOAfdIvbDDPKTtYVMGipFl8Nji23YR7ROw== X-Received: by 127.0.0.2 with SMTP id aGI1YY7687511xDrhlQpo0Bu; Thu, 04 Apr 2024 02:11:20 -0700 X-Received: from NAM11-CO1-obe.outbound.protection.outlook.com (NAM11-CO1-obe.outbound.protection.outlook.com [40.107.220.68]) by mx.groups.io with SMTP id smtpd.web11.33679.1712221879636930893 for ; Thu, 04 Apr 2024 02:11:19 -0700 X-Received: from BN9P221CA0028.NAMP221.PROD.OUTLOOK.COM (2603:10b6:408:10a::10) by PH7PR12MB6719.namprd12.prod.outlook.com (2603:10b6:510:1b2::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.46; Thu, 4 Apr 2024 09:11:16 +0000 X-Received: from BN2PEPF000044A6.namprd04.prod.outlook.com (2603:10b6:408:10a:cafe::23) by BN9P221CA0028.outlook.office365.com (2603:10b6:408:10a::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7409.46 via Frontend Transport; Thu, 4 Apr 2024 09:11:15 +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 X-Received: from SATLEXMB04.amd.com (165.204.84.17) by BN2PEPF000044A6.mail.protection.outlook.com (10.167.243.100) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.7452.22 via Frontend Transport; Thu, 4 Apr 2024 09:11:15 +0000 X-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.2507.35; Thu, 4 Apr 2024 04:11:13 -0500 From: "Chang, Abner via groups.io" To: CC: Michael D Kinney , Liming Gao , Zhiguang Liu , "Abdul Lateef Attar" , Brit Chesley Subject: [edk2-devel] [PATCH RESEND V4 1/6] MdePkg/Include: Update definitions of SPI related header files Date: Thu, 4 Apr 2024 17:10:47 +0800 Message-ID: <20240404091052.794-2-abner.chang@amd.com> In-Reply-To: <20240404091052.794-1-abner.chang@amd.com> References: <20240404091052.794-1-abner.chang@amd.com> MIME-Version: 1.0 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: BN2PEPF000044A6:EE_|PH7PR12MB6719:EE_ X-MS-Office365-Filtering-Correlation-Id: c4983269-ea52-4565-0ed7-08dc54872e7c X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Message-Info: zCb5/ttgw2Sb7NL5GdQdsEO1jz7lhShV2YGRKg3+aVlP2ZOFslG/3lPksPqHPjnE/c4QOR2c2ZPdiVYCGC+DcZOymda+Th+CymEczJ4/FDiiD06v1kKb5UZDz4+p9r3yivHoogDI49/sToSSNR5c6lEXrNYL8C4JQBALtjGhFkweKBSQwz2+Uol4XZEqu1Frk+ezXwacwnlpvjQnLwHB27UhbEvib9LyMph/nkMJ/KnYRFj+DgZw67IiNsz/b6oA03IZmaZpTMk4dAei5opiR92ZMEdms19KL9Djspl4ujU6yUVj69J6j5+SOtNr5yjNKl8t7BU61CyF4+a4M49ZqBSDyIse8N271zWfkMfuVcmLGs2QyqQ0Ww7NWTaHUuhVmLaEKNHkaah0E4cbe7WAOYW3csij69SzB7jdSYW0+OSv9tOaWODiEbpFXJbvZOs3cnYWjBbzA0IjwRCE8ZEjGZOnVk/BdkHb1Q2y0hTJDUxmsBmGLj0KNLf/S1dT1a1SDKDcsIybLiFK138oA5wCPfrA7XPHrCRcYP/OumbECLRi/PF+rpV5tJF9+qZ75vTHoQ/ZPcwjAyyfC+DVwPLotvGOzaLih/feIy25iD+DUaMF6k4MCzypNq2GlSc7UWsFneiizoQyFrMfC720AgYEVC7PJbgL05lVka3GL9MFdGW68qPxj+vSzATNl9Wi54x6QLWlf0IW0R2TBN8Au8RljKp4ETAA45YTUSCWZ8Mo5LHMRRf9PJDohKsd6jYyepLA X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Apr 2024 09:11:15.4780 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: c4983269-ea52-4565-0ed7-08dc54872e7c 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: BN2PEPF000044A6.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH7PR12MB6719 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: Thu, 04 Apr 2024 02:11:19 -0700 Resent-From: abner.chang@amd.com Reply-To: devel@edk2.groups.io,abner.chang@amd.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: Dc93fTo080w1G4ZaglJnaL1Rx7686176AA= Content-Transfer-Encoding: quoted-printable 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="q44E/lJ2"; dmarc=pass (policy=none) header.from=groups.io; spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce@groups.io From: abnchang BZ#: 4471 Update definitions according to PI spec 1.8 errata A Signed-off-by: Abner Chang Cc: Michael D Kinney Cc: Liming Gao Cc: Zhiguang Liu Cc: Abdul Lateef Attar Cc: Brit Chesley --- MdePkg/Include/Protocol/SpiConfiguration.h | 10 +++++++++- MdePkg/Include/Protocol/SpiHc.h | 16 +++++++++++++++- MdePkg/Include/Protocol/SpiIo.h | 12 +++++++++++- 3 files changed, 35 insertions(+), 3 deletions(-) diff --git a/MdePkg/Include/Protocol/SpiConfiguration.h b/MdePkg/Include/Pr= otocol/SpiConfiguration.h index 3f8fb9ff62c..120b54bbad8 100644 --- a/MdePkg/Include/Protocol/SpiConfiguration.h +++ b/MdePkg/Include/Protocol/SpiConfiguration.h @@ -2,10 +2,11 @@ This file defines the SPI Configuration Protocol. =20 Copyright (c) 2017, Intel Corporation. All rights reserved.
+ Copyright (C) 2024 Advanced Micro Devices, Inc. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent =20 @par Revision Reference: - This Protocol was introduced in UEFI PI Specification 1.6. + This Protocol was introduced in UEFI PI Specification 1.8 A. =20 **/ =20 @@ -168,6 +169,13 @@ typedef struct _EFI_SPI_BUS { VOID *ClockParameter; } EFI_SPI_BUS; =20 +/// +/// Definitions of SPI Part Attributes. +/// +#define SPI_PART_SUPPORTS_2_BIT_DATA_BUS_WIDTH BIT0 +#define SPI_PART_SUPPORTS_4_B1T_DATA_BUS_WIDTH BIT1 +#define SPI_PART_SUPPORTS_8_B1T_DATA_BUS_WIDTH BIT2 + /// /// The EFI_SPI_PERIPHERAL data structure describes how a specific block o= f /// logic which is connected to the SPI bus. This data structure also sele= cts diff --git a/MdePkg/Include/Protocol/SpiHc.h b/MdePkg/Include/Protocol/SpiH= c.h index 30128dd5c4d..354de721606 100644 --- a/MdePkg/Include/Protocol/SpiHc.h +++ b/MdePkg/Include/Protocol/SpiHc.h @@ -2,10 +2,11 @@ This file defines the SPI Host Controller Protocol. =20 Copyright (c) 2017, Intel Corporation. All rights reserved.
+ Copyright (C) 2024 Advanced Micro Devices, Inc. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent =20 @par Revision Reference: - This Protocol was introduced in UEFI PI Specification 1.6. + This Protocol was introduced in UEFI PI Specification 1.8 A. =20 **/ =20 @@ -121,6 +122,19 @@ typedef EFI_STATUS IN EFI_SPI_BUS_TRANSACTION *BusTransaction ); =20 +/// +/// Definitions of SPI Host Controller Attributes. +/// +#define HC_SUPPORTS_WRITE_ONLY_OPERATIONS BIT0 +#define HC_SUPPORTS_READ_ONLY_OPERATIONS BIT1 +#define HC_SUPPORTS_WRITE_THEN_READ_OPERATIONS BIT2 +#define HC_TX_FRAME_IN_MOST_SIGNIFICANT_BITS BIT3 +#define HC_RX_FRAME_IN_MOST_SIGNIFICANT_BITS BIT4 +#define HC_SUPPORTS_2_BIT_DATA_BUS_WIDTH BIT5 +#define HC_SUPPORTS_4_BIT_DATA_BUS_WIDTH BIT6 +#define HC_SUPPORTS_8_BIT_DATA_BUS_WIDTH BIT7 +#define HC_TRANSFER_SIZE_INCLUDES_OPCODE BIT8 +#define HC_TRANSFER_SIZE_INCLUDES_ADDRESS BIT9 /// /// Support a SPI data transaction between the SPI controller and a SPI ch= ip. /// diff --git a/MdePkg/Include/Protocol/SpiIo.h b/MdePkg/Include/Protocol/SpiI= o.h index b4fc5e03b88..2c95a375a20 100644 --- a/MdePkg/Include/Protocol/SpiIo.h +++ b/MdePkg/Include/Protocol/SpiIo.h @@ -2,10 +2,11 @@ This file defines the SPI I/O Protocol. =20 Copyright (c) 2017, Intel Corporation. All rights reserved.
+ Copyright (C) 2024 Advanced Micro Devices, Inc. All rights reserved. SPDX-License-Identifier: BSD-2-Clause-Patent =20 @par Revision Reference: - This Protocol was introduced in UEFI PI Specification 1.6. + This Protocol was introduced in UEFI PI Specification 1.8 A. =20 **/ =20 @@ -223,6 +224,15 @@ typedef struct _EFI_SPI_BUS_TRANSACTION { UINT8 *ReadBuffer; } EFI_SPI_BUS_TRANSACTION; =20 +/// +/// Definitions of SPI I/O Attributes. +/// +#define SPI_IO_SUPPORTS_2_BIT_DATA_BUS_WIDTH BIT0 +#define SPI_IO_SUPPORTS_4_BIT_DATA_BUS_WIDTH BIT1 +#define SPI_IO_SUPPORTS_8_BIT_DATA_BUS_WIDTH BIT2 +#define SPI_IO_TRANSFER_SIZE_INCLUDES_OPCODE BIT3 +#define SPI_IO_TRANSFER_SIZE_INCLUDES_ADDRESS BIT4 + /// /// Support managed SPI data transactions between the SPI controller and a= SPI /// chip. --=20 2.37.1.windows.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 (#117406): https://edk2.groups.io/g/devel/message/117406 Mute This Topic: https://groups.io/mt/105325625/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-