FreeCalypso > hg > freecalypso-sw
diff loadtools/ltexit.c @ 392:134c047c1269
loadtools: Iota poweroff on Compal targets
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Wed, 11 Jun 2014 16:38:28 +0000 |
parents | 6f8d3771aa6c |
children |
line wrap: on
line diff
--- a/loadtools/ltexit.c Wed Jun 11 08:32:22 2014 +0000 +++ b/loadtools/ltexit.c Wed Jun 11 16:38:28 2014 +0000 @@ -1,6 +1,6 @@ /* * This module implements the loadtool exit command, along with its - * options for jump-reboot or eventual Iota power-off. + * options for jump-reboot and Iota power-off. */ #include <stdio.h> @@ -24,6 +24,16 @@ } static void +exit_iotaoff() +{ + static char *poweroff_argv[2] = {"poweroff", 0}; + + tpinterf_make_cmd(poweroff_argv); + tpinterf_send_cmd(); + exit(0); +} + +static void exit_jump0() { static char *jump0_argv[3] = {"jump", "0", 0}; @@ -41,6 +51,7 @@ } exit_modes[] = { {"bare", exit_bare}, {"gta02-cutpwr", exit_gta02_cutpwr}, + {"iota-off", exit_iotaoff}, {"jump0", exit_jump0}, {0, 0} };