source: rtems/c/src/lib/libbsp/shared/bspclean.c @ 48bff53b

4.115
Last change on this file since 48bff53b was 48bff53b, checked in by Sebastian Huber <sebastian.huber@…>, on 12/06/12 at 16:47:30

score: rtems_initialize_start_multitasking()

Do not return from rtems_initialize_start_multitasking() and call
rtems_fatal() instead with a fatal source of RTEMS_FATAL_SOURCE_EXIT and
a fatal code with the exit status.

Remove all bsp_cleanup() functions. The boot_card() is now a no return
function.

  • Property mode set to 100644
File size: 1.0 KB
Line 
1/*
2 *  COPYRIGHT (c) 1989-1999.
3 *  On-Line Applications Research Corporation (OAR).
4 *
5 *  The license and distribution terms for this file may be
6 *  found in the file LICENSE in this distribution or at
7 *  http://www.rtems.com/license/LICENSE.
8 */
9
10#include <bsp.h>
11#include <bsp/bootcard.h>
12#include <rtems/bspIo.h>
13
14void bsp_fatal_extension(
15  rtems_fatal_source source,
16  bool is_internal,
17  rtems_fatal_code code
18)
19{
20  #if (BSP_PRESS_KEY_FOR_RESET)
21    printk( "\nEXECUTIVE SHUTDOWN! Any key to reboot..." );
22
23    /*
24     * Wait for a key to be pressed
25     */
26    while ( getchark() == -1 )
27      ;
28
29    printk("\n");
30  #endif
31
32  #if (BSP_PRINT_EXCEPTION_CONTEXT)
33    if ( source == RTEMS_FATAL_SOURCE_EXCEPTION ) {
34      rtems_exception_frame_print( (const rtems_exception_frame *) code );
35    }
36  #endif
37
38  /*
39   *  Check both conditions -- if you want to ask for reboot, then
40   *  you must have meant to reset the board.
41   */
42  #if (BSP_PRESS_KEY_FOR_RESET) || (BSP_RESET_BOARD_AT_EXIT)
43    bsp_reset();
44  #endif
45}
Note: See TracBrowser for help on using the repository browser.