source: rtems/c/src/lib/libbsp/m68k/ods68302/include/bsp.h @ 33d5f33

4.104.115
Last change on this file since 33d5f33 was 33d5f33, checked in by Joel Sherrill <joel.sherrill@…>, on 04/30/10 at 16:44:40

2010-04-30 Joel Sherrill <joel.sherrilL@…>

  • include/bsp.h: Add BSP_SMALL_MEMORY.
  • Property mode set to 100644
File size: 1.6 KB
Line 
1/*  bsp.h
2 *
3 *  This include file contains all board IO definitions.
4 *
5 *  COPYRIGHT (c) 1989-2010.
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 *  $Id$
13 */
14
15#ifndef _BSP_H
16#define _BSP_H
17
18#ifdef __cplusplus
19extern "C" {
20#endif
21
22#include <bspopts.h>
23
24#define BSP_SMALL_MEMORY 1
25#include <rtems.h>
26#include <rtems/console.h>
27#include <rtems/iosupp.h>
28#include <rtems/clockdrv.h>
29#include <rtems/m68k/m68302.h>
30
31#ifndef VARIANT
32#define VARIANT bare
33#endif
34#if defined(VARIANT)
35#define HQUOTE(a) <a.h>
36#include HQUOTE(VARIANT)
37#undef HQUOTE
38#endif
39
40/*
41 *  Simple spin delay in microsecond units for device drivers.
42 *  This is very dependent on the clock speed of the target.
43 */
44
45#define rtems_bsp_delay( microseconds ) \
46  { register uint32_t         _delay=(microseconds); \
47    register uint32_t         _tmp=123; \
48    asm volatile( "0: \
49                     nbcd      %0 ; \
50                     nbcd      %0 ; \
51                     dbf       %1,0b" \
52                  : "=d" (_tmp), "=d" (_delay) \
53                  : "0"  (_tmp), "1"  (_delay) ); \
54  }
55
56/* Constants */
57
58#define RAM_START RAM_BASE
59#define RAM_END   (RAM_BASE + RAM_SIZE)
60
61/* Structures */
62
63#ifdef GEN68302_INIT
64#undef EXTERN
65#define EXTERN
66#else
67#undef EXTERN
68#define EXTERN extern
69#endif
70
71extern m68k_isr_entry M68Kvec[];   /* vector table address */
72
73/* functions */
74
75m68k_isr_entry set_vector(
76  rtems_isr_entry     handler,
77  rtems_vector_number vector,
78  int                 type
79);
80
81#ifdef __cplusplus
82}
83#endif
84
85#endif
Note: See TracBrowser for help on using the repository browser.