source: rtems/c/src/lib/libbsp/i386/shared/irq/irq.h @ c3fd48d0

5
Last change on this file since c3fd48d0 was c3fd48d0, checked in by Chris Johns <chrisj@…>, on 05/07/16 at 04:28:45

i386/pc386: Clean out removed functions.

  • Property mode set to 100644
File size: 2.7 KB
Line 
1/**
2 * @file
3 * @ingroup i386_irq
4 * @brief Interrupt handlers
5 */
6
7/* irq.h
8 *
9 *  This include file describe the data structure and the functions implemented
10 *  by rtems to write interrupt handlers.
11 *
12 *  CopyRight (C) 1998 valette@crf.canon.fr
13 *
14 *  This code is heavilly inspired by the public specification of STREAM V2
15 *  that can be found at :
16 *
17 *      <http://www.chorus.com/Documentation/index.html> by following
18 *  the STREAM API Specification Document link.
19 *
20 *  The license and distribution terms for this file may be
21 *  found in the file LICENSE in this distribution or at
22 *  http://www.rtems.org/license/LICENSE.
23 */
24
25/**
26 * @defgroup i386_irq Interrupt handlers
27 * @ingroup i386_shared
28 * @brief Data structure and the functions to write interrupt handlers
29 * @{
30 */
31
32#ifndef _IRQ_H_
33#define _IRQ_H_
34
35#ifdef __cplusplus
36extern "C" {
37#endif
38
39/** @brief
40 * Include some preprocessor value also used by assember code
41 */
42
43#include <bsp/irq_asm.h>
44#include <rtems.h>
45#define BSP_SHARED_HANDLER_SUPPORT      1
46#include <rtems/irq.h>
47#include <rtems/irq-extension.h>
48
49/*-------------------------------------------------------------------------+
50| Constants
51+--------------------------------------------------------------------------*/
52
53/** @brief Base vector for our IRQ handlers. */
54#define BSP_IRQ_VECTOR_BASE             BSP_ASM_IRQ_VECTOR_BASE
55#define BSP_IRQ_LINES_NUMBER            16
56#define BSP_IRQ_MAX_ON_i8259A           (BSP_IRQ_LINES_NUMBER - 1)
57
58/*
59 * Define the number of valid vectors. This is different to the number of IRQ
60 * signals supported. Use this value to allocation vector data or range check.
61 */
62#define BSP_IRQ_VECTOR_NUMBER        17
63#define BSP_IRQ_VECTOR_LOWEST_OFFSET 0
64#define BSP_IRQ_VECTOR_MAX_OFFSET    (BSP_IRQ_VECTOR_NUMBER - 1)
65
66/** @brief
67 * Interrupt offset in comparison to BSP_ASM_IRQ_VECTOR_BASE
68 * NB : 1) Interrupt vector number in IDT = offset + BSP_ASM_IRQ_VECTOR_BASE
69 *          2) The same name should be defined on all architecture
70 *             so that handler connection can be unchanged.
71 */
72#define BSP_PERIODIC_TIMER      0 /* fixed on all builds of PC */
73#define BSP_KEYBOARD            1 /* fixed on all builds of PC */
74#define BSP_UART_COM2_IRQ       3 /* fixed for ISA bus */
75#define BSP_UART_COM1_IRQ       4 /* fixed for ISA bus */
76#define BSP_UART_COM3_IRQ       5
77#define BSP_UART_COM4_IRQ       6
78#define BSP_RT_TIMER1           8
79#define BSP_RT_TIMER3           10
80#define BSP_SMP_IPI             16 /* not part of the ATPIC */
81
82#define BSP_INTERRUPT_VECTOR_MIN BSP_IRQ_VECTOR_LOWEST_OFFSET
83#define BSP_INTERRUPT_VECTOR_MAX BSP_IRQ_VECTOR_MAX_OFFSET
84
85/** @brief
86 * Type definition for RTEMS managed interrupts
87 */
88typedef unsigned short rtems_i8259_masks;
89
90/** @} */
91
92#ifdef __cplusplus
93}
94#endif
95
96#endif /* _IRQ_H_ */
Note: See TracBrowser for help on using the repository browser.