source: rtems/c/src/lib/libbsp/sh/gensh1/include/bsp.h @ 5830f5a

4.115
Last change on this file since 5830f5a was c499856, checked in by Chris Johns <chrisj@…>, on 03/20/14 at 21:10:47

Change all references of rtems.com to rtems.org.

  • Property mode set to 100644
File size: 2.0 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.org/license/LICENSE.
21 */
22
23#ifndef _BSP_H
24#define _BSP_H
25
26#ifdef __cplusplus
27extern "C" {
28#endif
29
30#include <rtems.h>
31#include <rtems/clockdrv.h>
32#include <rtems/console.h>
33
34#include <bspopts.h>
35#include <bsp/default-initial-extension.h>
36
37#define BSP_SMALL_MEMORY 1
38
39/* EDIT: To activate the sci driver, change the define below */
40#if 1
41#include <rtems/devnull.h>
42#define BSP_CONSOLE_DEVNAME "/dev/null"
43#define BSP_CONSOLE_DRIVER_TABLE_ENTRY DEVNULL_DRIVER_TABLE_ENTRY
44#else
45#include <sh/sci.h>
46#define BSP_CONSOLE_DEVNAME "/dev/sci0"
47#define BSP_CONSOLE_DRIVER_TABLE_ENTRY DEVSCI_DRIVER_TABLE_ENTRY
48#endif
49
50/* Constants */
51
52/*
53 *  Simple spin delay in microsecond units for device drivers.
54 *  This is very dependent on the clock speed of the target.
55 */
56
57#define rtems_bsp_delay( microseconds ) CPU_delay(microseconds)
58#define sh_delay( microseconds ) CPU_delay(microseconds)
59
60/*
61 * Defined in the linker script 'linkcmds'
62 */
63
64extern void *CPU_Interrupt_stack_low ;
65extern void *CPU_Interrupt_stack_high ;
66
67/*
68 *  Device Driver Table Entries
69 */
70
71/*
72 * We redefine CONSOLE_DRIVER_TABLE_ENTRY to redirect /dev/console
73 */
74#undef CONSOLE_DRIVER_TABLE_ENTRY
75#define CONSOLE_DRIVER_TABLE_ENTRY \
76  BSP_CONSOLE_DRIVER_TABLE_ENTRY, \
77  { console_initialize, console_open, console_close, \
78      console_read, console_write, console_control }
79
80/*
81 * NOTE: Use the standard Clock driver entry
82 */
83
84#ifdef __cplusplus
85}
86#endif
87
88#endif
Note: See TracBrowser for help on using the repository browser.