From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=40.92.69.27; helo=eur02-ve1-obe.outbound.protection.outlook.com; envelope-from=marvin.haeuser@outlook.com; receiver=edk2-devel@lists.01.org Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-oln040092069027.outbound.protection.outlook.com [40.92.69.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id B77D622352291 for ; Tue, 27 Feb 2018 13:30:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=cJaIHNR8PE4D3biDYZH39Em8v7lQUJPnsgcwsMnmNiQ=; b=XlOHbjie+cWx5+DeSxEPtvVhPSxDKlkqOETkbe/9s/b267tHNZOA92uvSF2iTfLo0m21qJglXcmvwt+ck35kjTv1JeZgQxnwkORdPzoUltaBfSz78Jln590g9oY3vuLcLNoKUYgJe4XKwjO/1avLduHDYAS1Te9LWjsSjyV1i1jgSczN1Ifh0rKnvt9pjJAwqM+ZOA+95FC9WSaaFNx8RaGF4I0QY/eRd5ZNVKW0b3d0HFacup39ZdyrFSlOKN652qh73qMrNnlpMwaHBx0+6P9iEaNHggkjNCKTfLlqHiMBedfHW2ZZdzkmY8po3z9eJ+7TuUIr+DwKUQGDGgHWCw== Received: from HE1EUR02FT043.eop-EUR02.prod.protection.outlook.com (10.152.10.53) by HE1EUR02HT167.eop-EUR02.prod.protection.outlook.com (10.152.11.136) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.527.15; Tue, 27 Feb 2018 21:36:06 +0000 Received: from AM4PR06MB1491.eurprd06.prod.outlook.com (10.152.10.55) by HE1EUR02FT043.mail.protection.outlook.com (10.152.11.140) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.527.15 via Frontend Transport; Tue, 27 Feb 2018 21:36:06 +0000 Received: from AM4PR06MB1491.eurprd06.prod.outlook.com ([fe80::7d81:9d96:1051:d20d]) by AM4PR06MB1491.eurprd06.prod.outlook.com ([fe80::7d81:9d96:1051:d20d%14]) with mapi id 15.20.0527.021; Tue, 27 Feb 2018 21:36:06 +0000 From: Marvin H?user To: "edk2-devel@lists.01.org" CC: Felix Polyudov , "michael.d.kinney@intel.com" , "manickavasakamk@ami.com" , "liming.gao@intel.com" Thread-Topic: [edk2] [Patch v2] MdePkg/Include/IndustryStandard: Add PCI Express 4.0 header file Thread-Index: AQHTsA7hu++tXwdYSEq1yhTx4WIY46O4xVFw Date: Tue, 27 Feb 2018 21:36:05 +0000 Message-ID: References: <20180227210640.7536-1-felixp@ami.com> In-Reply-To: <20180227210640.7536-1-felixp@ami.com> Accept-Language: de-DE, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-incomingtopheadermarker: OriginalChecksum:155776FECED2A54FD19EBA322D5FCBF1D45E71FD5B5A11C5022514EE84FA8365; UpperCasedChecksum:D8D31B903F2CBAE382DCFD06BAE2B7E299C885CDD9886CFEB15F4784C4FE5627; SizeAsReceived:7259; Count:46 x-tmn: [11HvBofAWsYoQrOUJPE1Kj0JpFivs8SR] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; HE1EUR02HT167; 6:WetU1t4dGfNR+2Ibn4vV98rSZsL8lKwpJYRwztsuxfHxZT7pv/GahzyqotNHZ05B4QCknIy4TN/7u6+Puwyf/vllecm72n0HRmShfnGKE5g70mLba9l9sKfNfJdb+ijjd1MCAvZrW1vuttpUUGldgBW2Z4kATLnRxQH7qx4fuEX/N+L52wqbcjxSIegMVI9OVZqj99VrUENjxg83aKNGdFWPQ1x7Se0UX4FmJ5xfsi5G4tRR6t638zAVBzo2LqD6VTL8DzBZ+9WZeHwnaXa2uSkBOng2AfCadUmDfWJzqyt3IvBuKCsKQImKPE7206TjoAtdXOuMp4wKoN0iv/02vPDtbEnZb2d9yy1TIFEAYNY=; 5:yKnTsPUFRGtAF1qwKYjI+3hEAdjqY1hXeDZgQdnsId1SwMzeb4S961RLdhdj9sYQXzeGWdirFSrUtJPlWn3j3CDtJhN+8pcWTuvCvz/0pFz9I8nlLl4MKfH1XdgXh9SzVjGEROU11wIiaXG08RVhQdpSb7Op6/7GBZMfITt7K+8=; 24:/azvckYsj/wLAWK2T8xoBbvKgiEKmFxglBajVzB+4BnMJm/IP5wBnLpz8FeLlBjsCBEgZe2aHYbJs6tzxQ8pNpkXhGIUKZLlLdJIuZC93Qw=; 7:ZFjzaXHioGtC/SgF+hkYKBqRbNP/baS74802DQhP71bkZB1IW++ljchoJ1mrTlYkdrSiVlrYhO5baZmaoS0nu+wMGQVUEcADz0I5CypjvJ5thQYLo0qCNxMsm8Ecyalk6gGDhIC9Vus8M2xFvz7dfovbzCxrhObhSWqwWh4W4l9OreGNmV4OOtwhkvmCLHCtVu4JF7nBXlpm76fRMyCEWzKt0hBRN+/U2vOBBQMpfDkKwzCjU69i/hIZsZShyOHh x-incomingheadercount: 46 x-eopattributedmessage: 0 x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(201702061078)(5061506573)(5061507331)(1603103135)(2017031320274)(2017031324274)(2017031323274)(2017031322404)(1601125374)(1603101448)(1701031045); SRVR:HE1EUR02HT167; x-ms-traffictypediagnostic: HE1EUR02HT167: x-ms-office365-filtering-correlation-id: fbfbf59c-adf3-4ae4-5f92-08d57e2a1baf x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(444000031); SRVR:HE1EUR02HT167; BCL:0; PCL:0; RULEID:; SRVR:HE1EUR02HT167; x-forefront-prvs: 05961EBAFC x-forefront-antispam-report: SFV:NSPM; SFS:(7070007)(98901004); DIR:OUT; SFP:1901; SCL:1; SRVR:HE1EUR02HT167; H:AM4PR06MB1491.eurprd06.prod.outlook.com; FPR:; SPF:None; LANG:; spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: fbfbf59c-adf3-4ae4-5f92-08d57e2a1baf X-MS-Exchange-CrossTenant-originalarrivaltime: 27 Feb 2018 21:36:06.0059 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Internet X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1EUR02HT167 Subject: Re: [Patch v2] MdePkg/Include/IndustryStandard: Add PCI Express 4.0 header file X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Feb 2018 21:30:03 -0000 Content-Language: de-DE Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Good day, Please consider for compatibility with some toolchains, byte-packed structs= and unions must be decorated with the define 'PACKED'. Thanks, Marvin. > -----Original Message----- > From: edk2-devel On Behalf Of Felix > Polyudov > Sent: Tuesday, February 27, 2018 10:07 PM > To: edk2-devel@lists.01.org > Cc: michael.d.kinney@intel.com; manickavasakamk@ami.com; > liming.gao@intel.com > Subject: [edk2] [Patch v2] MdePkg/Include/IndustryStandard: Add PCI > Express 4.0 header file >=20 > v2: The structure is updated to include all the fields defined in the PCI= -E > specification. >=20 > The header includes Physical Layer PCI Express Extended Capability > definitions described in section 7.7.5 of PCI Express Base Specification = rev. > 4.0. >=20 > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Felix Polyudov > --- > MdePkg/Include/IndustryStandard/PciExpress40.h | 89 > ++++++++++++++++++++++++++ > 1 file changed, 89 insertions(+) > create mode 100644 MdePkg/Include/IndustryStandard/PciExpress40.h >=20 > diff --git a/MdePkg/Include/IndustryStandard/PciExpress40.h > b/MdePkg/Include/IndustryStandard/PciExpress40.h > new file mode 100644 > index 0000000..a832259 > --- /dev/null > +++ b/MdePkg/Include/IndustryStandard/PciExpress40.h > @@ -0,0 +1,89 @@ > +/** @file > +Support for the PCI Express 4.0 standard. > + > +This header file may not define all structures. Please extend as requir= ed. > + > +Copyright (c) 2018, American Megatrends, Inc. All rights reserved.
> +This program and the accompanying materials are licensed and made > +available under the terms and conditions of the BSD License which > +accompanies this distribution. The full text of the license may be > +found at http://opensource.org/licenses/bsd-license.php > + > +THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" > BASIS, > +WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER > EXPRESS OR IMPLIED. > + > +**/ > + > +#ifndef _PCIEXPRESS40_H_ > +#define _PCIEXPRESS40_H_ > + > +#include > + > +#pragma pack(1) > + > +/// The Physical Layer PCI Express Extended Capability definitions. > +/// > +/// Based on section 7.7.5 of PCI Express Base Specification 4.0. > +///@{ > +#define PCI_EXPRESS_EXTENDED_CAPABILITY_PHYSICAL_LAYER_16_0_ID > 0x0026 > +#define > PCI_EXPRESS_EXTENDED_CAPABILITY_PHYSICAL_LAYER_16_0_VER1 0x1 > + > +// Register offsets from Physical Layer PCI-E Ext Cap Header > +#define PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_CAPABILITIES_OFFSET > 0x04 > +#define PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_CONTROL_OFFSET > 0x08 > +#define PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_STATUS_OFFSET > 0x0C > +#define > PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_LOCAL_DATA_PARITY_STATUS_ > OFFSET 0x10 > +#define > PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_FIRST_RETIMER_DATA_PARITY_ > STATUS_OFFSET 0x14 > +#define > PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_SECOND_RETIMER_DATA_PARIT > Y_STATUS_OFFSET 0x18 > +#define > PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_LANE_EQUALIZATION_CONTROL > _OFFSET 0x20 > + > +typedef union { > + struct { > + UINT32 Reserved : 32; // Reserved bit 0:31 > + } Bits; > + UINT32 Uint32; > +} PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_CAPABILITIES; > + > +typedef union { > + struct { > + UINT32 Reserved : 32; // Reserved bit 0:31 > + } Bits; > + UINT32 Uint32; > +} PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_CONTROL; > + > +typedef union { > + struct { > + UINT32 EqualizationComplete : 1; // bit 0 > + UINT32 EqualizationPhase1Success : 1; // bit 1 > + UINT32 EqualizationPhase2Success : 1; // bit 2 > + UINT32 EqualizationPhase3Success : 1; // bit 3 > + UINT32 LinkEqualizationRequest : 1; // bit 4 > + UINT32 Reserved : 27; // Reserved bit 5:31 > + } Bits; > + UINT32 Uint32; > +} PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_STATUS; > + > +typedef union { > + struct { > + UINT8 DownstreamPortTransmitterPreset : 4; //bit 0..3 > + UINT8 UpstreamPortTransmitterPreset : 4; //bit 4..7 > + } Bits; > + UINT8 Uint8; > +} > PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_LANE_EQUALIZATION_CONTROL > ; > + > +typedef struct { > + PCI_EXPRESS_EXTENDED_CAPABILITIES_HEADER Header; > + PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_CAPABILITIES > Capablities; > + PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_CONTROL Control; > + PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_STATUS Status; > + UINT32 LocalDat= aParityMismatchStatus; > + UINT32 FirstRet= imerDataParityMismatchStatus; > + UINT32 > SecondRetimerDataParityMismatchStatus; > + UINT32 Reserved= ; > + > PCI_EXPRESS_REG_PHYSICAL_LAYER_16_0_LANE_EQUALIZATION_CONTROL > +LaneEqualizationControl; } > +PCI_EXPRESS_EXTENDED_CAPABILITIES_PHYSICAL_LAYER_16_0; > +///@} > + > +#pragma pack() > + > +#endif > -- > 2.10.0.windows.1 >=20 >=20 >=20 > Please consider the environment before printing this email. >=20 > The information contained in this message may be confidential and > proprietary to American Megatrends, Inc. This communication is intended = to > be read only by the individual or entity to whom it is addressed or by th= eir > designee. If the reader of this message is not the intended recipient, yo= u are > on notice that any distribution of this message, in any form, is strictly > prohibited. Please promptly notify the sender by reply e-mail or by > telephone at 770-246-8600, and then delete or destroy all copies of the > transmission. > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel