diff options
author | Andreas Baumann <mail@andreasbaumann.cc> | 2017-06-15 21:24:36 +0200 |
---|---|---|
committer | Andreas Baumann <mail@andreasbaumann.cc> | 2017-06-15 21:24:36 +0200 |
commit | f8dd9dd71ab603af23e008f1147f652b429c9296 (patch) | |
tree | 316bbf3585b9baeb55ca2b870e7be4724ce4936c /src/boot/stage2_check_magic.asm | |
parent | 48f0fe5954a445ba890b6a3633bbbf46cddd07c9 (diff) | |
download | abaos-f8dd9dd71ab603af23e008f1147f652b429c9296.tar.gz abaos-f8dd9dd71ab603af23e008f1147f652b429c9296.tar.bz2 |
increased size of stage 2 bootloader by 1024 bytes
Diffstat (limited to 'src/boot/stage2_check_magic.asm')
-rw-r--r-- | src/boot/stage2_check_magic.asm | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/boot/stage2_check_magic.asm b/src/boot/stage2_check_magic.asm index 1deaf05..7339a89 100644 --- a/src/boot/stage2_check_magic.asm +++ b/src/boot/stage2_check_magic.asm @@ -8,7 +8,7 @@ check_magic: push edi mov eax, NOF_LOAD_SECTORS ; number of 512-byte sectors shl eax, 9 ; 512 bytes per sector - mov edx, 0x8400 ; offset of kernel + mov edx, 0x8800 ; offset of kernel add edx, eax sub edx, MAGICLEN ; subtract the length of the magic string mov esi, edx ; now use edx as first string address to compare to @@ -20,12 +20,16 @@ check_magic: .ok: mov si, MAGIC_OK_MSG call pm_print_string + mov edx, esi + call pm_print_hex call pm_print_newline xor eax, eax jmp .end .mismatch: mov si, MAGIC_NOT_OK_MSG call pm_print_string + mov edx, esi + call pm_print_hex call pm_print_newline xor eax, eax mov eax, 1 @@ -42,7 +46,7 @@ db "ABAOS", %[MAGIC], 0 MAGICLEN equ $ - COMPARE_MAGIC MAGIC_NOT_OK_MSG: -db "Magic signature found", 0 +db "Magic signature found at ", 0 MAGIC_OK_MSG: -db "Magic signature not found!", 0 +db "Magic signature not found at ", 0 |