diff --git a/parts/src/org/lineageos/settings/doze/DozeService.java b/parts/src/org/lineageos/settings/doze/DozeService.java index 270eab7..84641e1 100644 --- a/parts/src/org/lineageos/settings/doze/DozeService.java +++ b/parts/src/org/lineageos/settings/doze/DozeService.java @@ -72,9 +72,6 @@ public class DozeService extends Service { private void onDisplayOn() { if (DEBUG) Log.d(TAG, "Display on"); - if (DozeUtils.isAlwaysOnEnabled(this)) { - DozeUtils.setDozeStatus(DozeUtils.DOZE_STATUS_DISABLED); - } if (DozeUtils.isPickUpEnabled(this)) { mPickupSensor.disable(); } @@ -89,9 +86,6 @@ public class DozeService extends Service { private void onDisplayOff() { if (DEBUG) Log.d(TAG, "Display off"); - if (DozeUtils.isAlwaysOnEnabled(this)) { - DozeUtils.setDozeStatus(DozeUtils.DOZE_STATUS_ENABLED); - } if (DozeUtils.isPickUpEnabled(this)) { mPickupSensor.enable(); } diff --git a/parts/src/org/lineageos/settings/doze/DozeUtils.java b/parts/src/org/lineageos/settings/doze/DozeUtils.java index 6dc121b..ff1921a 100644 --- a/parts/src/org/lineageos/settings/doze/DozeUtils.java +++ b/parts/src/org/lineageos/settings/doze/DozeUtils.java @@ -60,11 +60,6 @@ public final class DozeUtils { protected static final String DOZE_MODE_HBM = "1"; protected static final String DOZE_MODE_LBM = "0"; - private static final String DOZE_STATUS_PATH = - "/sys/devices/platform/soc/soc:qcom,dsi-display/doze_status"; - protected static final String DOZE_STATUS_ENABLED = "1"; - protected static final String DOZE_STATUS_DISABLED = "0"; - protected static final String DOZE_BRIGHTNESS_LBM = "0"; protected static final String DOZE_BRIGHTNESS_HBM = "1"; protected static final String DOZE_BRIGHTNESS_AUTO = "2"; @@ -157,10 +152,6 @@ public final class DozeUtils { return FileUtils.writeLine(DOZE_MODE_PATH, value); } - protected static boolean setDozeStatus(String value) { - return FileUtils.writeLine(DOZE_STATUS_PATH, value); - } - protected static boolean isDozeAutoBrightnessEnabled(Context context) { return PreferenceManager.getDefaultSharedPreferences(context) .getString(DOZE_BRIGHTNESS_KEY, DOZE_BRIGHTNESS_LBM) diff --git a/rootdir/etc/init.target.rc b/rootdir/etc/init.target.rc index 11f728b..0c54afb 100644 --- a/rootdir/etc/init.target.rc +++ b/rootdir/etc/init.target.rc @@ -96,9 +96,7 @@ on boot # Set doze mode permissions chown system system /sys/devices/platform/soc/soc:qcom,dsi-display/doze_mode - chown system system /sys/devices/platform/soc/soc:qcom,dsi-display/doze_status chmod 0660 /sys/devices/platform/soc/soc:qcom,dsi-display/doze_mode - chmod 0660 /sys/devices/platform/soc/soc:qcom,dsi-display/doze_status # Set xiaomi touch permissions chown system system /dev/xiaomi-touch diff --git a/sepolicy/vendor/file_contexts b/sepolicy/vendor/file_contexts index 7899d78..c6dfd77 100644 --- a/sepolicy/vendor/file_contexts +++ b/sepolicy/vendor/file_contexts @@ -14,7 +14,6 @@ /sys/devices/platform/soc/soc:qcom,dsi-display/fod_ui u:object_r:vendor_sysfs_fod:s0 /sys/devices/platform/soc/soc:qcom,dsi-display/hbm u:object_r:sysfs_hbm:s0 /sys/devices/platform/soc/soc:qcom,dsi-display/doze_mode u:object_r:sysfs_doze:s0 -/sys/devices/platform/soc/soc:qcom,dsi-display/doze_status u:object_r:sysfs_doze:s0 # Fingerprint /dev/goodix_fp u:object_r:fingerprint_device:s0