summaryrefslogtreecommitdiffhomepage
path: root/dev/ZBAKit/src
diff options
context:
space:
mode:
Diffstat (limited to 'dev/ZBAKit/src')
-rw-r--r--dev/ZBAKit/src/HEL/ARM64/BootAPI.S12
-rw-r--r--dev/ZBAKit/src/HEL/ARM64/BootMain.cc14
2 files changed, 19 insertions, 7 deletions
diff --git a/dev/ZBAKit/src/HEL/ARM64/BootAPI.S b/dev/ZBAKit/src/HEL/ARM64/BootAPI.S
new file mode 100644
index 00000000..9a53dfc9
--- /dev/null
+++ b/dev/ZBAKit/src/HEL/ARM64/BootAPI.S
@@ -0,0 +1,12 @@
+.global rt_jump_to_address
+
+.text
+
+/**
+ @brief this function setups a stack and then jumps to
+ a function */
+rt_jump_to_address:
+ mov x19, x0
+ mov sp, x2
+ br x19
+
diff --git a/dev/ZBAKit/src/HEL/ARM64/BootMain.cc b/dev/ZBAKit/src/HEL/ARM64/BootMain.cc
index 1d3d9150..99e321ee 100644
--- a/dev/ZBAKit/src/HEL/ARM64/BootMain.cc
+++ b/dev/ZBAKit/src/HEL/ARM64/BootMain.cc
@@ -9,12 +9,12 @@
#include <BootKit/Thread.h>
#include <BootKit/BootKit.h>
-#ifndef cExpectedWidth
-#define cExpectedWidth 844
+#ifndef kExpectedWidth
+#define kExpectedWidth 844
#endif
-#ifndef cExpectedHeight
-#define cExpectedHeight 390
+#ifndef kExpectedHeight
+#define kExpectedHeight 390
#endif
EXTERN EfiBootServices* BS;
@@ -52,8 +52,8 @@ EFI_EXTERN_C EFI_API Int32 Main(EfiHandlePtr ImageHandle,
writer.Write(infoPtr->VerticalResolution);
writer.Write("\r");
- if (infoPtr->HorizontalResolution == cExpectedWidth &&
- infoPtr->VerticalResolution == cExpectedHeight)
+ if (infoPtr->HorizontalResolution == kExpectedWidth &&
+ infoPtr->VerticalResolution == kExpectedHeight)
{
kGop->SetMode(kGop, i);
break;
@@ -69,7 +69,7 @@ EFI_EXTERN_C EFI_API Int32 Main(EfiHandlePtr ImageHandle,
auto kernel_thread = Boot::BThread(reader_kernel.Blob());
if (kernel_thread.IsValid())
- kernel_thread.Start(nullptr);
+ kernel_thread.Start(nullptr, YES);
}
CANT_REACH();