summaryrefslogtreecommitdiffhomepage
path: root/Boot/Sources
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal.elmahrouss@icloud.com>2024-06-21 05:55:02 +0200
committerAmlal El Mahrouss <amlal.elmahrouss@icloud.com>2024-06-21 05:56:26 +0200
commitf3432c10bd694344f7e1f82ed8cd793358f1a400 (patch)
treeb2ac11c9c1378cb24e046185b6d2eeb1b0e16e98 /Boot/Sources
parent3a11be8c6f15cb03b483e2693bcd244846c6d61d (diff)
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 <amlal.elmahrouss@icloud.com>
Diffstat (limited to 'Boot/Sources')
-rw-r--r--Boot/Sources/HEL/AMD64/BootMain.cxx18
1 files changed, 14 insertions, 4 deletions
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();