RTEMS  5.1
bsp.h
Go to the documentation of this file.
1 
9 /*===============================================================*\
10 | Project: RTEMS generic mcf548x BSP |
11 +-----------------------------------------------------------------+
12 | File: bsp.h |
13 +-----------------------------------------------------------------+
14 | The file contains the BSP header of generic MCF548x BSP. |
15 +-----------------------------------------------------------------+
16 | Copyright (c) 2007 |
17 | Embedded Brains GmbH |
18 | Obere Lagerstr. 30 |
19 | D-82178 Puchheim |
20 | Germany |
21 | rtems@embedded-brains.de |
22 +-----------------------------------------------------------------+
23 | |
24 | Parts of the code has been derived from the "dBUG source code" |
25 | package Freescale is providing for M548X EVBs. The usage of |
26 | the modified or unmodified code and it's integration into the |
27 | generic mcf548x BSP has been done according to the Freescale |
28 | license terms. |
29 | |
30 | The Freescale license terms can be reviewed in the file |
31 | |
32 | Freescale_license.txt |
33 | |
34 +-----------------------------------------------------------------+
35 | |
36 | The generic mcf548x BSP has been developed on the basic |
37 | structures and modules of the av5282 BSP. |
38 | |
39 +-----------------------------------------------------------------+
40 | |
41 | The license and distribution terms for this file may be |
42 | found in the file LICENSE in this distribution or at |
43 | |
44 | http://www.rtems.org/license/LICENSE. |
45 | |
46 +-----------------------------------------------------------------+
47 | |
48 | date history ID |
49 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
50 | 12.11.07 1.0 ras |
51 | |
52 \*===============================================================*/
53 
54 #ifndef LIBBSP_M68K_GENMCF548X_BSP_H
55 #define LIBBSP_M68K_GENMCF548X_BSP_H
56 
57 #include <bspopts.h>
59 
70 #include <rtems.h>
71 #include <rtems/bspIo.h>
72 
73 /***************************************************************************/
75 #include <mcf548x/mcf548x.h>
76 
77 #ifdef __cplusplus
78 extern "C" {
79 #endif
80 
81 /***************************************************************************/
84 /* define which port the console should use - all other ports are then defined as general purpose */
85 #define CONSOLE_PORT 0
86 
87 /* functions */
88 
89 uint32_t get_CPU_clock_speed(void);
90 
91 rtems_isr_entry set_vector(
92  rtems_isr_entry handler,
93  rtems_vector_number vector,
94  int type
95 );
96 
97 /* Initial values for the interrupt level and priority registers (INTC_ICRn) */
98 extern const uint8_t mcf548x_intc_icr_init_values[64];
99 
100 /*
101  * Network driver configuration
102  */
103 struct rtems_bsdnet_ifconfig;
104 extern int rtems_mcf548x_fec_driver_attach_detach(struct rtems_bsdnet_ifconfig *config,int attaching);
105 #define RTEMS_BSP_NETWORK_DRIVER_ATTACH rtems_mcf548x_fec_driver_attach_detach
106 
107 #define RTEMS_BSP_NETWORK_DRIVER_NAME "fec1"
108 #define RTEMS_BSP_NETWORK_DRIVER_NAME2 "fec2"
109 
110 #ifdef HAS_DBUG
111  typedef struct {
112  uint32_t console_baudrate;
113  uint8_t server_ip [4];
114  uint8_t client_ip [4];
115  uint8_t gateway_ip[4];
116  uint8_t netmask [4];
117  uint8_t spare[4];
118  uint8_t macaddr [6];
119  uint32_t ethport; /* default fec port: 1 = fec1, 2 = fec2 */
120  uint32_t uartport; /* default fec port: 1 = psc0, 2 = psc1... */
121  } dbug_settings_t;
122 
123 #define DBUG_SETTINGS (*(const dbug_settings_t *)0xFC020000)
124 #endif /* HAS_DBUG */
125 
126 void bsp_cacr_set_flags(uint32_t flags);
127 
128 void bsp_cacr_set_self_clear_flags(uint32_t flags);
129 
130 void bsp_cacr_clear_flags(uint32_t flags);
131 
132 #ifdef __cplusplus
133 }
134 #endif
135 
138 #endif
Definition: deflate.c:115
rtems_isr_entry set_vector(rtems_isr_entry handler, rtems_vector_number vector, int type)
Install an interrupt handler.
Definition: setvec.c:28
DEFAULT_INITIAL_EXTENSION Support.
ISR_Vector_number rtems_vector_number
Control block type used to manage the vectors.
Definition: intr.h:47
Interface to Kernel Print Methods.