From: Simon Glass Date: Wed, 29 Apr 2015 02:25:16 +0000 (-0600) Subject: x86: Provide access to the IDT X-Git-Url: http://git.dujemihanovic.xyz/?a=commitdiff_plain;h=6f41e0e7bcdc58e9e8af89988043893d5876bf7a;p=u-boot.git x86: Provide access to the IDT Add a function to return the address of the Interrupt Descriptor Table. Signed-off-by: Simon Glass Reviewed-by: Bin Meng --- diff --git a/arch/x86/cpu/interrupts.c b/arch/x86/cpu/interrupts.c index a21d2a6c50..c777d3646f 100644 --- a/arch/x86/cpu/interrupts.c +++ b/arch/x86/cpu/interrupts.c @@ -147,6 +147,11 @@ int cpu_init_interrupts(void) return 0; } +void *x86_get_idt(void) +{ + return &idt_ptr; +} + void __do_irq(int irq) { printf("Unhandled IRQ : %d\n", irq); diff --git a/arch/x86/include/asm/interrupt.h b/arch/x86/include/asm/interrupt.h index 25abde7be6..0a75f89d95 100644 --- a/arch/x86/include/asm/interrupt.h +++ b/arch/x86/include/asm/interrupt.h @@ -38,4 +38,6 @@ extern char exception_stack[]; */ void configure_irq_trigger(int int_num, bool is_level_triggered); +void *x86_get_idt(void); + #endif