Skip to content

MinPlatform

Building edk2-MinPlatform on Linux

The EDK2-MinPlatform instructions are only for Windows. If you want to build on Linux, you have to patch the trees a little bit. Actually getting MtOlympus OCP hardware to test on doesn't seem to be possible so it isn't clear what you would actually do with this firmware once it is built.

git clone https://github.com/tianocore/edk2.git
git clone https://github.com/tianocore/edk2-platforms.git -b devel-MinPlatform
git clone https://github.com/tianocore/edk2-non-osi.git -b devel-MinPlatform
git clone https://github.com/IntelFsp/FSP.git -b KabylakeFsp0001
( cd edk2 ; curl https://trmm.net/tmp/edk2.patch | patch -p1  )
( cd edk2-non-osi ; curl https://trmm.net/edk2-non-osi.patch | patch -p1 )
( cd edk2-platforms ; curl https://trmm.net/edk2-platforms.patch | patch -p1 )
make -C edk2/BaseTools
cd edk2-platforms/Platform/Intel/PurleyOpenBoardPkg/BoardMtOlympus
. ./setup.sh
mv target.txt ../../../../../Conf/
build 2>&1 | tee make.log

Output is in Build/PurleyOpenBoardPkg/BoardMtOlympus/DEBUG_GCC5/FV/PLATFORM.fd Since it isn't signed, you'll have to install it via chipclip and hardware SPI flash programmer.

Intel says that the fault in SecCore is likely due to a missing post-build step:

Then I think no prebuild and postbuild is the cause of the problem.

1) In prebuild we need regenerate AML offset table build %PRE_BUILD_CMD_LINE% -m %BOARD_PKG%\Acpi\BoardAcpiDxe\Dsdt.inf -y %PRE_BUILD_REPORT% --log=%PRE_BUILD_LOG%

set AML_FILTER="\"PSYS\" .MCTL\" .FIX0-9,A-Z\"" echo AML_FILTER=%AML_FILTER% %WORKSPACE%\edk2-platforms\Platform\Intel\MinPlatformPkg\Tools\AmlGenOffset\AmlGenOffset.py -d --aml_filter %AML_FILTER% -o %WORKSPACE%\edk2-platforms\Platform\Intel\%BOARD_PKG%\Acpi\BoardAcpiDxe\AmlOffsetTable.c %OUTPUT_DIR%\X64\PurleyOpenBoardPkg\Acpi\BoardAcpiDxe\DSDT\OUTPUT\Dsdt\WFPPlatform.offset.h

Without this step, you may get ASSERT in DXE ACPI DSDT table driver.

2) In postbuild we need PatchBinFv, RebaseBinFv, and PatchBfv.

Assuming you did not change PCD configuration, then you just need run PatchBfv.

call python %WORKSPACE%\edk2-platforms\Platform\Intel\MinPlatformPkg\Tools\PatchFv\PatchBfv.py %WORKSPACE%\Build\%BOARD_PKG%\%BOARD_NAME%\%TARGET%_%TOOL_CHAIN_TAG%\FV\PLATFORM.fd %WORKSPACE%\Build\BuildReport.txt gMinPlatformPkgTokenSpaceGuid.PcdFlashFvPreMemoryBase

Without this step, you may get ASSERT in SECCORE

2018 Heads


Last update: November 8, 2020