diff options
author | Tom Rini <trini@konsulko.com> | 2018-12-10 07:14:48 -0500 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2018-12-10 07:14:48 -0500 |
commit | 53287a89e90a842f7265446be89c3c6b2aff3271 (patch) | |
tree | 989dcec887c151bb2c8796f8177f3df80c5592ce /arch/x86/lib/interrupts.c | |
parent | cde578ff36b15ec9c2033f03b94ecf809af7cc64 (diff) | |
parent | d3d6531866f2d7aa85b053cef553090b251e909f (diff) |
Merge git://git.denx.de/u-boot-x86
- Enable RTC for Intel Tangier
- Wrap the call to 8259 PIC with Kconfig options for old targets without
8259
- Warp the call to USB init with Kconfg options for coreboot & EFI
payload
Diffstat (limited to 'arch/x86/lib/interrupts.c')
-rw-r--r-- | arch/x86/lib/interrupts.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/arch/x86/lib/interrupts.c b/arch/x86/lib/interrupts.c index 297067df710..39f8deaed13 100644 --- a/arch/x86/lib/interrupts.c +++ b/arch/x86/lib/interrupts.c @@ -64,7 +64,8 @@ void irq_install_handler(int irq, interrupt_handler_t *handler, void *arg) irq_handlers[irq].arg = arg; irq_handlers[irq].count = 0; - unmask_irq(irq); + if (CONFIG_IS_ENABLED(I8259_PIC)) + unmask_irq(irq); if (status) enable_interrupts(); @@ -83,7 +84,8 @@ void irq_free_handler(int irq) status = disable_interrupts(); - mask_irq(irq); + if (CONFIG_IS_ENABLED(I8259_PIC)) + mask_irq(irq); irq_handlers[irq].handler = NULL; irq_handlers[irq].arg = NULL; @@ -104,14 +106,16 @@ void do_irq(int hw_irq) } if (irq_handlers[irq].handler) { - mask_irq(irq); + if (CONFIG_IS_ENABLED(I8259_PIC)) + mask_irq(irq); irq_handlers[irq].handler(irq_handlers[irq].arg); irq_handlers[irq].count++; - unmask_irq(irq); - specific_eoi(irq); - + if (CONFIG_IS_ENABLED(I8259_PIC)) { + unmask_irq(irq); + specific_eoi(irq); + } } else { if ((irq & 7) != 7) { spurious_irq_cnt++; |