iPXE
Functions
null_reboot.c File Reference

Null reboot mechanism. More...

#include <stdio.h>
#include <errno.h>
#include <ipxe/reboot.h>

Go to the source code of this file.

Functions

 FILE_LICENCE (GPL2_OR_LATER_OR_UBDL)
 
static void null_reboot (int warm __unused)
 Reboot system. More...
 
static int null_poweroff (void)
 Power off system. More...
 
 PROVIDE_REBOOT (null, reboot, null_reboot)
 
 PROVIDE_REBOOT (null, poweroff, null_poweroff)
 

Detailed Description

Null reboot mechanism.

Definition in file null_reboot.c.

Function Documentation

◆ FILE_LICENCE()

FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL  )

◆ null_reboot()

static void null_reboot ( int warm  __unused)
static

Reboot system.

Parameters
warmPerform a warm reboot

Definition at line 42 of file null_reboot.c.

42  {
43 
44  printf ( "Cannot reboot; not implemented\n" );
45  while ( 1 ) {}
46 }
int printf(const char *fmt,...)
Write a formatted string to the console.
Definition: vsprintf.c:464

References printf().

◆ null_poweroff()

static int null_poweroff ( void  )
static

Power off system.

Return values
rcReturn status code

Definition at line 53 of file null_reboot.c.

53  {
54 
55  return -ENOTSUP;
56 }
#define ENOTSUP
Operation not supported.
Definition: errno.h:589

References ENOTSUP.

◆ PROVIDE_REBOOT() [1/2]

PROVIDE_REBOOT ( null  ,
reboot  ,
null_reboot   
)

◆ PROVIDE_REBOOT() [2/2]

PROVIDE_REBOOT ( null  ,
poweroff  ,
null_poweroff   
)