OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [rtems-20020807/] [c/] [src/] [lib/] [libbsp/] [m68k/] [efi332/] [include/] [bsp.h] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1026 ivang
/*  bsp.h
2
 *
3
 *  This include file contains all efi332 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
 *  bsp.h,v 1.13 2001/09/28 13:24:35 joel Exp
13
 */
14
 
15
#ifndef __EFI332_BSP_h
16
#define __EFI332_BSP_h
17
 
18
#ifdef __cplusplus
19
extern "C" {
20
#endif
21
 
22
#include <bspopts.h>
23
 
24
#include <rtems.h>
25
#include <clockdrv.h>
26
#include <console.h>
27
#include <iosupp.h>
28
#include <efi332.h>
29
#include <sim.h>
30
#include <qsm.h>
31
 
32
/*
33
 *  confdefs.h overrides for this BSP:
34
 *   - number of 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  (TBD * 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
 *  Define the interrupt mechanism for Time Test 27
54
 */
55
 
56
/* XXX - JRS - I want to compile the tmtests */
57
 
58
#define MUST_WAIT_FOR_INTERRUPT 1 
59
 
60
#define Install_tm27_vector( handler )
61
 
62
#define Cause_tm27_intr()
63
 
64
#define Clear_tm27_intr()
65
 
66
#define Lower_tm27_intr() 
67
 
68
/*
69
 *  Simple spin delay in microsecond units for device drivers.
70
 *  This is very dependent on the clock speed of the target.
71
 */
72
 
73
#define rtems_bsp_delay( microseconds ) \
74
  { register rtems_unsigned32 _delay=(microseconds); \
75
    register rtems_unsigned32 _tmp=123; \
76
    asm volatile( "0: \
77
                     nbcd      %0 ; \
78
                     nbcd      %0 ; \
79
                     dbf       %1,0b" \
80
                  : "=d" (_tmp), "=d" (_delay) \
81
                  : "0"  (_tmp), "1"  (_delay) ); \
82
  }
83
 
84
/* externals */
85
 
86
extern char _etext[];
87
extern char _copy_start[];
88
extern char _edata[];
89
extern char _clear_start[];
90
extern char end[];
91
extern char _copy_data_from_rom[];
92
 
93
/* constants */
94
 
95
#ifdef __START_C__
96
#define STACK_SIZE "#0x800"
97
#else
98
#define STACK_SIZE 0x800
99
#endif
100
 
101
/* macros */
102
 
103
#define RAW_PUTS(str) \
104
  { register char *ptr = str; \
105
    while (*ptr) outbyte(*ptr++); \
106
  }
107
 
108
#define RAW_PUTI(n) { \
109
    register int i, j; \
110
    \
111
    RAW_PUTS("0x"); \
112
    for (i=28;i>=0;i -= 4) { \
113
      j = (n>>i) & 0xf; \
114
      outbyte( (j>9 ? j-10+'a' : j+'0') ); \
115
    } \
116
  }
117
 
118
/* miscellaneous stuff assumed to exist */
119
 
120
extern rtems_configuration_table BSP_Configuration;
121
 
122
extern m68k_isr_entry M68Kvec[];   /* vector table address */
123
 
124
extern int stack_size;
125
 
126
extern int stack_start;
127
 
128
/*
129
 *  Device Driver Table Entries
130
 */
131
 
132
/*
133
 * NOTE: Use the standard Console driver entry
134
 */
135
 
136
/*
137
 * NOTE: Use the standard Clock driver entry
138
 */
139
 
140
/* functions */
141
 
142
void bsp_cleanup( void );
143
 
144
m68k_isr_entry set_vector(
145
  rtems_isr_entry     handler,
146
  rtems_vector_number vector,
147
  int                 type
148
);
149
 
150
void console_init(void);
151
 
152
void Spurious_Initialize(void);
153
 
154
void _UART_flush(void);
155
 
156
void Clock_exit(void);
157
 
158
void outbyte(char);
159
 
160
#ifdef __cplusplus
161
}
162
#endif
163
 
164
#endif
165
/* end of include file */

powered by: WebSVN 2.1.0

© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.