source: rtems/c/src/lib/libbsp/m68k/efi68k/include/bsp.h @ 9b2c969

4.104.114.84.95
Last change on this file since 9b2c969 was 9b2c969, checked in by Joel Sherrill <joel.sherrill@…>, on 01/13/00 at 15:07:03

Made sweep of changes to get all BSPs to the same point on the linkcmds
and memory layout. Next step is to share the same bsp_pretasking_hook.

  • Property mode set to 100644
File size: 3.1 KB
Line 
1/*  bsp.h
2 *
3 *  This include file contains all efi68k board IO definitions.
4 *
5 *  COPYRIGHT (c) 1989-1999.
6 *  On-Line Applications Research Corporation (OAR).
7 *
8 *  The license and distribution terms for this file may be
9 *  found in the file LICENSE in this distribution or at
10 *  http://www.OARcorp.com/rtems/license.html.
11 *
12 *  $Id$
13 */
14
15#ifndef __EFI68K_BSP_h
16#define __EFI68K_BSP_h
17
18#ifdef __cplusplus
19extern "C" {
20#endif
21
22#include <rtems.h>
23#include <clockdrv.h>
24#include <console.h>
25#include <iosupp.h>
26#include <efi68k.h>
27#include <DP8570A.h>
28#include <16550.h>
29
30/*
31 *  Define the time limits for RTEMS Test Suite test durations.
32 *  Long test and short test duration limits are provided.  These
33 *  values are in seconds and need to be converted to ticks for the
34 *  application.
35 *
36 */
37
38#define MAX_LONG_TEST_DURATION       300 /* 5 minutes = 300 seconds */
39#define MAX_SHORT_TEST_DURATION      3   /* 3 seconds */
40
41/*
42 *  Define the interrupt mechanism for Time Test 27
43 */
44
45/* XXX - JRS - I want to compile the tmtests */
46
47#define MUST_WAIT_FOR_INTERRUPT 1
48
49#define Install_tm27_vector( handler )
50
51#define Cause_tm27_intr()
52
53#define Clear_tm27_intr()
54
55#define Lower_tm27_intr()
56
57/*
58 *  Simple spin delay in microsecond units for device drivers.
59 *  This is very dependent on the clock speed of the target.
60 */
61
62#define delay( microseconds ) \
63  { register rtems_unsigned32 _delay=(microseconds); \
64    register rtems_unsigned32 _tmp=123; \
65    asm volatile( "0: \
66                     nbcd      %0 ; \
67                     nbcd      %0 ; \
68                     dbf       %1,0b" \
69                  : "=d" (_tmp), "=d" (_delay) \
70                  : "0"  (_tmp), "1"  (_delay) ); \
71  }
72
73/* externals */
74
75extern char _etext[];
76extern char _copy_start[];
77extern char _edata[];
78extern char _clear_start[];
79extern char end[];
80extern char _copy_data_from_rom[];
81extern char __end_of_ram[];
82
83/* constants */
84
85#define RAM_END ((int)__end_of_ram)
86
87#ifdef __START_C__
88#define STACK_SIZE "#0x800"
89#else
90#define STACK_SIZE 0x800
91#endif
92
93/* macros */
94
95#define RAW_PUTS(str) \
96  { register char *ptr = str; \
97    while (*ptr) outbyte(*ptr++); \
98  }
99
100#define RAW_PUTI(n) { \
101    register int i, j; \
102    \
103    RAW_PUTS("0x"); \
104    for (i=28;i>=0;i -= 4) { \
105      j = (n>>i) & 0xf; \
106      outbyte( (j>9 ? j-10+'a' : j+'0') ); \
107    } \
108  }
109
110/* miscellaneous stuff assumed to exist */
111
112extern rtems_configuration_table BSP_Configuration;
113
114extern m68k_isr_entry M68Kvec[];   /* vector table address */
115
116extern int stack_size;
117
118extern int stack_start;
119
120extern rtems_unsigned32 Timer_interrupts;
121
122/*
123 *  Device Driver Table Entries
124 */
125 
126/*
127 * NOTE: Use the standard Console driver entry
128 */
129 
130/*
131 * NOTE: Use the standard Clock driver entry
132 */
133 
134/* functions */
135
136void bsp_cleanup( void );
137
138m68k_isr_entry set_vector(
139  rtems_isr_entry     handler,
140  rtems_vector_number vector,
141  int                 type
142);
143
144void console_init(void);
145
146void watch_dog_init(void);
147
148void tcp_init(void);
149
150void Spurious_Initialize(void);
151
152void _UART_flush(void);
153
154void Clock_exit(void);
155
156void outbyte(char);
157
158#ifdef __cplusplus
159}
160#endif
161
162#endif
163/* end of include file */
Note: See TracBrowser for help on using the repository browser.