projects
/
nameless-os.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0b02cba
)
Slim down print.s
author
Duje Mihanović
<duje.mihanovic@skole.hr>
Sun, 20 Mar 2022 11:43:11 +0000
(12:43 +0100)
committer
Duje Mihanović
<duje.mihanovic@skole.hr>
Tue, 29 Mar 2022 13:12:29 +0000
(15:12 +0200)
boot/x86/print.s
patch
|
blob
|
history
diff --git
a/boot/x86/print.s
b/boot/x86/print.s
index bffa2299019d392d6be5eea70a04817c1dfe2a95..7148bc511854ed36c22dadf308a0f182fc7b3312 100644
(file)
--- a/
boot/x86/print.s
+++ b/
boot/x86/print.s
@@
-1,27
+1,21
@@
-; cs:si - pointer to ASCIIZ string
-print
+; ds:si - pointer to ASCIIZ string
+print:
+ pusha
pushf
- push ax
- push bx
- push si
+ cld
xor bh, bh
mov ah, 0Eh
-
-.loop
- mov al, [cs:si]
+.loop:
+ lodsb
cmp al, 0
je .done
int 10h
- inc si
jmp .loop
-
-.done
+.done:
mov al, 0Dh
int 10h
mov al, 0Ah
int 10h
- pop si
- pop bx
- pop ax
popf
+ popa
ret