summaryrefslogtreecommitdiff
path: root/bsps/sparc/shared/irq/bsp_isr_handler.c
blob: 1541aa236f1a4bb1a88cf43c2de63cf9d5891c96 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/*
*  COPYRIGHT (c) 2015
*  Cobham Gaisler
*
*  The license and distribution terms for this file may be
*  found in the file LICENSE in this distribution or at
*  http://www.rtems.org/license/LICENSE.
*
*/

#include <bsp.h>
#include <bsp/irq-generic.h>

#ifdef LEON3
#include <bsp/leon3.h>
#endif

/*
 * This function is called directly from _SPARC_Interrupt_trap() for
 * traps 0x10 to 0x1F which correspond to IRQ 0 to 15 respectively.
 */
void _SPARC_Interrupt_dispatch( uint32_t irq )
{
  bsp_interrupt_assert( irq < BSP_INTERRUPT_VECTOR_COUNT );

  /* Let BSP fixup and/or handle incoming IRQ */
  irq = bsp_irq_fixup( irq );

  bsp_interrupt_handler_dispatch_unchecked( irq );
}