c wrappers for asm port operations More...
#include "stdint.h"Go to the source code of this file.
Functions | |
| static uint8_t | inb (uint16_t port) |
| read byte from low level port | |
| static void | outb (uint16_t port, uint8_t val) |
| write byte to low level port | |
| static uint16_t | inw (uint16_t port) |
| read word from low level port | |
| static void | outw (uint16_t port, uint16_t val) |
| write word to low level port | |
| static uint32_t | inl (uint16_t port) |
| read double word from low level port | |
| static void | outl (uint16_t port, uint32_t val) |
| write double word to low level port | |
| static void | io_wait (void) |
| perform a short wait (1-4 microseconds) | |
c wrappers for asm port operations
read byte from low level port
| port | port to read from |
read double word from low level port
| port | port to read from |
read word from low level port
| port | port to read from |
|
inlinestatic |
perform a short wait (1-4 microseconds)
This function outputs to a random unused port (0x80 is almost always unused after booting) Since output takes some time, this function can work as a small wait
write byte to low level port
| port | port to write to |
| val | value to write to port |
write double word to low level port
| port | port to write to |
| val | value to write to port |