source: rtems/c/src/lib/libbsp/m68k/gen68340/include/bsp.h @ dd406cb3

4.104.114.84.95
Last change on this file since dd406cb3 was df49c60, checked in by Joel Sherrill <joel.sherrill@…>, on 06/12/00 at 15:00:15

Merged from 4.5.0-beta3a

  • Property mode set to 100644
File size: 2.7 KB
Line 
1/*
2 * Board Support Package for `Generic' Motorola MC68340
3 *
4 * Based on the `gen68360' board support package, and covered by the
5 * original distribution terms.
6 *
7 *  $Id$
8 */
9
10/*  bsp.h
11 *
12 *  COPYRIGHT (c) 1989-1999.
13 *  On-Line Applications Research Corporation (OAR).
14 *
15 *  The license and distribution terms for this file may be
16 *  found in the file LICENSE in this distribution or at
17 *  http://www.OARcorp.com/rtems/license.html.
18 */
19
20#ifndef __GEN68340_BSP_h
21#define __GEN68340_BSP_h
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
27#include <rtems.h>
28#include <console.h>
29#include <iosupp.h>
30#include <clockdrv.h>
31
32/*
33 *  confdefs.h overrides for this BSP:
34 *   - termios serial ports (defaults to 1)
35 *   - Interrupt stack space is not minimum if defined.
36 */
37
38/* #define CONFIGURE_NUMBER_OF_TERMIOS_PORTS 2 */
39#define CONFIGURE_INTERRUPT_STACK_MEMORY  (4 * 1024)
40 
41/*
42 *  Define the time limits for RTEMS Test Suite test durations.
43 *  Long test and short test duration limits are provided.  These
44 *  values are in seconds and need to be converted to ticks for the
45 *  application.
46 *
47 */
48
49#define MAX_LONG_TEST_DURATION       300 /* 5 minutes = 300 seconds */
50#define MAX_SHORT_TEST_DURATION      3   /* 3 seconds */
51
52/*
53 *  Stuff for Time Test 27
54 *  Don't bother with hardware -- just use a software-interrupt
55 */
56
57#define MUST_WAIT_FOR_INTERRUPT 0
58
59#define Install_tm27_vector( handler ) set_vector( (handler), 34, 1 )
60
61#define Cause_tm27_intr()       /* asm volatile ("trap #2"); */
62
63#define Clear_tm27_intr()
64
65#define Lower_tm27_intr()
66
67/*
68 *  Simple spin delay in microsecond units for device drivers.
69 *  This is very dependent on the clock speed of the target.
70 */
71
72#define delay( microseconds ) \
73  { register rtems_unsigned32 _delay=(microseconds); \
74    register rtems_unsigned32 _tmp=123; \
75    asm volatile( "0: \
76                     nbcd      %0 ; \
77                     nbcd      %0 ; \
78                     dbf       %1,0b" \
79                  : "=d" (_tmp), "=d" (_delay) \
80                  : "0"  (_tmp), "1"  (_delay) ); \
81  }
82
83/* Constants */
84
85/* Structures */
86
87/*
88 *  Device Driver Table Entries
89 */
90
91/*
92 * NOTE: Use the standard Console driver entry
93 */
94 
95/*
96 * NOTE: Use the standard Clock driver entry
97 */
98
99/*
100 * How many libio files we want
101 */
102
103#define BSP_LIBIO_MAX_FDS       20
104
105/* miscellaneous stuff assumed to exist */
106
107extern rtems_configuration_table BSP_Configuration;
108
109extern m68k_isr_entry M68Kvec[];   /* vector table address */
110
111/* functions */
112
113void bsp_cleanup( void );
114
115m68k_isr_entry set_vector(
116  rtems_isr_entry     handler,
117  rtems_vector_number vector,
118  int                 type
119);
120
121/*
122 * Values assigned by link editor
123 */
124extern void *_RomBase, *_RamBase;
125
126#ifdef __cplusplus
127}
128#endif
129
130#endif
131/* end of include file */
Note: See TracBrowser for help on using the repository browser.