source: rtems/c/src/lib/libbsp/m68k/csb360/include/bsp.h @ 05adba6

4.104.115
Last change on this file since 05adba6 was 05adba6, checked in by Joel Sherrill <joel.sherrill@…>, on 09/10/08 at 21:35:06

2008-09-10 Joel Sherrill <joel.sherrill@…>

  • Makefile.am, include/bsp.h: Review of all bsp_cleanup() implementations. In this phase, all prototypes were removed from bsp.h and empty implementations were removed and made to use the shared stub.
  • startup/bspclean.c: Removed.
  • Property mode set to 100644
File size: 4.6 KB
Line 
1/*
2 * Board Support Package for CSB360 evaluation board
3 * BSP definitions
4 *
5 * Copyright 2004 Cogent Computer Systems
6 * Author: Jay Monkman <jtm@lopingdog.com>
7 *
8 * Derived from mcf5206elite BSP:
9 * Copyright (C) 2000 OKTET Ltd., St.-Petersburg, Russia
10 * Author: Victor V. Vengerov <vvv@oktet.ru>
11 *
12 * The license and distribution terms for this file may be
13 * found in the file LICENSE in this distribution or at
14 *
15 * http://www.rtems.com/license/LICENSE.
16 *
17 *  bsp.h,v 1.1 2001/10/26 19:30:10 joel Exp
18 */
19
20#ifndef _BSP_H
21#define _BSP_H
22
23#include <mcf5272/mcf5272.h>
24
25
26/*** Board resources allocation ***/
27#define BSP_MEM_ADDR_SRAM 0x20000000
28#define BSP_MEM_SIZE_SRAM 4096
29
30/* Location and size of sdram. Note this includes space used by
31 * umon.
32 */
33#define BSP_MEM_ADDR_SDRAM 0x00000000
34#define BSP_MEM_MASK_SDRAM 0x01ffffff
35#define BSP_MEM_SIZE_SDRAM (32 * 1024 * 1024)
36
37/* Address to put SIM Modules */
38#define BSP_MBAR 0x10000000
39
40/* Address to put SRAM */
41#define BSP_RAMBAR BSP_MEM_ADDR_SRAM
42
43/* Interrupt Vectors */
44#define BSP_INTVEC_INT1   65
45#define BSP_INTVEC_INT2   66
46#define BSP_INTVEC_INT3   67
47#define BSP_INTVEC_INT4   68
48#define BSP_INTVEC_TMR0   69
49#define BSP_INTVEC_TMR1   70
50#define BSP_INTVEC_TMR2   71
51#define BSP_INTVEC_TMR3   72
52#define BSP_INTVEC_UART1  73
53#define BSP_INTVEC_UART2  74
54#define BSP_INTVEC_PLIP   75
55#define BSP_INTVEC_PLIA   76
56#define BSP_INTVEC_USB0   77
57#define BSP_INTVEC_USB1   78
58#define BSP_INTVEC_USB2   79
59#define BSP_INTVEC_USB3   80
60#define BSP_INTVEC_USB4   81
61#define BSP_INTVEC_USB5   82
62#define BSP_INTVEC_USB6   83
63#define BSP_INTVEC_USB7   84
64#define BSP_INTVEC_DMA    85
65#define BSP_INTVEC_ERX    86
66#define BSP_INTVEC_ETX    87
67#define BSP_INTVEC_ENTC   88
68#define BSP_INTVEC_QSPI   89
69#define BSP_INTVEC_INT5   90
70#define BSP_INTVEC_INT6   91
71#define BSP_INTVEC_SWTO   92
72
73#define BSP_INTLVL_INT1   1
74#define BSP_INTLVL_INT2   1
75#define BSP_INTLVL_INT3   1
76#define BSP_INTLVL_INT4   1
77#define BSP_INTLVL_TMR0   1
78#define BSP_INTLVL_TMR1   1
79#define BSP_INTLVL_TMR2   1
80#define BSP_INTLVL_TMR3   1
81#define BSP_INTLVL_UART1  1
82#define BSP_INTLVL_UART2  1
83#define BSP_INTLVL_PLIP   1
84#define BSP_INTLVL_PLIA   1
85#define BSP_INTLVL_USB0   1
86#define BSP_INTLVL_USB1   1
87#define BSP_INTLVL_USB2   1
88#define BSP_INTLVL_USB3   1
89#define BSP_INTLVL_USB4   1
90#define BSP_INTLVL_USB5   1
91#define BSP_INTLVL_USB6   1
92#define BSP_INTLVL_USB7   1
93#define BSP_INTLVL_DMA    1
94#define BSP_INTLVL_ERX    1
95#define BSP_INTLVL_ETX    1
96#define BSP_INTLVL_ENTC   1
97#define BSP_INTLVL_QSPI   1
98#define BSP_INTLVL_INT5   1
99#define BSP_INTLVL_INT6   1
100#define BSP_INTLVL_SWTO   1
101
102
103
104#ifndef ASM
105
106#ifdef __cplusplus
107extern "C" {
108#endif
109
110#include <bspopts.h>
111#include <rtems.h>
112#include <rtems/console.h>
113#include <rtems/iosupp.h>
114#include <rtems/clockdrv.h>
115
116struct rtems_bsdnet_ifconfig;
117extern int rtems_enet_driver_attach (struct rtems_bsdnet_ifconfig *config);
118#define RTEMS_BSP_NETWORK_DRIVER_NAME   "eth0"
119#define RTEMS_BSP_NETWORK_DRIVER_ATTACH rtems_enet_driver_attach
120
121/*
122 *  confdefs.h overrides for this BSP:
123 *   - termios serial ports (defaults to 1)
124 *   - Interrupt stack space is not minimum if defined.
125 */
126
127#define CONFIGURE_NUMBER_OF_TERMIOS_PORTS 2
128
129/* System frequency */
130#define BSP_SYSTEM_FREQUENCY (66 * 1000 * 1000)
131
132/*
133 *  Simple spin delay in microsecond units for device drivers.
134 *  This is very dependent on the clock speed of the target.
135 */
136
137#define delay( microseconds ) \
138  { register uint32_t _delay=(microseconds); \
139    register uint32_t _tmp=123; \
140    asm volatile( "0: \
141                     nbcd      %0 ; \
142                     nbcd      %0 ; \
143                     dbf       %1,0b" \
144                  : "=d" (_tmp), "=d" (_delay) \
145                  : "0"  (_tmp), "1"  (_delay) ); \
146  }
147
148/* Constants */
149
150/* Structures */
151
152/*
153 *  Device Driver Table Entries
154 */
155
156/*
157 * NOTE: Use the standard Console driver entry
158 */
159 
160/*
161 * NOTE: Use the standard Clock driver entry
162 */
163
164/*
165 * Real-Time Clock Driver Table Entry
166 * NOTE: put this entry to the device driver table AFTER I2C bus driver!
167 */
168#define RTC_DRIVER_TABLE_ENTRY \
169    { rtc_initialize, NULL, NULL, NULL, NULL, NULL }
170extern rtems_device_driver rtc_initialize(
171    rtems_device_major_number major,
172    rtems_device_minor_number minor,
173    void *arg
174);
175
176/* miscellaneous stuff assumed to exist */
177
178extern m68k_isr_entry M68Kvec[];   /* vector table address */
179
180extern rtems_isr (*rtems_clock_hook)(rtems_vector_number);
181
182/* functions */
183
184m68k_isr_entry set_vector(
185  rtems_isr_entry     handler,
186  rtems_vector_number vector,
187  int                 type
188);
189
190#ifdef __cplusplus
191}
192#endif
193
194#endif /* ASM */
195
196#endif
Note: See TracBrowser for help on using the repository browser.