source: rtems/c/src/lib/libbsp/arm/gba/irq/bsp_irq_init.c @ 128bbf9

4.104.114.84.95
Last change on this file since 128bbf9 was 128bbf9, checked in by Jay Monkman <jtm@…>, on 06/03/06 at 03:08:01

2006-06-02 Jay Monkman <jtm@…>

  • irq/bsp_irq_init.c: Changed interrupt handling to use shared rtems_irq_connect_data struct.
  • Property mode set to 100644
File size: 1.0 KB
Line 
1/**
2 *  @file bsp_irq_init.c
3 *
4 *  This file contains the implementation of rtems initialization
5 *  related to interrupt handling.
6 */
7/*
8 *  RTEMS GBA BSP
9 *
10 *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
11 *
12 *  The license and distribution terms for this file may be
13 *  found in found in the file LICENSE in this distribution or at
14 *  http://www.rtems.com/license/LICENSE.
15 *
16 *  $Id$
17 */
18
19#include <irq.h>
20#include <bsp.h>
21#include <gba_registers.h>
22
23
24/**
25 *  @brief BSP_rtems_irq_mngt_init BSP routine initialize irq registers
26 *
27 *  @param  None
28 *  @return None
29 */
30void BSP_rtems_irq_mngt_init(void)
31{
32  long *vectorTable;
33  int i;
34
35  vectorTable = (long *) VECTOR_TABLE;
36   
37  /* Initialize the vector table contents with default handler */
38  for (i=0; i<BSP_MAX_INT; i++) {
39      *(vectorTable + i) = (long)(default_int_handler);
40  }
41
42  /* clear all interrupt status flags */
43  GBA_REG_IF = 0xffff;
44  /* disable all interrupts */
45  GBA_REG_IE = 0;
46  /* set master interrupt enable */
47  GBA_REG_IME = 1;
48}
Note: See TracBrowser for help on using the repository browser.