source: rtems/c/src/lib/libbsp/sh/gensh2/include/bsp.h @ f86582c8

4.104.114.84.95
Last change on this file since f86582c8 was 5dbd4fe, checked in by Joel Sherrill <joel.sherrill@…>, on 05/11/01 at 16:51:06

2001-05-10 Ralf Corsepius <corsepiu@…>

  • configure.in: Use RTEMS_PROG_CC_FOR_TARGET([-ansi -fasm]), add bspopts.h.
  • include/.cvsignore: Add stamp-h*, bspopts.h*.
  • include/Makefile.am: Use include_HEADERS instead of H_FILES.
  • include/bsp.h: Add bspopts.h.
  • startup/bspstart.c: Replace HZ w/ CPU_CLOCK_RATE_HZ.
  • Property mode set to 100644
File size: 3.5 KB
Line 
1/*
2 *  This include file contains all board IO definitions.
3 *
4 *  generic sh2
5 *
6 *  Author: Ralf Corsepius (corsepiu@faw.uni-ulm.de)
7 *
8 *  COPYRIGHT (c) 1997-1998, FAW Ulm, Germany
9 *
10 *  This program is distributed in the hope that it will be useful,
11 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
12 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
13 *
14 *
15 *  COPYRIGHT (c) 1998.
16 *  On-Line Applications Research Corporation (OAR).
17 *  Copyright assigned to U.S. Government, 1994.
18 *
19 *  The license and distribution terms for this file may be
20 *  found in the file LICENSE in this distribution or at
21 *  http://www.OARcorp.com/rtems/license.html.
22 *
23 *  Minor adaptations for sh2 by:
24 *  John M. Mills (jmills@tga.com)
25 *  TGA Technologies, Inc.
26 *  100 Pinnacle Way, Suite 140
27 *  Norcross, GA 30071 U.S.A.
28 *
29 *  This modified file may be copied and distributed in accordance
30 *  the above-referenced license. It is provided for critique and
31 *  developmental purposes without any warranty nor representation
32 *  by the authors or by TGA Technologies.
33 *
34 *  $Id$
35 */
36
37#ifndef __gensh2_h
38#define __gensh2_h
39
40#ifdef __cplusplus
41extern "C" {
42#endif
43
44#include <rtems.h>
45#include <clockdrv.h>
46#include <console.h>
47
48#include <bspopts.h>
49
50/*
51 *  confdefs.h overrides for this BSP:
52 *   - number of termios serial ports (defaults to 1)
53 *   - Interrupt stack space is not minimum if defined.
54 */
55
56/* #define CONFIGURE_NUMBER_OF_TERMIOS_PORTS 2 */
57#define CONFIGURE_INTERRUPT_STACK_MEMORY  (4 * 1024)
58
59#if 0
60#include <rtems/devnull.h>
61#define BSP_CONSOLE_DEVNAME "/dev/null"
62#define BSP_CONSOLE_DRIVER_TABLE_ENTRY DEVNULL_DRIVER_TABLE_ENTRY
63#else
64#include <sh/sci.h>
65#define BSP_CONSOLE_DEVNAME "/dev/sci0"
66#define BSP_CONSOLE_DRIVER_TABLE_ENTRY DEVSCI_DRIVER_TABLE_ENTRY
67#endif
68
69/*
70 *  Define the time limits for RTEMS Test Suite test durations.
71 *  Long test and short test duration limits are provided.  These
72 *  values are in seconds and need to be converted to ticks for the
73 *  application.
74 *
75 */
76
77#define MAX_LONG_TEST_DURATION       300 /* 5 minutes = 300 seconds */
78#define MAX_SHORT_TEST_DURATION      3   /* 3 seconds */
79
80/*
81 *  Stuff for Time Test 27
82 */
83
84#define MUST_WAIT_FOR_INTERRUPT 0
85
86#define Install_tm27_vector( handler ) \
87{ \
88  rtems_isr_entry ignored ; \
89  rtems_interrupt_catch( (handler), 0, &ignored ) ; \
90}
91
92#define Cause_tm27_intr()
93
94#define Clear_tm27_intr()
95
96#define Lower_tm27_intr()
97
98/* Constants */
99
100/*
101 *  Simple spin delay in microsecond units for device drivers.
102 *  This is very dependent on the clock speed of the target.
103 */
104
105#define delay( microseconds ) CPU_delay(microseconds)
106#define sh_delay( microseconds ) CPU_delay( microseconds )
107
108
109/*
110 * Defined in the linker script 'linkcmds'
111 */
112
113extern unsigned32       HeapStart ;
114extern unsigned32       HeapEnd ;
115extern unsigned32       WorkSpaceStart ;
116extern unsigned32       WorkSpaceEnd ;
117
118extern void *CPU_Interrupt_stack_low ;
119extern void *CPU_Interrupt_stack_high ;
120
121 
122/* miscellaneous stuff assumed to exist */
123
124extern rtems_configuration_table BSP_Configuration;
125
126extern void bsp_cleanup( void );
127
128/*
129 *  Device Driver Table Entries
130 */
131
132/*
133 * We redefine CONSOLE_DRIVER_TABLE_ENTRY to redirect /dev/console
134 */
135#undef CONSOLE_DRIVER_TABLE_ENTRY
136#define CONSOLE_DRIVER_TABLE_ENTRY \
137  BSP_CONSOLE_DRIVER_TABLE_ENTRY, \
138  { console_initialize, console_open, console_close, \
139      console_read, console_write, console_control }
140 
141/*
142 * NOTE: Use the standard Clock driver entry
143 */
144
145#ifdef __cplusplus
146}
147#endif
148
149#endif
150/* end of include file */
Note: See TracBrowser for help on using the repository browser.