1 | /* bsp.h |
---|
2 | * |
---|
3 | * This include file contains some definitions specific to the |
---|
4 | * Cogent CSB350 Board. |
---|
5 | * |
---|
6 | * COPYRIGHT (c) 1989-2000. |
---|
7 | * On-Line Applications Research Corporation (OAR). |
---|
8 | * |
---|
9 | * The license and distribution terms for this file may be |
---|
10 | * found in the file LICENSE in this distribution or at |
---|
11 | * http://www.rtems.com/license/LICENSE. |
---|
12 | * |
---|
13 | * $Id$ |
---|
14 | */ |
---|
15 | |
---|
16 | #ifndef _BSP_H |
---|
17 | #define _BSP_H |
---|
18 | |
---|
19 | #ifdef __cplusplus |
---|
20 | extern "C" { |
---|
21 | #endif |
---|
22 | |
---|
23 | #include <bspopts.h> |
---|
24 | |
---|
25 | #include <rtems.h> |
---|
26 | #include <rtems/iosupp.h> |
---|
27 | #include <rtems/console.h> |
---|
28 | #include <rtems/clockdrv.h> |
---|
29 | #include <libcpu/au1x00.h> |
---|
30 | |
---|
31 | /* |
---|
32 | * Define the interrupt mechanism for Time Test 27 |
---|
33 | */ |
---|
34 | int assert_sw_irw(uint32_t irqnum); |
---|
35 | int negate_sw_irw(uint32_t irqnum); |
---|
36 | |
---|
37 | #define MUST_WAIT_FOR_INTERRUPT 0 |
---|
38 | |
---|
39 | #define Install_tm27_vector( handler ) \ |
---|
40 | (void) set_vector(handler, AU1X00_IRQ_SW0, 1); |
---|
41 | |
---|
42 | #define Cause_tm27_intr() \ |
---|
43 | do { \ |
---|
44 | assert_sw_irq(0); \ |
---|
45 | } while(0) |
---|
46 | |
---|
47 | #define Clear_tm27_intr() \ |
---|
48 | do { \ |
---|
49 | negate_sw_irq(0); \ |
---|
50 | } while(0) |
---|
51 | |
---|
52 | #if 0 |
---|
53 | #define Lower_tm27_intr() \ |
---|
54 | mips_enable_in_interrupt_mask( 0xff01 ); |
---|
55 | #else |
---|
56 | #define Lower_tm27_intr() \ |
---|
57 | do { \ |
---|
58 | continue;\ |
---|
59 | } while(0) |
---|
60 | #endif |
---|
61 | |
---|
62 | /* Constants */ |
---|
63 | |
---|
64 | /* miscellaneous stuff assumed to exist */ |
---|
65 | |
---|
66 | /* |
---|
67 | * Device Driver Table Entries |
---|
68 | */ |
---|
69 | |
---|
70 | /* |
---|
71 | * NOTE: Use the standard Console driver entry |
---|
72 | */ |
---|
73 | |
---|
74 | /* |
---|
75 | * NOTE: Use the standard Clock driver entry |
---|
76 | */ |
---|
77 | |
---|
78 | /* |
---|
79 | * Network driver configuration |
---|
80 | */ |
---|
81 | extern struct rtems_bsdnet_ifconfig *config; |
---|
82 | |
---|
83 | int rtems_au1x00_emac_attach(struct rtems_bsdnet_ifconfig *config, |
---|
84 | int attaching); |
---|
85 | #define RTEMS_BSP_NETWORK_DRIVER_NAME "eth0" |
---|
86 | #define RTEMS_BSP_NETWORK_DRIVER_ATTACH rtems_au1x00_emac_attach |
---|
87 | |
---|
88 | /* functions */ |
---|
89 | |
---|
90 | void bsp_cleanup( void ); |
---|
91 | |
---|
92 | rtems_isr_entry set_vector( |
---|
93 | rtems_isr_entry, rtems_vector_number, int ); |
---|
94 | |
---|
95 | #ifdef __cplusplus |
---|
96 | } |
---|
97 | #endif |
---|
98 | |
---|
99 | #endif |
---|