source: rtems/c/src/lib/libbsp/m68k/gen68360/include/bsp.h @ 05adba6

4.104.115
Last change on this file since 05adba6 was 05adba6, checked in by Joel Sherrill <joel.sherrill@…>, on 09/10/08 at 21:35:06

2008-09-10 Joel Sherrill <joel.sherrill@…>

  • Makefile.am, include/bsp.h: Review of all bsp_cleanup() implementations. In this phase, all prototypes were removed from bsp.h and empty implementations were removed and made to use the shared stub.
  • startup/bspclean.c: Removed.
  • Property mode set to 100644
File size: 3.0 KB
Line 
1/*
2 * Board Support Package for `Generic' Motorola MC68360
3 *
4 * Based on the `gen68302' board support package, and covered by the
5 * original distribution terms.
6 *
7 * W. Eric Norum
8 * Saskatchewan Accelerator Laboratory
9 * University of Saskatchewan
10 * Saskatoon, Saskatchewan, CANADA
11 * eric@skatter.usask.ca
12 *
13 *  $Id$
14 */
15
16/*  bsp.h
17 *
18 *  COPYRIGHT (c) 1989-1999.
19 *  On-Line Applications Research Corporation (OAR).
20 *
21 *  The license and distribution terms for this file may be
22 *  found in the file LICENSE in this distribution or at
23 *  http://www.rtems.com/license/LICENSE.
24 */
25
26#ifndef _BSP_H
27#define _BSP_H
28
29#ifdef __cplusplus
30extern "C" {
31#endif
32
33#include <bspopts.h>
34
35#include <rtems.h>
36#include <rtems/console.h>
37#include <rtems/iosupp.h>
38#include <rtems/clockdrv.h>
39
40/*
41 * Network driver configuration
42 */
43struct rtems_bsdnet_ifconfig;
44extern int rtems_scc1_driver_attach (struct rtems_bsdnet_ifconfig *config, int attaching);
45#define RTEMS_BSP_NETWORK_DRIVER_NAME   "scc1"
46#define RTEMS_BSP_NETWORK_DRIVER_ATTACH rtems_scc1_driver_attach
47
48/*
49 *  Simple spin delay in microsecond units for device drivers.
50 *  This is very dependent on the clock speed of the target.
51 */
52
53#define rtems_bsp_delay( microseconds ) \
54  { register uint32_t         _delay=(microseconds); \
55    register uint32_t         _tmp=123; \
56    asm volatile( "0: \
57                     nbcd      %0 ; \
58                     nbcd      %0 ; \
59                     dbf       %1,0b" \
60                  : "=d" (_tmp), "=d" (_delay) \
61                  : "0"  (_tmp), "1"  (_delay) ); \
62  }
63
64/* Constants */
65
66/* Structures */
67
68/*
69 *  Device Driver Table Entries
70 */
71
72/*
73 * NOTE: Use the standard Console driver entry
74 */
75
76/*
77 * NOTE: Use the standard Clock driver entry
78 */
79
80/* miscellaneous stuff assumed to exist */
81
82extern m68k_isr_entry M68Kvec[];   /* vector table address */
83
84/* functions */
85
86void M360ExecuteRISC( uint16_t         command );
87void *M360AllocateBufferDescriptors( int count );
88void *M360AllocateRiscTimers( int count );
89extern char M360DefaultWatchdogFeeder;
90
91extern int m360_clock_rate; /* BRG clock rate, defined in console.c */
92
93m68k_isr_entry set_vector(
94  rtems_isr_entry     handler,
95  rtems_vector_number vector,
96  int                 type
97);
98
99/*
100 * Values assigned by link editor
101 */
102extern char _RamBase[];
103extern char _HeapSize[];
104
105
106/*
107 * Definitions for Atlas Computer Equipment Inc. High Speed Bridge (HSB)
108 */
109#define ATLASHSB_ESR    0x20010000L
110#define ATLASHSB_USICR  0x20010001L
111#define ATLASHSB_DSRR   0x20010002L
112#define ATLASHSB_LED4   0x20010004L
113#define ATLASHSB_ROM_U6 0xFF080000L     /* U6 flash ROM socket */
114
115
116  /*
117   * definitions for PGH360 board
118   */
119#if defined(PGH360)
120/*
121 * logical SPI addresses of SPI slaves available
122 */
123#define PGH360_SPI_ADDR_EEPROM     0
124#define PGH360_SPI_ADDR_DISP4_DATA 1
125#define PGH360_SPI_ADDR_DISP4_CTRL 2
126
127/*
128 * Port B bit locations of SPI slave selects
129 */
130#define PGH360_PB_SPI_DISP4_RS_MSK   (1<<15)
131#define PGH360_PB_SPI_DISP4_CE_MSK   (1<<14)
132#define PGH360_PB_SPI_EEP_CE_MSK     (1<< 0)
133#endif /* defined(PGH360) */
134
135#ifdef __cplusplus
136}
137#endif
138
139#endif
Note: See TracBrowser for help on using the repository browser.