Merge "libcutils: android_reboot: add thermal shutdown command"

This commit is contained in:
Treehugger Robot 2017-03-15 02:11:38 +00:00 committed by Gerrit Code Review
commit 97a2c49a58
2 changed files with 5 additions and 0 deletions

View File

@ -209,6 +209,10 @@ int android_reboot_with_callback(
LINUX_REBOOT_CMD_RESTART2, arg);
break;
case ANDROID_RB_THERMOFF:
ret = reboot(RB_POWER_OFF);
break;
default:
ret = -1;
}

View File

@ -25,6 +25,7 @@ __BEGIN_DECLS
#define ANDROID_RB_RESTART 0xDEAD0001
#define ANDROID_RB_POWEROFF 0xDEAD0002
#define ANDROID_RB_RESTART2 0xDEAD0003
#define ANDROID_RB_THERMOFF 0xDEAD0004
/* Properties */
#define ANDROID_RB_PROPERTY "sys.powerctl"