/* * asm/io.h * * Provides acces to x86 I/O functions */ #define inb(port) ({ \ unsigned char _val; \ __asm__ volatile ("inb %%dx, %%al" : "=a" (_val) : "d" (port)); \ _val; \ }) #define outb(port, val) \ __asm__ volatile ("outb %%al, %%dx" : : "d" (port), "a" (val));