source: MondoRescue/branches/2.2.9/mindi-busybox/init/reboot.h@ 3320

Last change on this file since 3320 was 3320, checked in by Bruno Cornec, 9 years ago
  • Re-add (thanks git BTW) the 2.2.9 branch which had been destroyed in the move to 3.0
  • Property svn:eol-style set to native
File size: 737 bytes
Line 
1/*
2 * Definitions related to the reboot() system call,
3 * shared between init.c and halt.c.
4 */
5
6#include <sys/reboot.h>
7
8#ifndef RB_HALT_SYSTEM
9# if defined(__linux__)
10# define RB_HALT_SYSTEM 0xcdef0123
11# define RB_ENABLE_CAD 0x89abcdef
12# define RB_DISABLE_CAD 0
13# define RB_POWER_OFF 0x4321fedc
14# define RB_AUTOBOOT 0x01234567
15# elif defined(RB_HALT)
16# define RB_HALT_SYSTEM RB_HALT
17# endif
18#endif
19
20/* Stop system and switch power off if possible. */
21#ifndef RB_POWER_OFF
22# if defined(RB_POWERDOWN)
23# define RB_POWER_OFF RB_POWERDOWN
24# elif defined(__linux__)
25# define RB_POWER_OFF 0x4321fedc
26# else
27# warning "poweroff unsupported, using halt as fallback"
28# define RB_POWER_OFF RB_HALT_SYSTEM
29# endif
30#endif
Note: See TracBrowser for help on using the repository browser.