Skip to content

Commit 1fb8a39

Browse files
author
Ian Seyler
committed
Script updates
1 parent 6abeaab commit 1fb8a39

File tree

3 files changed

+6
-9
lines changed

3 files changed

+6
-9
lines changed

build.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ mkdir -p bin
44

55
cd src
66

7-
nasm -dBIOS=1 -dNOVIDEO=1 pure64.asm -o ../bin/pure64-bios-novideo.sys -l ../bin/pure64-bios-novideo-debug.txt
8-
nasm -dBIOS=1 pure64.asm -o ../bin/pure64-bios.sys -l ../bin/pure64-bios-debug.txt
9-
nasm -dUEFI=1 pure64.asm -o ../bin/pure64-uefi.sys -l ../bin/pure64-uefi-debug.txt
7+
nasm -dBIOS -dNOVIDEO pure64.asm -o ../bin/pure64-bios-novideo.sys -l ../bin/pure64-bios-novideo-debug.txt
8+
nasm -dBIOS pure64.asm -o ../bin/pure64-bios.sys -l ../bin/pure64-bios-debug.txt
9+
nasm -dUEFI pure64.asm -o ../bin/pure64-uefi.sys -l ../bin/pure64-uefi-debug.txt
1010

1111
cd boot
1212

clean.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
#!/usr/bin/env bash
22

33
rm -f bin/*.sys
4+
rm -f bin/*.txt

src/init/timer.asm

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,6 @@ init_timer_kvm_configure:
205205
kvm_get_usec:
206206
push r10
207207
push r9
208-
push r8
209208
push rdi
210209
push rdx
211210
push rcx
@@ -228,11 +227,9 @@ kvm_get_usec_wait:
228227
mov rax, [rdi+0x08] ; 64-bit tsc_timestamp
229228
mov rbx, [rdi+0x10] ; 64-bit system_time
230229
mov ecx, [rdi+0x18] ; 32-bit tsc_to_system_mul
231-
movzx r8, byte [rdi+0x1C] ; 8-bit tsc_shift
232-
233-
; Reorg register usage
234230
push rcx ; Save tsc_to_system_mul to stack
235-
mov ecx, r8d ; Copy tsc_shift to ECX
231+
xor ecx, ecx
232+
mov cl, [rdi+0x1C] ; 8-bit tsc_shift
236233

237234
; Calculate timer delta (CPU TSC - tsc_timestamp)
238235
sub r9, rax
@@ -274,7 +271,6 @@ kvm_get_usec_shift_done:
274271
pop rcx
275272
pop rdx
276273
pop rdi
277-
pop r8
278274
pop r9
279275
pop r10
280276
ret

0 commit comments

Comments
 (0)