source: rtems/c/src/lib/libbsp/powerpc/psim/irq/no_pic.c @ 393a1e05

4.104.114.95
Last change on this file since 393a1e05 was 393a1e05, checked in by Till Straumann <strauman@…>, on 11/30/07 at 21:44:17

2007-11-30 Till Straumann <strauman@…>

  • Makefile.am, irq/irq.h, irq/no_pic.c: install and use new <irq/irq_supp.h> header.
  • Property mode set to 100644
File size: 1.3 KB
Line 
1/*
2 *
3 *  This file contains the implementation of the function described in irq.h
4 *
5 *  Copyright (C) 1998, 1999 valette@crf.canon.fr
6 *
7 *  The license and distribution terms for this file may be
8 *  found in found in the file LICENSE in this distribution or at
9 *  http://www.rtems.com/license/LICENSE.
10 *
11 *  Dummy support for just the decrementer interrupt but no PIC.
12 *
13 *  T. Straumann, 2007/11/30
14 *
15 *  irq.c,v 1.4.2.8 2003/09/04 18:45:20 joel Exp
16 */
17#include <rtems.h>
18#include <bsp.h>
19#include <bsp/irq.h>
20#include <bsp/irq_supp.h>
21#include <libcpu/raw_exception.h>
22
23static rtems_irq_connect_data *rtems_hdl_tbl;
24
25/*
26 * High level IRQ handler called from shared_raw_irq_code_entry
27 */
28void C_dispatch_irq_handler (CPU_Interrupt_frame *frame, unsigned int excNum)
29{
30        register unsigned msr;
31        register unsigned new_msr;
32
33        if (excNum == ASM_DEC_VECTOR) {
34                _CPU_MSR_GET(msr);
35                new_msr = msr | MSR_EE;
36                _CPU_MSR_SET(new_msr);
37
38                rtems_hdl_tbl[BSP_DECREMENTER].hdl(rtems_hdl_tbl[BSP_DECREMENTER].handle);
39
40                _CPU_MSR_SET(msr);
41                return;
42
43        }
44}
45
46void
47BSP_enable_irq_at_pic(const rtems_irq_number irq)
48{
49}
50
51void
52BSP_disable_irq_at_pic(const rtems_irq_number irq)
53{
54}
55
56int
57BSP_setup_the_pic(rtems_irq_global_settings *config)
58{
59        rtems_hdl_tbl = config->irqHdlTbl;
60        return 1;
61}
Note: See TracBrowser for help on using the repository browser.