Hi Tian, Attached are the raw files. The dynamic PCDs were defined in the package's dec file, and are below. The names have been changed.
1. Pcds Section from the .dec file [PcdsDynamic.common] gVendorPolicy.XXXX7|0|BOOLEAN|0x00000001 gVendorPolicy.XXXX5|0|UINT8|0x00000002 gVendorPolicy.ZZZZ|0|UINT16|0x00000003 2. Attached PEIPcdDataBase.raw and DXEPcdDataBase.raw. You will probably need the following tables from autogen.h to help decipher the binaries typedef struct { UINT64 XXXX1_2f9003d7_ac98_407d_ae38_9dbf8127e5b1[1]; UINT64 XXXX2_2f9003d7_ac98_407d_ae38_9dbf8127e5b1[1]; UINT16 ZZZZ_187ab756_9413_eb25_1ead_23581c7b1da4[1]; UINT8 XXXX3_727c1648_5f39_4f34_9e0d_60701b0cfdc5[1]; UINT8 XXXX4_2f9003d7_ac98_407d_ae38_9dbf8127e5b1[1]; UINT8 XXXX5_187ab756_9413_eb25_1ead_23581c7b1da4[1]; BOOLEAN XXXX6_2f9003d7_ac98_407d_ae38_9dbf8127e5b1[1]; BOOLEAN XXXX7_187ab756_9413_eb25_1ead_23581c7b1da4[1]; BOOLEAN XXXX8_727c1648_5f39_4f34_9e0d_60701b0cfdc5[1]; BOOLEAN XXXX9_727c1648_5f39_4f34_9e0d_60701b0cfdc5[1]; } PEI_PCD_DATABASE_UNINIT; 3.The line of code uses the PcdLib to set the value: PcdSet16(ZZZZ, <value>); -----Original Message----- From: Zeng, Star [mailto:star.z...@intel.com] Sent: Wednesday, January 07, 2015 11:53 PM To: edk2-devel@lists.sourceforge.net; Tian, Feng Subject: Re: [edk2] [PATCH] MdeModulePkg: PcdPeim: Unaligned PcdSet in PEI for architectures requiring alignment Hi Aaron, Thanks for the information. For root causing the issue why the unaligned case happened on your platform, could you help share more information? 1. Share the PcdsDynamic sections in your platform dsc file. 2. Share the PEIPcdDataBase.raw and DXEPcdDataBase.ram in $(OUTPUT_DIRECTORY)\$(TARGET)_$(TOOL_CHAIN_TAG)\IA32\MdeModulePkg\Universal\PCD\Pei\Pcd\OUTPUT and $(OUTPUT_DIRECTORY)\$(TARGET)_$(TOOL_CHAIN_TAG)\ X64\MdeModulePkg\Universal\PCD\Dxe\Pcd\OUTPUT. 3. Share which PCD set in PEI cause the issue. Thanks, Star -----Original Message----- From: Aaron Pop [mailto:aar...@ami.com] Sent: Thursday, January 08, 2015 5:40 AM To: Tian, Feng; edk2-devel@lists.sourceforge.net Subject: Re: [edk2] [PATCH] MdeModulePkg: PcdPeim: Unaligned PcdSet in PEI for architectures requiring alignment Hi Feng, This error was encountered on an AARCH64 ARM based platform, in a PEIM driver that was attempting to set a PCD. After we figured out that the unaligned access was causing the exception, we searched in other projects, both X86 and ARM, and did not find any PEIMs that were attempting to set PCD values. We assumed that our project was just one of the few that were trying to use this functionality. As far as the tool needing to generate aligned pcd data... in the PcdPeim, the PeiPcdGetN functions (PeiPcdGet16, PeiPcdGet32, PeiPcdGet64) use the ReadUnalignedN functions on the returned pointers returned by the GetWorker functions. This leads me to believe that unaligned PCD values are allowed by the tool, and that the Set functions were never tested in the same way as the get functions. Best Regards, Aaron -----Original Message----- From: Tian, Feng [mailto:feng.t...@intel.com] Sent: Tuesday, January 06, 2015 8:35 PM To: edk2-devel@lists.sourceforge.net; Aaron Pop Cc: Tian, Feng Subject: RE: [edk2] [PATCH] MdeModulePkg: PcdPeim: Unaligned PcdSet in PEI for architectures requiring alignment Aaron, Sorry for late response. Could you let me know it's a real case or review result? If it's a real case, could you share us how to reproduce it? In PCD_DATABASE_INIT of PcdDataBaseSignatureGuid.h, you can see below comments // // Padding is needed to keep necessary alignment // It means build tool should generate aligned pcd data and make all data access work. Please correct me if I misunderstand something. Thanks Feng -----Original Message----- From: Aaron Pop [mailto:aar...@ami.com] Sent: Tuesday, December 30, 2014 04:50 To: edk2-devel@lists.sourceforge.net Subject: [edk2] [PATCH] MdeModulePkg: PcdPeim: Unaligned PcdSet in PEI for architectures requiring alignment On architectures that require aligned reads/writes, the PCD PEIM can cause a misaligned access exception. This stems from the PcdPeim's SetWorker not using the WriteUnalignedN functions from the BaseLib. The attached patch file includes modifications to the PEIM that enforce unaligned access for calls to PcdSet. Best Regards, Aaron 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 their designee. If the reader of this message is not the intended recipient, you 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. 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 their designee. If the reader of this message is not the intended recipient, you 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. ------------------------------------------------------------------------------ Dive into the World of Parallel Programming! The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net _______________________________________________ edk2-devel mailing list edk2-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/edk2-devel ------------------------------------------------------------------------------ Dive into the World of Parallel Programming! The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net _______________________________________________ edk2-devel mailing list edk2-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/edk2-devel 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 their designee. If the reader of this message is not the intended recipient, you 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.
PEIPcdDataBase.raw
Description: PEIPcdDataBase.raw
DXEPcdDataBase.raw
Description: DXEPcdDataBase.raw
------------------------------------------------------------------------------ Dive into the World of Parallel Programming! The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net
_______________________________________________ edk2-devel mailing list edk2-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/edk2-devel