summaryrefslogtreecommitdiffhomepage
path: root/dev/ZBA
diff options
context:
space:
mode:
Diffstat (limited to 'dev/ZBA')
-rw-r--r--dev/ZBA/Sources/HEL/AMD64/BootAPI.S8
-rw-r--r--dev/ZBA/Sources/HEL/AMD64/BootMain.cxx4
-rw-r--r--dev/ZBA/amd64-efi.make2
3 files changed, 7 insertions, 7 deletions
diff --git a/dev/ZBA/Sources/HEL/AMD64/BootAPI.S b/dev/ZBA/Sources/HEL/AMD64/BootAPI.S
index 380aeb94..9db0961a 100644
--- a/dev/ZBA/Sources/HEL/AMD64/BootAPI.S
+++ b/dev/ZBA/Sources/HEL/AMD64/BootAPI.S
@@ -18,15 +18,14 @@ rt_jump_to_address:
rt_reset_hardware:
/* dont raise any interrupts. (except ofc NMIs.) */
cli
+ /* remap PIC */
wait_gate1:
- /* wait for gate 1 to be ready? */
in al,0x64
and al,2
jnz wait_gate1
mov al,0x0D1
out 0x64,al
wait_gate2:
- /* wait for gate 2 to be ready? */
in al,0x64
and al,2
jnz wait_gate2
@@ -35,8 +34,9 @@ wait_gate2:
/* trigger triple fault, by writing to cr4 */
- xor rax,rax
- mov cr4,rax
+ mov rax, 0
+ lidt [rax]
+
reset_wait:
jmp reset_wait
diff --git a/dev/ZBA/Sources/HEL/AMD64/BootMain.cxx b/dev/ZBA/Sources/HEL/AMD64/BootMain.cxx
index ca2f4975..76a82a24 100644
--- a/dev/ZBA/Sources/HEL/AMD64/BootMain.cxx
+++ b/dev/ZBA/Sources/HEL/AMD64/BootMain.cxx
@@ -203,8 +203,8 @@ EFI_EXTERN_C EFI_API Int Main(EfiHandlePtr ImageHandle,
// Update handover file specific table and phyiscal start field.
//-----------------------------------------------------------//
- handoverHdrPtr->f_PhysicalStart =
- (VoidPtr)Descriptor[cDefaultMemoryMap].PhysicalStart;
+ handoverHdrPtr->f_PageStart =
+ (VoidPtr)Descriptor[cDefaultMemoryMap].VirtualStart;
handoverHdrPtr->f_FirmwareSpecific[HEL::kHandoverSpecificAttrib] =
Descriptor[cDefaultMemoryMap].Attribute;
diff --git a/dev/ZBA/amd64-efi.make b/dev/ZBA/amd64-efi.make
index d7d5132e..5d5071e0 100644
--- a/dev/ZBA/amd64-efi.make
+++ b/dev/ZBA/amd64-efi.make
@@ -36,7 +36,7 @@ EMU_FLAGS=-net none -m 8G -M q35 \
file=fat:rw:Sources/Root/,index=2,format=raw \
-drive id=disk_2,file=$(IMG_2),if=none \
-device ahci,id=ahci \
- -device ide-hd,drive=disk_2,bus=ahci.0 -no-reboot -no-shutdown -d int
+ -device ide-hd,drive=disk_2,bus=ahci.0 -d int
LD_FLAGS=-e Main --subsystem=10