ReactOS 0.4.15-dev-5666-gc548b97
reboot.c File Reference
#include <hal.h>
#include <debug.h>
Include dependency graph for reboot.c:

Go to the source code of this file.

Macros

#define NDEBUG
 

Functions

static VOID DECLSPEC_NORETURN NTAPI HalpFreezeSystem (VOID)
 
VOID NTAPI HalpReboot (VOID)
 
VOID NTAPI HalReturnToFirmware (_In_ FIRMWARE_REENTRY Action)
 

Macro Definition Documentation

◆ NDEBUG

#define NDEBUG

Definition at line 12 of file reboot.c.

Function Documentation

◆ HalpFreezeSystem()

static VOID DECLSPEC_NORETURN NTAPI HalpFreezeSystem ( VOID  )
static

Definition at line 20 of file reboot.c.

21{
23
24 while (TRUE)
25 NOTHING;
26}
#define TRUE
Definition: types.h:120
VOID NTAPI HaliHaltSystem(VOID)
Definition: processor.c:21
#define NOTHING
Definition: input_list.c:10

Referenced by HalReturnToFirmware().

◆ HalpReboot()

VOID NTAPI HalpReboot ( VOID  )

Definition at line 30 of file reboot.c.

31{
32 /* Disable interrupts */
33 _disable();
34
35 /* Flush write buffers */
37
38 /* Send the reset command */
42
43 /* Halt the CPU */
44 __halt();
45}
VOID NTAPI KeFlushWriteBuffer(VOID)
Definition: misc.c:39
void __cdecl _disable(void)
Definition: intrin_arm.h:365
__INTRIN_INLINE void __halt(void)
Definition: intrin_x86.h:1714
unsigned char * PUCHAR
Definition: retypes.h:3
#define WRITE_PORT_UCHAR(p, d)
Definition: pc98vid.h:21
#define CPU_IO_o_RESET
Definition: cpu.h:10
#define PPI_IO_o_CONTROL
Definition: sysport.h:12
#define PPI_SHUTDOWN_0_ENABLE
Definition: sysport.h:16
#define PPI_SHUTDOWN_1_ENABLE
Definition: sysport.h:15

◆ HalReturnToFirmware()

VOID NTAPI HalReturnToFirmware ( _In_ FIRMWARE_REENTRY  Action)

Definition at line 51 of file reboot.c.

53{
54 switch (Action)
55 {
58
59 case HalHaltRoutine:
61#ifndef _MINIHAL_
62 /* Acquire the display */
64#endif
65
66 /* Call the internal reboot function */
67 HalpReboot();
68
69 /* Anything else */
70 default:
71 /* Print message and break */
72 DbgPrint("HalReturnToFirmware called!\n");
74 }
75}
#define DbgPrint
Definition: hal.h:12
VOID NTAPI HalpReboot(VOID)
Definition: reboot.c:28
static VOID DECLSPEC_NORETURN NTAPI HalpFreezeSystem(VOID)
Definition: reboot.c:20
VOID NTAPI InbvAcquireDisplayOwnership(VOID)
Definition: inbv.c:289
NTSYSAPI void WINAPI DbgBreakPoint(void)
@ HalHaltRoutine
Definition: haltypes.h:34
@ HalPowerDownRoutine
Definition: haltypes.h:35
@ HalRebootRoutine
Definition: haltypes.h:37
_In_ WDFIOTARGET _In_ _Strict_type_match_ WDF_IO_TARGET_SENT_IO_ACTION Action
Definition: wdfiotarget.h:510