source: rtems/c/src/lib/libbsp/shared/bspclean.c @ 6a9282d

5
Last change on this file since 6a9282d was 6a9282d, checked in by Sebastian Huber <sebastian.huber@…>, on Dec 9, 2016 at 9:49:49 AM

Rename is_internal to always_set_to_false

Update #2825.

  • 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.org/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 always_set_to_false,
17  rtems_fatal_code code
18)
19{
20  #if (BSP_PRINT_EXCEPTION_CONTEXT)
21    if ( source == RTEMS_FATAL_SOURCE_EXCEPTION ) {
22      rtems_exception_frame_print( (const rtems_exception_frame *) code );
23    }
24  #endif
25
26  #if (BSP_PRESS_KEY_FOR_RESET)
27    printk( "\nFATAL ERROR - Executive shutdown! Any key to reboot..." );
28
29    /*
30     * Wait for a key to be pressed
31     */
32    while ( getchark() == -1 )
33      ;
34
35    printk("\n");
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.