blob: e3fa77a994a1ef73a61b87ff097389ebfc3c779a [file] [log] [blame]
Dmitry V. Levin9aaf88c2014-02-05 14:51:19 +00001#include "defs.h"
2#include <linux/reboot.h>
3
Dmitry V. Levin0ed617b2014-04-25 23:30:54 +00004#include "xlat/bootflags1.h"
Dmitry V. Levin0ed617b2014-04-25 23:30:54 +00005#include "xlat/bootflags2.h"
Dmitry V. Levin0ed617b2014-04-25 23:30:54 +00006#include "xlat/bootflags3.h"
Dmitry V. Levin9aaf88c2014-02-05 14:51:19 +00007
8int
9sys_reboot(struct tcb *tcp)
10{
11 if (exiting(tcp))
12 return 0;
13
14 printflags(bootflags1, tcp->u_arg[0], "LINUX_REBOOT_MAGIC_???");
15 tprints(", ");
16 printflags(bootflags2, tcp->u_arg[1], "LINUX_REBOOT_MAGIC_???");
17 tprints(", ");
18 printflags(bootflags3, tcp->u_arg[2], "LINUX_REBOOT_CMD_???");
Dmitry V. Levin3ed5d022014-09-10 13:46:04 +000019 if (tcp->u_arg[2] == (long) LINUX_REBOOT_CMD_RESTART2) {
Dmitry V. Levin9aaf88c2014-02-05 14:51:19 +000020 tprints(", ");
21 printstr(tcp, tcp->u_arg[3], -1);
22 }
23 return 0;
24}