blob: 081de1bb51d0d2145889f23014f2ba4c8cf0d294 [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001--- a/kexec/kexec-syscall.h
2+++ b/kexec/kexec-syscall.h
3@@ -2,7 +2,7 @@
4 #define KEXEC_SYSCALL_H
5
6 #define __LIBRARY__
7-#include <syscall.h>
8+/*#include <syscall.h>*/
9 #include <sys/syscall.h>
10 #include <unistd.h>
11
12@@ -23,6 +23,7 @@
13 #define LINUX_REBOOT_CMD_KEXEC 0x45584543
14
15 #ifndef __NR_kexec_load
16+/*
17 #ifdef __i386__
18 #define __NR_kexec_load 283
19 #endif
20@@ -61,19 +62,21 @@
21 #ifndef __NR_kexec_load
22 #error Unknown processor architecture. Needs a kexec_load syscall number.
23 #endif
24+*/
25 #endif /*ifndef __NR_kexec_load*/
26
27 struct kexec_segment;
28-
29+/*
30 static inline long kexec_load(void *entry, unsigned long nr_segments,
31 struct kexec_segment *segments, unsigned long flags)
32 {
33 return (long) syscall(__NR_kexec_load, entry, nr_segments, segments, flags);
34 }
35-
36+*/
37 static inline long kexec_reboot(void)
38 {
39- return (long) syscall(__NR_reboot, LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2, LINUX_REBOOT_CMD_KEXEC, 0);
40+ //return (long) syscall(__NR_reboot, LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2, LINUX_REBOOT_CMD_KEXEC, 0);
41+ return __reboot(LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2, LINUX_REBOOT_CMD_KEXEC, 0);
42 }
43
44