Dmitry V. Levin | 9aaf88c | 2014-02-05 14:51:19 +0000 | [diff] [blame] | 1 | #include "defs.h" |
Dmitry V. Levin | 9aaf88c | 2014-02-05 14:51:19 +0000 | [diff] [blame] | 2 | |
Dmitry V. Levin | 0ed617b | 2014-04-25 23:30:54 +0000 | [diff] [blame] | 3 | #include "xlat/bootflags1.h" |
Dmitry V. Levin | 0ed617b | 2014-04-25 23:30:54 +0000 | [diff] [blame] | 4 | #include "xlat/bootflags2.h" |
Dmitry V. Levin | 0ed617b | 2014-04-25 23:30:54 +0000 | [diff] [blame] | 5 | #include "xlat/bootflags3.h" |
Dmitry V. Levin | 9aaf88c | 2014-02-05 14:51:19 +0000 | [diff] [blame] | 6 | |
Dmitry V. Levin | a0bd374 | 2015-04-07 01:36:50 +0000 | [diff] [blame] | 7 | SYS_FUNC(reboot) |
Dmitry V. Levin | 9aaf88c | 2014-02-05 14:51:19 +0000 | [diff] [blame] | 8 | { |
Dmitry V. Levin | b83bb1c | 2016-04-26 17:41:44 +0000 | [diff] [blame] | 9 | const unsigned int magic1 = tcp->u_arg[0]; |
| 10 | const unsigned int magic2 = tcp->u_arg[1]; |
| 11 | const unsigned int cmd = tcp->u_arg[2]; |
| 12 | |
| 13 | printflags(bootflags1, magic1, "LINUX_REBOOT_MAGIC_???"); |
Dmitry V. Levin | 9aaf88c | 2014-02-05 14:51:19 +0000 | [diff] [blame] | 14 | tprints(", "); |
Dmitry V. Levin | b83bb1c | 2016-04-26 17:41:44 +0000 | [diff] [blame] | 15 | printflags(bootflags2, magic2, "LINUX_REBOOT_MAGIC_???"); |
Dmitry V. Levin | 9aaf88c | 2014-02-05 14:51:19 +0000 | [diff] [blame] | 16 | tprints(", "); |
Dmitry V. Levin | b83bb1c | 2016-04-26 17:41:44 +0000 | [diff] [blame] | 17 | printflags(bootflags3, cmd, "LINUX_REBOOT_CMD_???"); |
| 18 | if (cmd == LINUX_REBOOT_CMD_RESTART2) { |
Dmitry V. Levin | 9aaf88c | 2014-02-05 14:51:19 +0000 | [diff] [blame] | 19 | tprints(", "); |
| 20 | printstr(tcp, tcp->u_arg[3], -1); |
| 21 | } |
Dmitry V. Levin | 307945d | 2015-07-17 20:27:00 +0000 | [diff] [blame] | 22 | return RVAL_DECODED; |
Dmitry V. Levin | 9aaf88c | 2014-02-05 14:51:19 +0000 | [diff] [blame] | 23 | } |