10 #ifndef XTF_X86_IO_APIC_H 11 #define XTF_X86_IO_APIC_H 17 #define IOAPIC_REGSEL 0x00 18 #define IOAPIC_IOWIN 0x10 23 #define IOAPIC_VERSION 0x1 24 #define IOAPIC_MAXREDIR_MASK 0xff0000 26 #define IOAPIC_REDIR_ENTRY(e) (0x10 + (e) * 2) 27 #define IOAPIC_REDIR_MASK_SHIFT 16 29 #define IOAPIC_DEFAULT_BASE 0xfec00000 static uint64_t ioapic_read64(unsigned int reg)
Common declarations for all tests.
static uint32_t ioapic_read32(unsigned int reg)
int ioapic_set_mask(unsigned int entry, bool mask)
Set the mask bit on a redirection entry.
Primatives for number manipulation.
#define IOAPIC_DEFAULT_BASE
static void ioapic_write32(unsigned int reg, uint32_t val)
static void ioapic_write64(unsigned int reg, uint64_t val)
#define _p(v)
Express an abitrary integer v as void *.
int ioapic_init(void)
Discover and initialise the IO-APIC.