source: rtems/c/src/lib/libbsp/sh/gensh1/include/bsp.h @ 34c4852

4.104.114.84.95
Last change on this file since 34c4852 was 34c4852, checked in by Ralf Corsepius <ralf.corsepius@…>, on 05/26/05 at 05:36:48

2005-05-26 Ralf Corsepius <ralf.corsepius@…>

  • include/bsp.h: New header guard.
  • Property mode set to 100644
File size: 2.5 KB
Line 
1/*
2 *  This include file contains all board IO definitions.
3 *
4 *  generic sh1
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 *
18 *  The license and distribution terms for this file may be
19 *  found in the file LICENSE in this distribution or at
20 *  http://www.rtems.com/license/LICENSE.
21 *
22 *  $Id$
23 */
24
25#ifndef _BSP_H
26#define _BSP_H
27
28#ifdef __cplusplus
29extern "C" {
30#endif
31
32#include <rtems.h>
33#include <rtems/clockdrv.h>
34#include <rtems/console.h>
35
36#include <bspopts.h>
37
38/*
39 *  confdefs.h overrides for this BSP:
40 *   - number of termios serial ports (defaults to 1)
41 *   - Interrupt stack space is not minimum if defined.
42 */
43
44/* #define CONFIGURE_NUMBER_OF_TERMIOS_PORTS 2 */
45#define CONFIGURE_INTERRUPT_STACK_MEMORY  (4 * 1024)
46
47/* EDIT: To activate the sci driver, change the define below */
48#if 1
49#include <rtems/devnull.h>
50#define BSP_CONSOLE_DEVNAME "/dev/null"
51#define BSP_CONSOLE_DRIVER_TABLE_ENTRY DEVNULL_DRIVER_TABLE_ENTRY
52#else
53#include <sh/sci.h>
54#define BSP_CONSOLE_DEVNAME "/dev/sci0"
55#define BSP_CONSOLE_DRIVER_TABLE_ENTRY DEVSCI_DRIVER_TABLE_ENTRY
56#endif
57
58/* Constants */
59
60/*
61 *  Simple spin delay in microsecond units for device drivers.
62 *  This is very dependent on the clock speed of the target.
63 */
64
65#define rtems_bsp_delay( microseconds ) CPU_delay(microseconds)
66#define sh_delay( microseconds ) CPU_delay(microseconds)
67
68/*
69 * Defined in the linker script 'linkcmds'
70 */
71
72extern uint32_t         HeapStart ;
73extern uint32_t         HeapEnd ;
74extern uint32_t         WorkSpaceStart ;
75extern uint32_t         WorkSpaceEnd ;
76
77extern void *CPU_Interrupt_stack_low ;
78extern void *CPU_Interrupt_stack_high ;
79
80/* miscellaneous stuff assumed to exist */
81
82extern rtems_configuration_table BSP_Configuration;
83
84extern void bsp_cleanup( void );
85
86/*
87 *  Device Driver Table Entries
88 */
89
90/*
91 * We redefine CONSOLE_DRIVER_TABLE_ENTRY to redirect /dev/console
92 */
93#undef CONSOLE_DRIVER_TABLE_ENTRY
94#define CONSOLE_DRIVER_TABLE_ENTRY \
95  BSP_CONSOLE_DRIVER_TABLE_ENTRY, \
96  { console_initialize, console_open, console_close, \
97      console_read, console_write, console_control }
98
99/*
100 * NOTE: Use the standard Clock driver entry
101 */
102
103#ifdef __cplusplus
104}
105#endif
106
107#endif
108/* end of include file */
Note: See TracBrowser for help on using the repository browser.