summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorElliott Hughes <enh@google.com>2013-11-21 20:35:50 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2013-11-21 20:35:50 +0000
commita6fbc0f9f49b797f4a67ea49f37681c08ab41111 (patch)
treef29513c7075bd95df23e09f2d688a12bc2974a55
parent048bb92f3f33196d96a51b446c73805e208a5333 (diff)
parentdccdb942841aec3d243e8df8ccd20d6279737a2e (diff)
downloadsystem_core-a6fbc0f9f49b797f4a67ea49f37681c08ab41111.zip
system_core-a6fbc0f9f49b797f4a67ea49f37681c08ab41111.tar.gz
system_core-a6fbc0f9f49b797f4a67ea49f37681c08ab41111.tar.bz2
Merge "Replace __reboot call with syscall"
-rw-r--r--libcutils/android_reboot.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libcutils/android_reboot.c b/libcutils/android_reboot.c
index 33a7358..7b3ec6f 100644
--- a/libcutils/android_reboot.c
+++ b/libcutils/android_reboot.c
@@ -16,6 +16,7 @@
#include <unistd.h>
#include <sys/reboot.h>
+#include <sys/syscall.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
@@ -121,7 +122,7 @@ int android_reboot(int cmd, int flags, char *arg)
break;
case ANDROID_RB_RESTART2:
- ret = __reboot(LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2,
+ ret = syscall(__NR_reboot, LINUX_REBOOT_MAGIC1, LINUX_REBOOT_MAGIC2,
LINUX_REBOOT_CMD_RESTART2, arg);
break;