source: rtems/c/src/lib/libbsp/m68k/mvme136/startup/bspstart.c @ 19f4a349

4.104.114.95
Last change on this file since 19f4a349 was 19f4a349, checked in by Joel Sherrill <joel.sherrill@…>, on 05/15/08 at 15:52:00

2008-05-15 Joel Sherrill <joel.sherrill@…>

  • Makefile.am, configure.ac, startup/bspstart.c: Add capability for bootcard.c BSP Initialization Framework to ask the BSP where it has memory for the RTEMS Workspace and C Program Heap. These collectively are referred to as work area. If the BSP supports this, then it does not have to include code to split the available memory between the two areas. This reduces the amount of code in the BSP specific bspstart.c file. Additionally, the shared framework can dirty the work area memory. Until most/all BSPs support this new capability, if the BSP supports this, it should call RTEMS_BSP_BOOTCARD_HANDLES_RAM_ALLOCATION from its configure.ac. When the transition is complete, this autoconf macro can be removed.
  • Property mode set to 100644
File size: 1.4 KB
Line 
1/*
2 *  This routine starts the application.  It includes application,
3 *  board, and monitor specific initialization and configuration.
4 *  The generic CPU dependent initialization has been performed
5 *  before this routine is invoked.
6 *
7 *  COPYRIGHT (c) 1989-1999.
8 *  On-Line Applications Research Corporation (OAR).
9 *
10 *  The license and distribution terms for this file may be
11 *  found in the file LICENSE in this distribution or at
12 *  http://www.rtems.com/license/LICENSE.
13 *
14 *  $Id$
15 */
16
17#include <string.h>
18
19#include <bsp.h>
20#include <rtems/libio.h>
21#include <rtems/libcsupport.h>
22#include <rtems/zilog/z8036.h>
23
24/*
25 *  bsp_start
26 *
27 *  This routine does the bulk of the system initialization.
28 */
29void bsp_start( void )
30{
31  m68k_isr_entry *monitors_vector_table;
32  int             index;
33
34  monitors_vector_table = (m68k_isr_entry *)0;   /* 135Bug Vectors are at 0 */
35  m68k_set_vbr( monitors_vector_table );
36
37  for ( index=2 ; index<=255 ; index++ )
38    M68Kvec[ index ] = monitors_vector_table[ 32 ];
39
40  M68Kvec[  2 ] = monitors_vector_table[  2 ];   /* bus error vector */
41  M68Kvec[  4 ] = monitors_vector_table[  4 ];   /* breakpoints vector */
42  M68Kvec[  9 ] = monitors_vector_table[  9 ];   /* trace vector */
43  M68Kvec[ 47 ] = monitors_vector_table[ 47 ];   /* system call vector */
44
45  m68k_set_vbr( &M68Kvec );
46
47  (*(uint8_t*)0xfffb0067) = 0x7f; /* make VME access round-robin */
48
49  rtems_cache_enable_instruction();
50}
Note: See TracBrowser for help on using the repository browser.