From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2a01:111:f400:fe46::728; helo=nam02-bl2-obe.outbound.protection.outlook.com; envelope-from=christopher.co@microsoft.com; receiver=edk2-devel@lists.01.org Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0728.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe46::728]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id CBD7A2118F79B for ; Mon, 3 Dec 2018 17:44:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=+ppePvAOj5WgZKm7BqDzvmak0bTYfmkMiXl3xXX5tOI=; b=KHQc/NZejTeBPsLO6goe51BPv0y4lUPsa5PV+sp0TRWztFEbhpw2PhP7c4UDjmxymuFDAuU9LSUfMCz837ufJT8xIGkAitnQGy7SGBs0qmMmovY8YooczsweKjKUyH3lbVTDyOsFYRBBvKGo/8eA2RkLWPaZyLTd9z1f7M7mr4k= Received: from DM5PR21MB0186.namprd21.prod.outlook.com (10.173.173.137) by DM5PR21MB0857.namprd21.prod.outlook.com (10.173.172.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1425.2; Tue, 4 Dec 2018 01:44:52 +0000 Received: from DM5PR21MB0186.namprd21.prod.outlook.com ([fe80::9115:7193:d145:d0f5]) by DM5PR21MB0186.namprd21.prod.outlook.com ([fe80::9115:7193:d145:d0f5%6]) with mapi id 15.20.1425.005; Tue, 4 Dec 2018 01:44:52 +0000 From: Chris Co To: Leif Lindholm CC: "edk2-devel@lists.01.org" , Ard Biesheuvel , Michael D Kinney Thread-Topic: [PATCH edk2-platforms 09/27] Silicon/NXP: Add headers for SoC-specific i.MX packages to use Thread-Index: AQHUUYS6Td0Qdv51FkilLzYFFMJClqU7fA4AgC32pnCAA8NVAIABDBRg Date: Tue, 4 Dec 2018 01:44:52 +0000 Message-ID: References: <20180921082542.35768-1-christopher.co@microsoft.com> <20180921082542.35768-10-christopher.co@microsoft.com> <20181101182020.w5qvmjbi3ukhxf2t@bivouac.eciton.net> <20181203094241.n6nbk4zvs73xf4k3@bivouac.eciton.net> In-Reply-To: <20181203094241.n6nbk4zvs73xf4k3@bivouac.eciton.net> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Enabled=True; MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_SiteId=72f988bf-86f1-41af-91ab-2d7cd011db47; MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Owner=chrco@microsoft.com; MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_SetDate=2018-12-04T01:44:50.6348542Z; MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Name=General; MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Application=Microsoft Azure Information Protection; MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Extended_MSFT_Method=Automatic; Sensitivity=General x-originating-ip: [2001:4898:80e8:1:6928:7d3d:7cac:2222] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; DM5PR21MB0857; 6:3vjLxbV3P9AhNduz2+QGG12tSVhNwyErpXMaXTwTard4OdH6xIbAFDT581t7VgGEEIUFgsS31V9rBnYiW8cxLDvkxShqEZ7wlQT2bAZCP+x482hoxV0psMtvefgiNchVN5yUO1wSHTRoocrKzG6Llv1ZgFbT2VL99Ibimp1/wsCJRjKdhkGZPDSN14O06KJdhRZWPtdXhkrQcNNOQo7yI16aXt8XVrsnXaSzJJMnMstrGhNPNB4Kf0ODogg519mQ/MjuYBci0haf5dfmlmRcbGz2oHFNDQZE3YJdVJJsLo/pB+jrrBPoDSaamUmI68gCOg20DJseNjHIQCOhEoRUgNBY9ZoNE3QgvBinKoQ8yiB5ZefVT1kNdaK3Gv+VJjOH2xSobGZdzbH/y/rYVLJxPc0xgX36C2shbcyWfblAgBfsmr+ewMrOHJW4PS75zz1hz/ouisAnjKw/a+mgeams/w==; 5:Id8cXasdwOJJpZgn9cyZHJ9qDO8W0AqkRXFpUFRNE9EneJsiB1q8McwvTR6t1mVe+ovkQ3HW8tUy2b1PbUzU0n1M/chp8U0LUH4yTcF5YfiAVTHHlnwZ3yi+qR+nYg003NPfv4i1OwFCgLBLwBc6lIEdAIidnRsSIp+4N6GDD2I=; 7:Yxtog0/xHvKC5PHla9XQ7c7tvPFOOd2bbZsbtoVPUJDfoc4OXWi0JvuIbxAjh+k42RkKKpcsU+b98lvemkxv+SUSWZKehIT4OWyWU/xyn8CFgU1kXAjEhUU/RMjXsjw9nThB3Ijlwx/0MOFiJPHXdw== x-ms-exchange-antispam-srfa-diagnostics: SOS; x-ms-office365-filtering-correlation-id: 0074885b-4de6-4837-c52c-08d6598a1596 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390098)(7020095)(4652040)(8989299)(5600074)(711020)(4618075)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(2017052603328)(7193020); SRVR:DM5PR21MB0857; x-ms-traffictypediagnostic: DM5PR21MB0857: x-ms-exchange-purlcount: -3 authentication-results: spf=none (sender IP is ) smtp.mailfrom=Christopher.Co@microsoft.com; x-microsoft-antispam-prvs: x-ms-exchange-senderadcheck: 1 x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(8220035)(2401047)(8121501046)(5005006)(93006095)(93001095)(3231455)(999002)(944501505)(2018427008)(3002001)(10201501046)(6055026)(148016)(149066)(150057)(6041310)(20161123562045)(20161123558120)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(201708071742011)(7699051)(76991095); SRVR:DM5PR21MB0857; BCL:0; PCL:0; RULEID:; SRVR:DM5PR21MB0857; x-forefront-prvs: 0876988AF0 x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(136003)(376002)(366004)(396003)(346002)(39860400002)(199004)(189003)(13464003)(6506007)(476003)(5660300001)(99286004)(7736002)(76176011)(53546011)(71200400001)(71190400001)(7696005)(53936002)(55016002)(9686003)(6436002)(305945005)(6246003)(25786009)(4326008)(22452003)(93886005)(186003)(316002)(68736007)(11346002)(54906003)(446003)(102836004)(46003)(6916009)(86362001)(229853002)(74316002)(86612001)(486006)(6116002)(33656002)(8990500004)(2906002)(14454004)(10090500001)(8676002)(81166006)(72206003)(256004)(81156014)(478600001)(10290500003)(105586002)(106356001)(97736004)(8936002); DIR:OUT; SFP:1102; SCL:1; SRVR:DM5PR21MB0857; H:DM5PR21MB0186.namprd21.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: microsoft.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: EcFw9mxmpgPFWeQslE0K6IHmC3ebejOhfm7D+cN8ekwEy7od7iOwAeUQc/t8I9CM4lqteb8l44PHjC1rq27uE1tRqfrwHRe8W+DPyQEFsmRKs+BOf7tc/kjdAJudoUYWGTSRablL4Ek8ZiyBXQnUMsbkyq+2eGTns6pwWiAK9ynNXbB6BKNeBrlYqVFyvRq5pSje0su3wWj18wdWn/rfXsoXpfnHcTr4+E1qTYwlxqi9V9Xnc5He2eAayqD6R10jASYzfytdt8Xmnp7Ez1AEDujF1G/sNUqti0Q4Mf/RlD/keeORYzbCgvpzKk+7/OR698KCfcPl2RtCgV8QimuREEKYlkAy77B7OHWBkREuKeo= spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: microsoft.com X-MS-Exchange-CrossTenant-Network-Message-Id: 0074885b-4de6-4837-c52c-08d6598a1596 X-MS-Exchange-CrossTenant-originalarrivaltime: 04 Dec 2018 01:44:52.0724 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR21MB0857 Subject: Re: [PATCH edk2-platforms 09/27] Silicon/NXP: Add headers for SoC-specific i.MX packages to use X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Dec 2018 01:44:55 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable > -----Original Message----- > From: Leif Lindholm > Sent: Monday, December 3, 2018 1:43 AM > To: Chris Co > Cc: edk2-devel@lists.01.org; Ard Biesheuvel ; > Michael D Kinney > Subject: Re: [PATCH edk2-platforms 09/27] Silicon/NXP: Add headers for So= C- > specific i.MX packages to use >=20 > On Sat, Dec 01, 2018 at 12:22:17AM +0000, Chris Co wrote: > > > If using EFI_ACPI prefix, these #defines really should be in edk2 > > > MdePkg. And CSRT itself is, so that might not be a bad idea. > > > > > > > + > > > > +#pragma pack(push, 1) > > > > > > I don't see this #pragma making any difference to the structs below, > > > can it be dropped? > > > > The pragma pack is defensive. Without it, we rely on the compiler > > packing structures by default and this may not happen on 64 bit > > compiles. >=20 > I understand that is what the pragma does. My comment was because all of = the > variables in the below structs are naturally aligned. > The reason I dislike its use when effectively a no-op, is that it makes i= t look like it > it isn't a no-op. >=20 > If it covers a larger set of structs, some of which require the packed at= tribute I'm > OK with that. But I'm not a fan of adding it "just in case" without conte= mplating > the statement's (lack of) effect. >=20 > Regards, >=20 > Leif >=20 Makes sense. I am checking to make sure this pragma wasn't included due to = some observed compiler behavior on our end, since this header is also used = on our ARM64 work. Will remove it once confirmed it is safe. Thanks, Chris > > I have addressed the remaining feedback and will resubmit with v2. > > > > Thanks, > > Chris > > > > > > +//--------------------------------------------------------------- > > > > +---- > > > > +----- // CSRT Resource Group header 24 bytes long > > > > +//--------------------------------------------------------------- > > > > +---- > > > > +----- > > > > +typedef struct { > > > > + UINT32 Length; > > > > + UINT32 VendorID; > > > > + UINT32 SubVendorId; > > > > + UINT16 DeviceId; > > > > + UINT16 SubdeviceId; > > > > + UINT16 Revision; > > > > + UINT16 Reserved; > > > > + UINT32 SharedInfoLength; > > > > +} EFI_ACPI_5_0_CSRT_RESOURCE_GROUP_HEADER; > > > > + > > > > +//--------------------------------------------------------------- > > > > +---- > > > > +----- // CSRT Resource Descriptor 12 bytes total > > > > +//--------------------------------------------------------------- > > > > +---- > > > > +----- > > > > +typedef struct { > > > > + UINT32 Length; > > > > + UINT16 ResourceType; > > > > + UINT16 ResourceSubType; > > > > + UINT32 UID; > > > > +} EFI_ACPI_5_0_CSRT_RESOURCE_DESCRIPTOR_HEADER; > > > > +#pragma pack (pop)