Changeset 084369e in rtems


Ignore:
Timestamp:
Sep 22, 2008, 9:49:43 PM (11 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, master
Children:
34ea1e6
Parents:
d4f6b30
Message:

2008-09-22 Joel Sherrill <joel.sherrill@…>

  • Makefile.am, configure.ac, console/inch.c, console/keyboard.c, include/bsp.h: Use standardized bsp_cleanup() which can optionally print a message, poll for user to press key, and call bsp_reset(). Using this eliminates the various bsp_cleanup() implementations which had their own implementation and variety of string constants.
Location:
c/src/lib/libbsp/i386/pc386
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/i386/pc386/ChangeLog

    rd4f6b30 r084369e  
     12008-09-22      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * Makefile.am, configure.ac, console/inch.c, console/keyboard.c,
     4        include/bsp.h: Use standardized bsp_cleanup() which can optionally
     5        print a message, poll for user to press key, and call bsp_reset().
     6        Using this eliminates the various bsp_cleanup() implementations which
     7        had their own implementation and variety of string constants.
     8
    192008-09-18      Joel Sherrill <joel.sherrill@oarcorp.com>
    210
  • c/src/lib/libbsp/i386/pc386/Makefile.am

    rd4f6b30 r084369e  
    8181startup_SOURCES = ../../shared/bsplibc.c ../../shared/bsppost.c \
    8282    ../../shared/bsppredriverhook.c startup/bspgetworkarea.c \
    83     ../../shared/bsppretaskinghook.c \
    84     startup/bspstart.c startup/bspclean.c ../../i386/shared/irq/idt.c \
     83    ../../shared/bsppretaskinghook.c startup/bspstart.c \
     84    ../../shared/bspclean.c startup/bspreset.c ../../i386/shared/irq/idt.c \
    8585    ../../i386/shared/irq/irq.c ../../i386/shared/irq/irq_init.c \
    8686    ../../shared/bootcard.c ../../shared/sbrk.c \
  • c/src/lib/libbsp/i386/pc386/configure.ac

    rd4f6b30 r084369e  
    5959AC_SUBST(RTEMS_BSP)
    6060
     61RTEMS_BSPOPTS_SET([BSP_PRESS_KEY_FOR_RESET],[*],[1])
     62RTEMS_BSPOPTS_HELP([BSP_PRESS_KEY_FOR_RESET],
     63[If defined, print a message and wait until pressed before resetting
     64 board when application exits.])
     65
     66RTEMS_BSPOPTS_SET([BSP_RESET_BOARD_AT_EXIT],[*],[1])
     67RTEMS_BSPOPTS_HELP([BSP_RESET_BOARD_AT_EXIT],
     68[If defined, reset the board when the application exits.])
     69
    6170RTEMS_BSP_BOOTCARD_HANDLES_RAM_ALLOCATION
    6271
  • c/src/lib/libbsp/i386/pc386/console/inch.c

    rd4f6b30 r084369e  
    3131
    3232#include <bsp.h>
     33#include <bsp/bootcard.h>
    3334#include <bsp/irq.h>
    3435
     
    7374
    7475/*-------------------------------------------------------------------------+
    75 |         Function: rtemsReboot
    76 |      Description: Reboot the PC.
    77 | Global Variables: None.
    78 |        Arguments: None.
    79 |          Returns: Nothing.
    80 +--------------------------------------------------------------------------*/
    81 void rtemsReboot(void)
    82 {
    83   /* shutdown and reboot */
    84   outport_byte(0x64, 0xFE);      /* use keyboard controler to do the job... */
    85 } /* rtemsReboot */
    86 
    87 /*-------------------------------------------------------------------------+
    8876|         Function: _IBMPC_scankey
    8977|      Description: This function can be called during a poll for input, or by
     
    175163    case 0x53:
    176164      if (ctrl_pressed && alt_pressed)
    177         rtemsReboot(); /* ctrl+alt+del -> reboot */
     165        bsp_reset(); /* ctrl+alt+del -> reboot */
    178166      break;
    179167
  • c/src/lib/libbsp/i386/pc386/console/keyboard.c

    rd4f6b30 r084369e  
    1111#include <rtems/kd.h>
    1212#include <bsp.h>
     13#include <bsp/bootcard.h>
    1314
    1415#define SIZE(x) (sizeof(x)/sizeof((x)[0]))
     
    3132
    3233extern void add_to_queue( unsigned short );
    33 extern void rtemsReboot( void );
    3434
    3535int set_bit(int nr, unsigned long * addr)
     
    135135
    136136static void_fn do_null, enter, show_ptregs, send_intr, lastcons, caps_toggle,
    137   num, hold, scroll_forw, scroll_back, boot_it, caps_on, compose,
     137  num, hold, scroll_forw, scroll_back, caps_on, compose,
    138138  SAK, decr_console, incr_console, spawn_console, bare_num;
    139139
     
    142142  show_state,  send_intr,  lastcons,  caps_toggle,
    143143  num,    hold,    scroll_forw,  scroll_back,
    144   boot_it,  caps_on,  compose,  SAK,
     144  bsp_reset,  caps_on,  compose,  SAK,
    145145  decr_console,  incr_console,  spawn_console,  bare_num
    146146};
     
    456456}
    457457
    458 static void boot_it(void)
    459 {
    460    printk( "boot_it() " );
    461    rtemsReboot();
    462 }
    463 
    464458static void compose(void)
    465459{
  • c/src/lib/libbsp/i386/pc386/include/bsp.h

    rd4f6b30 r084369e  
    176176char          _IBMPC_inch_sleep (void);  /* from 'inch.c'   */
    177177
    178 void rtemsReboot(void);                  /* from 'exit.c'   */
    179 
    180178void Wait_X_ms(unsigned int timeToWait); /* from 'timer.c'  */
    181179
Note: See TracChangeset for help on using the changeset viewer.