1 | /* bsp.h |
---|
2 | * |
---|
3 | * This include file contains all SPARC simulator definitions. |
---|
4 | * |
---|
5 | * COPYRIGHT (c) 1989-1998. |
---|
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.rtems.com/license/LICENSE. |
---|
11 | * |
---|
12 | * Ported to ERC32 implementation of the SPARC by On-Line Applications |
---|
13 | * Research Corporation (OAR) under contract to the European Space |
---|
14 | * Agency (ESA). |
---|
15 | * |
---|
16 | * ERC32 modifications of respective RTEMS file: COPYRIGHT (c) 1995. |
---|
17 | * European Space Agency. |
---|
18 | * |
---|
19 | * $Id$ |
---|
20 | */ |
---|
21 | |
---|
22 | #ifndef _BSP_H |
---|
23 | #define _BSP_H |
---|
24 | |
---|
25 | #ifdef __cplusplus |
---|
26 | extern "C" { |
---|
27 | #endif |
---|
28 | |
---|
29 | #include <bspopts.h> |
---|
30 | |
---|
31 | #include <rtems.h> |
---|
32 | #include <leon.h> |
---|
33 | #include <rtems/clockdrv.h> |
---|
34 | #include <rtems/console.h> |
---|
35 | |
---|
36 | /* SPARC CPU variant: LEON2 */ |
---|
37 | #define LEON2 1 |
---|
38 | |
---|
39 | /* |
---|
40 | * BSP provides its own Idle thread body |
---|
41 | */ |
---|
42 | void *bsp_idle_thread( uintptr_t ignored ); |
---|
43 | #define BSP_IDLE_TASK_BODY bsp_idle_thread |
---|
44 | |
---|
45 | /* |
---|
46 | * Network driver configuration |
---|
47 | */ |
---|
48 | struct rtems_bsdnet_ifconfig; |
---|
49 | extern int rtems_leon_open_eth_driver_attach( |
---|
50 | struct rtems_bsdnet_ifconfig *config |
---|
51 | ); |
---|
52 | extern int rtems_smc91111_driver_attach_leon2( |
---|
53 | struct rtems_bsdnet_ifconfig *config |
---|
54 | ); |
---|
55 | #define RTEMS_BSP_NETWORK_DRIVER_NAME "open_eth1" |
---|
56 | #define RTEMS_BSP_NETWORK_DRIVER_ATTACH_OPENETH \ |
---|
57 | rtems_leon_open_eth_driver_attach |
---|
58 | #define RTEMS_BSP_NETWORK_DRIVER_ATTACH_SMC91111 \ |
---|
59 | rtems_smc91111_driver_attach_leon2 |
---|
60 | |
---|
61 | #define HAS_SMC91111 |
---|
62 | |
---|
63 | /* Configure GRETH driver */ |
---|
64 | #define GRETH_SUPPORTED |
---|
65 | #define GRETH_MEM_LOAD(addr) leon_r32_no_cache(addr) |
---|
66 | |
---|
67 | /* |
---|
68 | * The synchronous trap is an arbitrarily chosen software trap. |
---|
69 | */ |
---|
70 | |
---|
71 | extern int CPU_SPARC_HAS_SNOOPING; |
---|
72 | |
---|
73 | /* Constants */ |
---|
74 | |
---|
75 | /* |
---|
76 | * Information placed in the linkcmds file. |
---|
77 | */ |
---|
78 | |
---|
79 | extern int RAM_START; |
---|
80 | extern int RAM_END; |
---|
81 | extern int RAM_SIZE; |
---|
82 | |
---|
83 | extern int PROM_START; |
---|
84 | extern int PROM_END; |
---|
85 | extern int PROM_SIZE; |
---|
86 | |
---|
87 | extern int CLOCK_SPEED; |
---|
88 | |
---|
89 | extern int end; /* last address in the program */ |
---|
90 | |
---|
91 | /* miscellaneous stuff assumed to exist */ |
---|
92 | |
---|
93 | rtems_isr_entry set_vector( /* returns old vector */ |
---|
94 | rtems_isr_entry handler, /* isr routine */ |
---|
95 | rtems_vector_number vector, /* vector number */ |
---|
96 | int type /* RTEMS or RAW intr */ |
---|
97 | ); |
---|
98 | |
---|
99 | void BSP_fatal_return( void ); |
---|
100 | |
---|
101 | void bsp_spurious_initialize( void ); |
---|
102 | |
---|
103 | #ifdef __cplusplus |
---|
104 | } |
---|
105 | #endif |
---|
106 | |
---|
107 | #endif |
---|