2005-04-21 16:53:53 +02:00
|
|
|
/* reboot.c - Systemcall interface to mm/signal.c::do_reboot()
|
|
|
|
|
|
|
|
author: Edvard Tuinder v892231@si.hhs.NL
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <lib.h>
|
|
|
|
#define reboot _reboot
|
|
|
|
#include <unistd.h>
|
|
|
|
#include <stdarg.h>
|
|
|
|
|
|
|
|
int reboot(int how, ...)
|
|
|
|
{
|
|
|
|
message m;
|
|
|
|
va_list ap;
|
|
|
|
|
|
|
|
va_start(ap, how);
|
|
|
|
if ((m.m1_i1 = how) == RBT_MONITOR) {
|
|
|
|
m.m1_p1 = va_arg(ap, char *);
|
|
|
|
m.m1_i2 = va_arg(ap, size_t);
|
|
|
|
}
|
|
|
|
va_end(ap);
|
|
|
|
|
2010-06-08 15:58:01 +02:00
|
|
|
return _syscall(PM_PROC_NR, REBOOT, &m);
|
2005-04-21 16:53:53 +02:00
|
|
|
}
|