! This is standard Minix 2.0.x's ACK-cc style assembly ! Rewrote from osdep_inout.s (GNU style) ! GNU style: mov[b|w|l] %srcreg, %destreg ! Intel style: mov destreg, srcreg ! ATTENTION: src/dest is reversed, no % for registers .sect .text .define _PortInb .define _PortOutb .define _PortOutw ! ! unsigned char _PortInb(unsigned int port); ! .align 4 _PortInb: mov edx, 4(esp) sub eax, eax inb dx ret ! .type _PortInb,@function ! .size _PortInb,.-_PortInb ! ! void _PortOutb(unsigned char value, unsigned int port); ! .align 4 _PortOutb: mov eax, 4(esp) mov edx, 8(esp) outb dx ret ! .type _PortOutb,@function ! .size _PortOutb,.-_PortOutb ! ! void _PortOutw(unsigned short value, unsigned int port); ! .align 4 _PortOutw: mov eax, 4(esp) mov edx, 8(esp) out dx ret ! .type _PortOutw,@function ! .size _PortOutw,.-_PortOutw