Changeset View
Changeset View
Standalone View
Standalone View
head/stand/efi/loader/main.c
Show First 20 Lines • Show All 987 Lines • ▼ Show 20 Lines | #if !defined(__arm__) | ||||
} | } | ||||
#endif | #endif | ||||
interact(); /* doesn't return */ | interact(); /* doesn't return */ | ||||
return (EFI_SUCCESS); /* keep compiler happy */ | return (EFI_SUCCESS); /* keep compiler happy */ | ||||
} | } | ||||
COMMAND_SET(poweroff, "poweroff", "power off the system", command_poweroff); | |||||
static int | |||||
command_poweroff(int argc __unused, char *argv[] __unused) | |||||
{ | |||||
int i; | |||||
for (i = 0; devsw[i] != NULL; ++i) | |||||
if (devsw[i]->dv_cleanup != NULL) | |||||
(devsw[i]->dv_cleanup)(); | |||||
RS->ResetSystem(EfiResetShutdown, EFI_SUCCESS, 0, NULL); | |||||
/* NOTREACHED */ | |||||
return (CMD_ERROR); | |||||
} | |||||
COMMAND_SET(reboot, "reboot", "reboot the system", command_reboot); | COMMAND_SET(reboot, "reboot", "reboot the system", command_reboot); | ||||
static int | static int | ||||
command_reboot(int argc, char *argv[]) | command_reboot(int argc, char *argv[]) | ||||
{ | { | ||||
int i; | int i; | ||||
for (i = 0; devsw[i] != NULL; ++i) | for (i = 0; devsw[i] != NULL; ++i) | ||||
▲ Show 20 Lines • Show All 373 Lines • Show Last 20 Lines |