summaryrefslogtreecommitdiff
path: root/cpu/io.s
diff options
context:
space:
mode:
authorAnton Kling <anton@kling.gg>2023-10-25 19:36:25 +0200
committerAnton Kling <anton@kling.gg>2023-10-30 21:49:48 +0100
commit9ea708da24784d2f4960f0353b7a08c0c2c08145 (patch)
tree9d4f3ab1fbfb864ef14cd0d45ea014de0556db72 /cpu/io.s
parent730e065e0bba1394750b3172bb7e2f1c0fd42c73 (diff)
RTL8139: Transmission and interrupts seem to magically work now.
This commit is done to preserve the functional code before I make new changes.
Diffstat (limited to 'cpu/io.s')
-rw-r--r--cpu/io.s10
1 files changed, 8 insertions, 2 deletions
diff --git a/cpu/io.s b/cpu/io.s
index 3c409de..31e9df0 100644
--- a/cpu/io.s
+++ b/cpu/io.s
@@ -4,6 +4,7 @@
.global outw
.global outl
.global inb
+.global inw
.global inl
.global rep_outsw
.global rep_insw
@@ -36,9 +37,9 @@ outb:
ret
outw:
- mov eax, [esp + 8]
+ mov ax, [esp + 8]
mov dx, [esp + 4]
- out dx, eax
+ out dx, ax
ret
inl:
@@ -46,6 +47,11 @@ inl:
in eax, dx
ret
+inw:
+ mov dx, [esp + 4]
+ in ax, dx
+ ret
+
inb:
mov dx, [esp + 4]
in al, dx