The PcdPrePiProduceMemoryTypeInformationHob on ARM breaks Linux efistub
boot. The efistub for arm32 uncompresses Linux kernel into memory ranges
which occupied by DXE-phase drivers which leads to
'permission denied'-error during page write. So as a temporary solution
we use PcdPrePiProduceMemoryTypeInformationHob only for AARCH64
Signed-off-by: Savva Mitrofanov <savvamtr@gmail.com>
This change removes Xcode5ExceptionHandlerAsm and merge it's
functionality into ExceptionHandlerAsm.
Also decreases number of vectors to 32 for:
- 64-bit PeiCpuExceptionHandlerLib
- 32-bit PeiCpuExceptionHandlerLib, SecPeiCpuExceptionHandlerLib
Signed-off-by: Savva Mitrofanov <savvamtr@gmail.com>
BaseTools has been duplicating and adapting code that is defined in
MdePkg and MdeModulePkg. This leads to desync issues where the same
symbols may be backed by different functions with slightly different
semantics and also fixes that apply only to BaseTools or only to MdePkg
and MdeModulePkg.
To address these issues, update BaseTools/Source/C to utilize the code
from MdePkg and MdeModulePkg.
Signed-off-by: Marvin Häuser <mhaeuser@posteo.de>
BaseTools has been duplicating and adapting code that is defined in
MdePkg and MdeModulePkg. This leads to desync issues where the same
symbols may be backed by different functions with slightly different
semantics and also fixes that apply only to BaseTools or only to MdePkg
and MdeModulePkg.
To address these issues, update BaseTools/Source/C to utilize the code
from MdePkg and MdeModulePkg.
Signed-off-by: Marvin Häuser <mhaeuser@posteo.de>
MtrrLib does not include PcdLib.h despite explicitly using its
definitions. Add the include to fix compilation for modules that do not
utilize AutoGen.
Signed-off-by: Marvin Häuser <mhaeuser@posteo.de>
In preparation of including Base.h in C++ BaseTools programs, support
the C++ 11 alignof operator. The C _Alignof operator is not universally
supported in C++ mode across compiler toolchains and thus the current
definition may lead to compilation errors with said programs.
Signed-off-by: Marvin Häuser <mhaeuser@posteo.de>
To support GoogleTest, 933b4c3 added support for C++ static_assert.
However, this is not a mandatory or universally supported C++ feature.
Guard its usage by the __cpp_static_assert support flag.
Signed-off-by: Marvin Häuser <mhaeuser@posteo.de>
Implements gEfiFatPkgTokenSpaceGuid token space and adds token which
disables write operations. By default driver still supports read-write
mode
Signed-off-by: Savva Mitrofanov <savvamtr@gmail.com>
For the bitfield access, MSVC apparently uses a right shift of the base type of the bitfield member. In our case, is is cased by IA32_PTE_4K and
IA32_PAGE_LEAF_ENTRY_BIG_PAGESIZE and other structures which uses uint64
bitfields and 32-bit x86 doesn't have a 64-bit integer shift (except using MMX or SSE2). With -Od (NOOPT) even for constant counts it puts
the data in EDX:EAX, the shift count in cl and calls __aullshr.
Signed-off-by: Savva Mitrofanov <savvamtr@gmail.com>
The ashrdi3 function should do arithmetic shift instead of logic using
sar instruction. Also adds __lshrdi3 implementation to correct build
using LLVM
Signed-off-by: Savva Mitrofanov <savvamtr@gmail.com>
Silences "sometimes-uninitialized" warning by initializing the variable FspMultiPhaseApiOffset and corrects build using LLVM 15 toolchain
Signed-off-by: Savva Mitrofanov <savvamtr@gmail.com>
Update the brotli submodule to the latest commit (ed1995b6bda1)
so that the build isn't broken in GCC 12 compilers.
Signed-off-by: Savva Mitrofanov <savvamtr@gmail.com>