From f3432c10bd694344f7e1f82ed8cd793358f1a400 Mon Sep 17 00:00:00 2001 From: Amlal El Mahrouss Date: Fri, 21 Jun 2024 05:55:02 +0200 Subject: IMP: protect other computers which doesnt support EPM layout (AMD64) IMP: Add LTE builtin and NetworkDevice of type LTE. UPDATE: Also updated ReadMe. Signed-off-by: Amlal El Mahrouss --- Boot/Sources/HEL/AMD64/BootMain.cxx | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'Boot/Sources') diff --git a/Boot/Sources/HEL/AMD64/BootMain.cxx b/Boot/Sources/HEL/AMD64/BootMain.cxx index fab212ee..145bdadb 100644 --- a/Boot/Sources/HEL/AMD64/BootMain.cxx +++ b/Boot/Sources/HEL/AMD64/BootMain.cxx @@ -77,7 +77,7 @@ STATIC Bool CheckBootDevice(BootDeviceATA& ataDev) /// @brief Main EFI entrypoint. /// @param ImageHandle Handle of this image. /// @param SystemTable The system table of it. -/// @return +/// @return nothing, never returns. EFI_EXTERN_C EFI_API Int Main(EfiHandlePtr ImageHandle, EfiSystemTable* SystemTable) { @@ -91,9 +91,19 @@ EFI_EXTERN_C EFI_API Int Main(EfiHandlePtr ImageHandle, writer.Write(L"Zeta Electronics Corporation (R) newosldr: ") .Write(BVersionString::The()); - writer.Write(L"\rnewosldr: Firmware Vendor: ") - .Write(SystemTable->FirmwareVendor) - .Write(L"\r"); + if (SystemTable->FirmwareVendor[0] != '\\' || + SystemTable->FirmwareVendor[1] != 'E' || + SystemTable->FirmwareVendor[2] != 'P' || + SystemTable->FirmwareVendor[3] != 'M') + { + writer.Write(L"\rnewosldr: vendor: ") + .Write(SystemTable->FirmwareVendor) + .Write(L" isn't supported.\r"); + + EFI::Stop(); + + CANT_REACH(); + } UInt32* MapKey = new UInt32(); UInt32* SizePtr = new UInt32(); -- cgit v1.2.3