source: rtems/c/src/lib/libbsp/m68k/mvme147/startup/bspclean.c @ 46dad9d4

4.115
Last change on this file since 46dad9d4 was 46dad9d4, checked in by Joel Sherrill <joel.sherrill@…>, on 10/15/14 at 22:54:02

m68k/mvme147: Fix warnings

  • Property mode set to 100644
File size: 1.3 KB
Line 
1/*
2 *  This routine returns control to 147Bug.
3 */
4
5/*
6 *  COPYRIGHT (c) 1989-2014.
7 *  On-Line Applications Research Corporation (OAR).
8 *
9 *  The license and distribution terms for this file may be
10 *  found in the file LICENSE in this distribution or at
11 *  http://www.rtems.org/license/LICENSE.
12 *
13 *  MVME147 port for TNI - Telecom Bretagne
14 *  by Dominique LE CAMPION (Dominique.LECAMPION@enst-bretagne.fr)
15 *  May 1996
16 */
17
18#include <bsp.h>
19#include <bsp/bootcard.h>
20
21extern void start(void);
22
23static rtems_isr bsp_return_to_monitor_trap(
24  rtems_vector_number vector
25)
26{
27  register volatile void *start_addr;
28
29  m68k_set_vbr( 0 );                    /* restore 147Bug vectors */
30  __asm__ volatile( "trap   #15"  );    /* trap to 147Bug */
31  __asm__ volatile( ".short 0x63" );    /* return to 147Bug (.RETURN) */
32                                        /* restart program */
33  start_addr = start;
34
35  __asm__ volatile ( "jmp %0@" : "=a" (start_addr) : "0" (start_addr) );
36}
37
38void bsp_fatal_extension(
39  rtems_fatal_source source,
40  bool is_internal,
41  rtems_fatal_code error
42)
43{
44   pcc->timer1_int_control = 0; /* Disable Timer 1 */
45   pcc->timer2_int_control = 0; /* Disable Timer 2 */
46
47   M68Kvec[ 45 ] = bsp_return_to_monitor_trap;   /* install handler */
48   __asm__ volatile( "trap #13" );               /* ensures SUPV mode */
49}
Note: See TracBrowser for help on using the repository browser.