From c579744e36eb925e74b0b52aff304cd0c4b33115 Mon Sep 17 00:00:00 2001 From: emilchung Date: Tue, 30 Jan 2024 03:50:38 +0000 Subject: [PATCH] hall_sensor: Disable hall sensor input when bootmode is unknown Fix: 322899718 Test: 1. No hall sensor in getevent. 2. Inner/outer screen can be switched in offmode charging, recovery, fastboot mode. Change-Id: Ie61216a201b31a320b423460fe6694d21838b973 Signed-off-by: emilchung --- conf/init.comet.rc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/conf/init.comet.rc b/conf/init.comet.rc index d8f7b8b..e85d829 100644 --- a/conf/init.comet.rc +++ b/conf/init.comet.rc @@ -43,6 +43,9 @@ on post-fs-data on init && property:ro.bootmode=normal write /sys/devices/platform/hall_sensor/enable 0 +on init && property:ro.bootmode=unknown + write /sys/devices/platform/hall_sensor/enable 0 + on init && property:ro.bootmode=factory write /sys/devices/platform/hall_sensor/enable 0