summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* UefiCpuPkg/LocalApic.h: Remove duplicated/conflicted definitionsJeff Fan2016-08-177-71/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | #define MSR_IA32_APIC_BASE_ADDRESS is duplicated with #define MSR_IA32_APIC_BASE defined in UefiCpuPkg/Include/Register/ArchitecturalMsr.h, so we could remove it and update the modules to use MSR_IA32_APIC_BASE from ArchitecturalMsr.h. Structure MSR_IA32_APIC_BASE conflicts with #define MSR_IA32_APIC_BASE defined in UefiCpuPkg/Include/Register/ArchitecturalMsr.h, so we could remove it and update the modules to use structure MSR_IA32_APIC_BASE_REGISTER from ArchitecturalMsr.h. v5: 1. Update SourceLevelDebugPkg to use APIC Base MSR from ArchitecturalMsr.h. Cc: Michael Kinney <michael.d.kinney@intel.com> Cc: Feng Tian <feng.tian@intel.com> Cc: Giri P Mudusuru <giri.p.mudusuru@intel.com> Cc: Laszlo Ersek <lersek@redhat.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jeff Fan <jeff.fan@intel.com> Reviewed-by: Giri P Mudusuru <giri.p.mudusuru@intel.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Reviewed-by: Michael Kinney <michael.d.kinney@intel.com> Tested-by: Laszlo Ersek <lersek@redhat.com> Tested-by: Michael Kinney <michael.d.kinney@intel.com>
* Vlv2TbltDevicePkg: Add RAW file type to Rule.Common.SEC.BINARYWei, David2016-08-171-1/+5
| | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: David Wei <david.wei@intel.com> Thanks, David Wei -----Original Message----- From: Gary Lin [mailto:glin@suse.com] Sent: Thursday, August 11, 2016 4:38 PM To: edk2-devel@lists.01.org Cc: Wei, David <david.wei@intel.com> Subject: [PATCH 4/4] Vlv2TbltDevicePkg: Add RAW file type to Rule.Common.SEC.BINARY For GCC, it's using the reset vector in IntelFspWrapperPkg/FspWrapperSecCore/Vtf0/Bin/ResetVec.ia32.raw. Add the RAW file type to Rule.Common.SEC.BINARY in PlatformPkgGcc.fdf, so that GenFds can handle the raw file. Cc: David Wei <david.wei@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Gary Lin <glin@suse.com>
* Vlv2TbltDevicePkg/PlatformFspLib: Fix the include pathWei, David2016-08-171-1/+1
| | | | | | | | | | | | | | | | | | Reviewed-by: David Wei <david.wei@intel.com> Thanks, David Wei -----Original Message----- From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Gary Lin Sent: Thursday, August 11, 2016 4:38 PM To: edk2-devel@lists.01.org Cc: Wei, David <david.wei@intel.com> Subject: [edk2] [PATCH 3/4] Vlv2TbltDevicePkg/PlatformFspLib: Fix the include path Cc: David Wei <david.wei@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Gary Lin <glin@suse.com>
* Vlv2TbltDevicePkg/FspSupport: Fix GCC build errorsWei, David2016-08-173-8/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reviewed-by: David Wei <david.wei@intel.com> Thanks, David Wei -----Original Message----- From: Gary Lin [mailto:glin@suse.com] Sent: Thursday, August 11, 2016 4:38 PM To: edk2-devel@lists.01.org Cc: Wei, David <david.wei@intel.com> Subject: [PATCH 1/4] Vlv2TbltDevicePkg/FspSupport: Fix GCC build errors Fix the errors from GCC: Vlv2TbltDevicePkg/FspSupport/Library/PeiFspHobProcessLibVlv2/FspHobProcessLibVlv2.c: In function 'GetMemorySizeInMemoryTypeInformation': Vlv2TbltDevicePkg/FspSupport/Library/PeiFspHobProcessLibVlv2/FspHobProcessLibVlv2.c:59:40: error: passing argument 1 of '(*PeiServices)->GetHobList' from incompatible pointer type [-Werror=incompatible-pointer-types] Vlv2TbltDevicePkg/FspSupport/Library/PeiFspHobProcessLibVlv2/FspHobProcessLibVlv2.c:52:31: error: variable 'Status' set but not used [-Werror=unused-but-set-variable] Vlv2TbltDevicePkg/FspSupport/Library/PeiFspHobProcessLibVlv2/FspHobProcessLibVlv2.c: In function 'FspHobProcessForOtherData': Vlv2TbltDevicePkg/FspSupport/Library/PeiFspHobProcessLibVlv2/FspHobProcessLibVlv2.c:401:29: error: passing argument 1 of 'PlatformHobCreateFromFsp' from incompatible pointer type [-Werror=incompatible-pointer-types] Vlv2TbltDevicePkg/FspSupport/Library/SecFspPlatformSecLibVlv2/PlatformInit.c:18:30: fatal error: Library\DebugLib.h: No such file or directory Vlv2TbltDevicePkg/FspSupport/Library/SecFspPlatformSecLibVlv2/PlatformInit.c:19:35: fatal error: Library\SerialPortLib.h: No such file or directory Vlv2TbltDevicePkg/FspSupport/Library/SecFspPlatformSecLibVlv2/UartInit.c:18:27: fatal error: Library\IoLib.h: No such file or directory Vlv2TbltDevicePkg/FspSupport/Library/SecFspPlatformSecLibVlv2/UartInit.c:19:35: fatal error: Library\SerialPortLib.h: No such file or directory Vlv2TbltDevicePkg/FspSupport/Library/SecFspPlatformSecLibVlv2/UartInit.c: In function 'EnableInternalUart': Vlv2TbltDevicePkg/FspSupport/Library/SecFspPlatformSecLibVlv2/UartInit.c:195:20: error: pointer targets in passing argument 1 of 'SerialPortWrite' differ in signedness [-Werror=pointer-sign] Cc: David Wei <david.wei@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Gary Lin <glin@suse.com>
* UefiCpuPkg: MTRR_PHYSMASK.Valid should be one bit instead of 8 bitsRuiyu Ni2016-08-171-1/+1
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Feng Tian <feng.tian@intel.com>
* ShellPkg/Ls: Handle the case when SearchString is NULLRuiyu Ni2016-08-171-0/+5
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Hao Wu <hao.a.wu@intel.com>
* SecurityPkg: AuthVariableLib: Fix inconsistent CertDB caseZhang, Chao B2016-08-171-1/+1
| | | | | | | | | | | | | | | | | | | 2 steps are used to create/delete a time based variable. For create step 1: Insert Signer Cert to CertDB. Step 2: Insert Payload to Variable. For delete step 1: Delete Variable. Step 2: Delete Cert from CertDB. System may breaks between step 1 & step 2, so CertDB may contains useless Cert in the next reboot. AuthVariableLib choose to sync consistent state between CertDB & Time Auth Variable on initialization. However, it doesn't apply Time Auth attribute check. Now add it. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Chao Zhang <chao.b.zhang@intel.com> Reviewed-by: Fu Siyuan <siyuan.fu@intel.com> Reviewed-by: Zeng Star <star.zeng@intel.com>
* MdePkg: Fix guid conflict.Dong, Eric2016-08-162-4/+20
| | | | | | | | | Update Image Decoder Protocol GUID value to fix GUID conflict with EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL_GUID. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
* MdeModulePkg/PeiCore: Fix ConverSinglePpiPointer () typo.Marvin Haeuser2016-08-151-4/+4
| | | | | | | | | Rename ConverSinglePpiPointer () to ConvertSinglePpiPointer (). Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Marvin Haeuser <Marvin.Haeuser@outlook.com> Reviewed-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Feng Tian <feng.tian@intel.com>
* BaseTools/GenFv: Account for rebase of FV section containing VTF fileLeo Duran2016-08-141-4/+6
| | | | | | | | | | | | | | Account for rebase of FV section containing VTF file on IA32/IA64. This supports cases where the reset vector may not be set at 0xFFFFFFF0. For example, FV section defined as: [FV.FvSecPei] FvBaseAddress = $(FV_BOOT_BASE) FvForceRebase = TRUE Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Leo Duran <leo.duran@amd.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
* PcAtChipsetPkg AcpiTimerLib: Get more accurate TSC FrequencyStar Zeng2016-08-123-21/+99
| | | | | | | | | | | | | | Minimize the code overhead between the two TSC reads by adding new internal API to calculate TSC Frequency instead of reusing MicroSecondDelay (). Cc: Michael D Kinney <michael.d.kinney@intel.com> Cc: Liming Gao <liming.gao@intel.com> Cc: Paul A Lohr <paul.a.lohr@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
* MdePkg RVCT: add definition of UNREACHABLEArd Biesheuvel2016-08-121-0/+7
| | | | | | | | | | | | | The RVCT compiler in --gnu mode appears to simply strip of the __builtin prefix when it encounters calls to __builtin_xxx() functions, and so the __builtin_unreachable() we emit for GCC results in linker errors regarding undefined references against 'unreachable()'. So define UNREACHABLE() to a NOP instead. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Liming Gao <liming.gao@intel.com>
* BaseTools RVCT: ignore various RVC diagnosticsArd Biesheuvel2016-08-121-1/+1
| | | | | | | | | | | | | This updates the RVCT CC flags so various diagnostics that trigger warnings-as-errors are silenced. In particular, RVCT complains about missing newlines at the end of source files, mixing of enums and int values and return statements followed by a break, all of which occur in the Tianocore codebase, but none of which are actual errors in the code. So just silence them. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Liming Gao <liming.gao@intel.com>
* BaseTools ARM AARCH64: drop redundant compiler argumentsArd Biesheuvel2016-08-121-2/+2
| | | | | | | | | | | | The ARM and AARCH64 CC_FLAGS definitions include both GCC_ALL_CC_FLAGS and GCC44_ALL_CC_FLAGS, resulting in many of the compiler arguments being passed twice. Since the CLANG35 definitions do not refer to GCC44_ALL_CC_FLAGS, drop the reference for GCCx as well. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org> Reviewed-by: Liming Gao <liming.gao@intel.com>
* BaseTools ARM AARCH64: pass CC flags to linker for XIP modules as wellArd Biesheuvel2016-08-121-3/+3
| | | | | | | | | | | | | | | | | | | | | | Commit 478f50990a ("BaseTools GCC: add the compiler flags to the linker command line") added the compiler flags to the linker command line, which is required for LTO to function correctly, since it involves code generation at link time. This patch failed to update the build rules for XIP modules on AARCH64, which not only requires the ordinary CC flags but also the XIP CC flags to prevent the LTO backend to, e.g., emit code that does not adhere to the strict alignment rules we impose for code that may execute with the MMU off. So update the XIP link rules as well. Since AARCH64 and ARM are not supported by any toolchains in the GCCLD build rule family, drop the reference to GCCLD while we're at it. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org> Reviewed-by: Liming Gao <liming.gao@intel.com>
* MdeModulePkg/Browser: Enhance the logic when getting value from AltRespDandan Bi2016-08-121-26/+35
| | | | | | | | | | | | | | | This patch is to enhance SetupBrowser to handle following two cases: 1. When searching BlockName in AltResp, the hex digits of related BlockName in AltResp may be in uppercase. 2. When converting the Value in AltResp to HiiValue, the length of value string is bigger than the length of StorageWidth of the question. Cc: Liming Gao <liming.gao@intel.com> Cc: Eric Dong <eric.dong@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dandan Bi <dandan.bi@intel.com> Reviewed-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
* BaseTool/VfrCompile: Remove reset button opcode in CheckQuestionOpCodeDandan Bi2016-08-121-1/+0
| | | | | | | | | | | "EFI_IFR_RESET_BUTTON_OP" is a statement, not a question, so remove it from function CheckQuestionOpCode. Cc: Liming Gao <liming.gao@intel.com> Cc: Eric Dong <eric.dong@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dandan Bi <dandan.bi@intel.com> Reviewed-by: Eric Dong <eric.dong@intel.com>
* ArmPlatformPkg/ArmPlatformStackLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-48/+12
| | | | | | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. While we're at it, replace some inefficient uses of LoadConstantToReg(), and remove the workaround that was added to allow conditional branches to functions with external linkage. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPlatformPkg/ArmPlatformLibNull: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-42/+14
| | | | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. While we're at it, replace some inefficient uses of LoadConstantToReg() Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPlatformPkg/ArmVExpressPkg: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-115-111/+41
| | | | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. While we're at it, replace some inefficient uses of LoadConstantToReg() Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPlatformPkg/PrePeiCore: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-115-71/+18
| | | | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. While we're at it, replace some inefficient uses of LoadConstantToReg() Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPlatformPkg/PrePi: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-70/+29
| | | | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. While we're at it, replace some inefficient uses of LoadConstantToReg() Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPlatformPkg/ArmJunoLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-52/+21
| | | | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. While we're at it, replace some inefficient uses of LoadConstantToReg() Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* BeagleBoardPkg: add missing ArmMmuLib resolutionArd Biesheuvel2016-08-111-0/+1
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/SemihostLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-11/+4
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/CompilerIntrinsicsLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-1125-113/+56
| | | | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Note that in some cases, various entry points refer to different parts of the same routine, so in those cases, the files have been left untouched. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/BaseMemoryLibVstm: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-11/+6
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/BaseMemoryLibSm: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-9/+6
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/ArmSmcLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-10/+5
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/ArmMmuLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-111-3/+1
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/ArmLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-119-424/+205
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/ArmHvcLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-12/+7
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/ArmGicV3: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-40/+16
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/ArmCpuLib: switch to ASM_FUNC() asm macroArd Biesheuvel2016-08-112-15/+3
| | | | | | | | | Annotate functions with ASM_FUNC() so that they are emitted into separate sections. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/ArmSmcLibNull: move to generic C implementationArd Biesheuvel2016-08-114-66/+24
| | | | | | | | | | The C language is powerful enough to implement a function that does absolutely nothing, so there is no need to resort to implementations in assembler for various toolchains/architectures. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmVirtPkg: clean up assembly source filesArd Biesheuvel2016-08-119-250/+97
| | | | | | | | | | | | | | This updates all assembly source files under ArmVirtPkg to mark exported functions as ASM_FUNC(), which puts them in a separate section, allowing the linker to prune code that is left unused. At the same time, clean up the code to get rid of LoadConstantToReg() instances involving symbol references, each of which emits an absolute literal, and hence and entry in the PE/COFF .reloc table. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmVirt/PrePi: make jump to CEntryPoint relativeArd Biesheuvel2016-08-112-12/+2
| | | | | | | | | | The ArmVirtPkg platforms that use PrePi have no notion of boot remapped aliases, so we can simply jump to CEntryPoint() directly rather than via an absolute reference. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg: introduce ASM_FUNC, MOV32/MOV64 and ADRL/LDRL macrosArd Biesheuvel2016-08-112-1/+42
| | | | | | | | | | | | | | | | This introduces the ASM_FUNC() macro to annotate function entry points in assembler files. This allows us to add additional metadata that marks a function entry point as a function, and allows us to emit a .section directive for each function, which makes it possible for the linker to drop unreferenced code. In addition, introduce a couple of utility macros that we can use to clean up the code. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Eugene Cohen <eugene@hp.com> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPlatformPkg RVCT: drop dependency on GCC macro libraryArd Biesheuvel2016-08-119-66/+29
| | | | | | | | | | | The RVCT .asm files include AsmMacroIoLib.h only for the definition of LoadConstantToReg (), which makes it tedious to make change to that file without the risk of making the RVCT assembler unhappy. So simply replace LoadConstantToReg() with mov32, which does the right thing in all cases. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg/AsmMacroIoLib: remove unused obsolete MMIO and other asm macrosArd Biesheuvel2016-08-112-267/+0
| | | | | | | | | | | | | | This removes the various Mmio ASM macros that are not used anywhere in the code, and removes some variants of LoadConstant... () that are not used anywhere either. Note that these MmioXxx() implementations are unrelated to the C versions defined in MdePkg. These are strictly intended for use in assembler, and no such uses remain. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmPkg: add missing ArmMmuLib resolution to ArmPkg.dscArd Biesheuvel2016-08-111-0/+4
| | | | | | Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* ArmLib: remove ArmReplaceLiveTranslationEntry() implementationArd Biesheuvel2016-08-112-60/+4
| | | | | | | | | | | | | | | The function ArmReplaceLiveTranslationEntry() has been moved to ArmMmuLib, so remove the old implementation from ArmLib. Note that the new implementation was not exported from the object file, and so references to it were satisfied by the old version residing in ArmLib. Since we are removing that one, we need to export the new one at the same time to prevent the linker from bailing with undefined reference errors. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
* MdeModulePkg/DriverSample: Skip the character "&" before "OFFSET="Dandan Bi2016-08-111-0/+5
| | | | | | | | | | | | | When comparing the L"OFFSET=" with the ConfigResp string to find all the "OFFSET=" in ConfigResp, should skip the character "&" before "OFFSET=" in ConfigResp string. Cc: Liming Gao <liming.gao@intel.com> Cc: Eric Dong <eric.dong@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dandan Bi <dandan.bi@intel.com> Reviewed-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
* MdePkg/HiiImageEx: Fix incorrect parameter type in GetImageInfo()Dandan Bi2016-08-111-1/+1
| | | | | | | | | | | | | | In latest UEFI2.6 spec, the type of the fourth parameter in function GetImageInfo() is "EFI_IMAGE_OUTPUT", but in the header file, it is "EFI_IMAGE_INPUT". Now correct it to follow the spec. Cc: Liming Gao <liming.gao@intel.com> Cc: Eric Dong <eric.dong@intel.com> Cc: Cecil Sheng <cecil.sheng@hpe.com> Cc: Abner Chang <abner.chang@hpe.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dandan Bi <dandan.bi@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
* MdeModulePkg/Browser: Share default if some default value are not specifiedDandan Bi2016-08-112-5/+43
| | | | | | | | | | | | | | | | Add a new implementation policy of getting default value in SetupBrowser. The new policy is only for the situation that a question has default value but doesn't have default value for all supported default type. In this case, we will choose the smallest default id from the existing defaults, and share its value to other default id which has no default value. Cc: Liming Gao <liming.gao@intel.com> Cc: Eric Dong <eric.dong@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dandan Bi <dandan.bi@intel.com> Reviewed-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
* MdeModulePkg/HiiDB: Share default if some default value are not specifiedDandan Bi2016-08-112-16/+109
| | | | | | | | | | | | | | | | Add a new implementation policy of getting default value in HiiDatabase. The new policy is only for the situation that a question has default value but doesn't have default value for all supported default type. In this case, we will choose the smallest default id from the existing defaults, and share its value to other default id which has no default value. Cc: Liming Gao <liming.gao@intel.com> Cc: Eric Dong <eric.dong@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Dandan Bi <dandan.bi@intel.com> Reviewed-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
* CryptoPkg: Fix "responsiblity" typosThomas Huth2016-08-113-15/+15
| | | | | | | | | It's "responsibility", not "responsiblity". Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Qin Long <qin.long@intel.com> Reviewed-By: Wu Jiaxin <jiaxin.wu@intel.com>
* CryptoPkg: Fix capitalization of path name in Patch-HOWTO.txtThomas Huth2016-08-111-1/+1
| | | | | | | | | | | It's "OpensslLib", not "OpenSslLib" - not a big issue, but the typo is annoying when trying to copy-n-paste the path name to use it on the command line on Linux. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Qin Long <qin.long@intel.com> Reviewed-By: Wu Jiaxin <jiaxin.wu@intel.com>
* CryptoPkg IntrinsicLib: Add the missing nasm source fileLiming Gao2016-08-113-1/+100
| | | | | | | | | Add two name files IntrinsicLib Ia32 MathLShiftS64.nasm and MathRShiftU64.nasm Cc: Qin Long <qin.long@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Liming Gao <liming.gao@intel.com> Reviewed-by: Qin Long <qin.long@intel.com>
* ArmVirtPkg/PrePi: use correct callee saved regsArd Biesheuvel2016-08-102-20/+20
| | | | | | | | | | Both the ARM and the AARCH64 versions of the PrePi code (shared between ArmVirtQemuKernel and ArmVirtXen) 'preserve' values across a function call using registers that are not in fact callee saved. So fix that. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Acked-by: Laszlo Ersek <lersek@redhat.com>