source: rtems/c/src/lib/libbsp/powerpc/tqm8xx/include/bsp.h @ ee0ea5bf

4.115
Last change on this file since ee0ea5bf was ee0ea5bf, checked in by Joel Sherrill <joel.sherrill@…>, on 10/12/14 at 18:57:28

powerpc/tqm8xx: Fix warnings

  • Property mode set to 100644
File size: 3.7 KB
Line 
1/*
2 *  RTEMS TQM8xx BSP
3 *  This include file contains all board IO definitions.
4 */
5
6/*
7 * This file has been adapted to MPC8xx by:
8 *    Thomas Doerfler <Thomas.Doerfler@embedded-brains.de>
9 *    Copyright (c) 2008
10 *    Embedded Brains GmbH
11 *    Obere Lagerstr. 30
12 *    D-82178 Puchheim
13 *    Germany
14 *    rtems@embedded-brains.de
15 *
16 *  COPYRIGHT (c) 1989-2008.
17 *  On-Line Applications Research Corporation (OAR).
18 *
19 *  The license and distribution terms for this file may be
20 *  found in the file LICENSE in this distribution or at
21 *  http://www.rtems.org/license/LICENSE.
22 */
23
24#ifndef _BSP_H
25#define _BSP_H
26
27/*
28 * indicate, that BSP is booted via TQMMon
29 */
30#define BSP_HAS_TQMMON
31
32#include <libcpu/powerpc-utility.h>
33
34LINKER_SYMBOL(TopRamReserved);
35
36LINKER_SYMBOL( bsp_ram_start);
37LINKER_SYMBOL( bsp_ram_end);
38LINKER_SYMBOL( bsp_ram_size);
39
40LINKER_SYMBOL( bsp_rom_start);
41LINKER_SYMBOL( bsp_rom_end);
42LINKER_SYMBOL( bsp_rom_size);
43
44LINKER_SYMBOL( bsp_section_text_start);
45LINKER_SYMBOL( bsp_section_text_end);
46LINKER_SYMBOL( bsp_section_text_size);
47
48LINKER_SYMBOL( bsp_section_data_start);
49LINKER_SYMBOL( bsp_section_data_end);
50LINKER_SYMBOL( bsp_section_data_size);
51
52LINKER_SYMBOL( bsp_section_bss_start);
53LINKER_SYMBOL( bsp_section_bss_end);
54LINKER_SYMBOL( bsp_section_bss_size);
55
56LINKER_SYMBOL( bsp_interrupt_stack_start);
57LINKER_SYMBOL( bsp_interrupt_stack_end);
58LINKER_SYMBOL( bsp_interrupt_stack_size);
59
60LINKER_SYMBOL( bsp_work_area_start);
61
62#ifndef ASM
63
64#include <bspopts.h>
65
66#include <rtems.h>
67#include <rtems/console.h>
68#include <rtems/clockdrv.h>
69#include <mpc8xx.h>
70#include <mpc8xx/cpm.h>
71#include <mpc8xx/mmu.h>
72#include <mpc8xx/console.h>
73#include <bsp/vectors.h>
74#include <bsp/tqm.h>
75#include <libcpu/powerpc-utility.h>
76#include <bsp/default-initial-extension.h>
77
78#ifdef __cplusplus
79extern "C" {
80#endif
81
82/*
83 * Network driver configuration
84 */
85struct rtems_bsdnet_ifconfig;
86
87#if BSP_USE_NETWORK_FEC
88extern int rtems_fec_enet_driver_attach (struct rtems_bsdnet_ifconfig *config,
89                                         int attaching);
90#define RTEMS_BSP_FEC_NETWORK_DRIVER_NAME       "fec1"
91#define RTEMS_BSP_FEC_NETWORK_DRIVER_ATTACH     rtems_fec_enet_driver_attach
92#endif
93
94#if BSP_USE_NETWORK_SCC
95extern int rtems_scc_enet_driver_attach (struct rtems_bsdnet_ifconfig *config,
96                                         int attaching);
97#define RTEMS_BSP_SCC_NETWORK_DRIVER_NAME       "scc1"
98#define RTEMS_BSP_SCC_NETWORK_DRIVER_ATTACH     rtems_scc_enet_driver_attach
99#endif
100
101#if BSP_USE_NETWORK_FEC
102#define RTEMS_BSP_NETWORK_DRIVER_NAME   RTEMS_BSP_FEC_NETWORK_DRIVER_NAME
103#define RTEMS_BSP_NETWORK_DRIVER_ATTACH RTEMS_BSP_FEC_NETWORK_DRIVER_ATTACH
104#elif BSP_USE_NETWORK_SCC
105#define RTEMS_BSP_NETWORK_DRIVER_NAME   RTEMS_BSP_SCC_NETWORK_DRIVER_NAME
106#define RTEMS_BSP_NETWORK_DRIVER_ATTACH RTEMS_BSP_SCC_NETWORK_DRIVER_ATTACH
107#endif
108/*
109 * We need to decide how much memory will be non-cacheable. This
110 * will mainly be memory that will be used in DMA (network and serial
111 * buffers).
112 */
113#define NOCACHE_MEM_SIZE 512*1024
114
115/*
116 * indicate, that BSP has IDE driver
117 */
118#undef RTEMS_BSP_HAS_IDE_DRIVER
119
120/*
121 * SPI driver configuration
122 */
123
124  /* select values for SPI addressing */
125#define PGHPLUS_SPI_ADDR_EEPROM 0
126#define PGHPLUS_SPI_ADDR_DISP4  1
127  /* NOTE: DISP4 occupies two consecutive addresses for data and control port */
128#define PGHPLUS_SPI_ADDR_DISP4_DATA  (PGHPLUS_SPI_ADDR_DISP4)
129#define PGHPLUS_SPI_ADDR_DISP4_CTRL  (PGHPLUS_SPI_ADDR_DISP4_DATA+1)
130
131  /* bit masks for Port B lines */
132#define PGHPLUS_PB_SPI_EEP_CE_MSK     (1<< 0)
133#define PGHPLUS_PB_SPI_DISP4_RS_MSK   (1<<15)
134#define PGHPLUS_PB_SPI_DISP4_CE_MSK   (1<<14)
135
136/*
137 * our (internal) bus frequency
138 */
139extern uint32_t BSP_bus_frequency;
140
141/*
142 *  Interfaces to required Clock Driver support methods
143 */
144int BSP_disconnect_clock_handler(void);
145int BSP_connect_clock_handler (rtems_irq_hdl);
146
147#ifdef __cplusplus
148}
149#endif
150
151#endif
152#endif
Note: See TracBrowser for help on using the repository browser.