Some devices have multiple panels, including some with 0 brightness. Take the one with the highest brightness

This commit is contained in:
Pierre-Hugues Husson 2020-05-14 18:31:37 +02:00 committed by tboy1991
parent f987ea4fee
commit c09bf830cc

View File

@ -701,4 +701,4 @@ resetprop service.adb.root 0
# This is for Samsung Galaxy devices with HBM FOD
# On those devices, a magic Layer usageBits switches to "mask_brightness"
# But default is 255, so set it to max instead
cat /sys/class/backlight/panel/max_brightness > /sys/class/lcd/panel/mask_brightness
cat /sys/class/backlight/*/max_brightness |sort -n |tail -n 1 > /sys/class/lcd/panel/mask_brightness