summaryrefslogtreecommitdiff
path: root/include/linux/input
diff options
context:
space:
mode:
authorLijuan Gao <lijuang@codeaurora.org>2017-12-06 16:20:35 +0800
committerLijuan Gao <lijuang@codeaurora.org>2017-12-11 19:11:18 +0800
commit25c63fa374f6f23f948ad9c1ec9ed2a0962502e6 (patch)
tree1f3cf56d1703d627b4b167e26863880c0f64481f /include/linux/input
parent4f8f0737764aefd860f16eca0af844a639f8a11b (diff)
drivers: power: reset: Do cold reset when doing oem reboot
As the IMEM approach to store reset reason is deprecated, so use the spare register in PMIC power-on peripheral to store the oem restart reason. Bit-2 to bit-7 of SOFT_RB_SPARE for hard reset reason, so divide existing range into regions, value 0 to 31 for common defined features and 32 to 63 values are for OEMs/ODMs specific features. Change-Id: Ib8e64d6dd5a335325d0469280e41e9d10ec9b893 Signed-off-by: Lijuan Gao <lijuang@codeaurora.org>
Diffstat (limited to 'include/linux/input')
-rw-r--r--include/linux/input/qpnp-power-on.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/input/qpnp-power-on.h b/include/linux/input/qpnp-power-on.h
index a2624ab57826..5944f0fd3414 100644
--- a/include/linux/input/qpnp-power-on.h
+++ b/include/linux/input/qpnp-power-on.h
@@ -51,6 +51,7 @@ enum pon_power_off_type {
};
enum pon_restart_reason {
+ /* 0 ~ 31 for common defined features */
PON_RESTART_REASON_UNKNOWN = 0x00,
PON_RESTART_REASON_RECOVERY = 0x01,
PON_RESTART_REASON_BOOTLOADER = 0x02,
@@ -58,6 +59,10 @@ enum pon_restart_reason {
PON_RESTART_REASON_DMVERITY_CORRUPTED = 0x04,
PON_RESTART_REASON_DMVERITY_ENFORCE = 0x05,
PON_RESTART_REASON_KEYS_CLEAR = 0x06,
+
+ /* 32 ~ 63 for OEMs/ODMs secific features */
+ PON_RESTART_REASON_OEM_MIN = 0x20,
+ PON_RESTART_REASON_OEM_MAX = 0x3f,
};
#ifdef CONFIG_INPUT_QPNP_POWER_ON