Skip to content

Commit

Permalink
sdm845-common: Fix restoring default LiveDisplay mode
Browse files Browse the repository at this point in the history
* Call DisplayModes::setDisplayMode(modeID, false) in the constructor
* Move sysfs nodes chown/chmod to from 'on boot' to on init' so that
  they have proper perms right away.

Change-Id: I51ee19136688f83703e85b76d5219e5a567bbaa3
  • Loading branch information
luk1337 committed Jun 17, 2019
1 parent f0e0e81 commit 702507f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions livedisplay/DisplayModes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,8 @@ DisplayModes::DisplayModes() : mDefaultModeId(0) {
break;
}
}

setDisplayMode(mDefaultModeId, false);
}

// Methods from ::vendor::lineage::livedisplay::V2_0::IDisplayModes follow.
Expand Down
8 changes: 4 additions & 4 deletions livedisplay/[email protected]_sdm845.rc
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
on post-fs-data
mkdir /data/misc/display 0770 system graphics

on boot
on init
chmod 0660 /sys/devices/platform/soc/ae00000.qcom,mdss_mdp/main_display/display_mode
chmod 0660 /sys/devices/platform/soc/ae00000.qcom,mdss_mdp/main_display/hbm
chown system system /sys/devices/platform/soc/ae00000.qcom,mdss_mdp/main_display/display_mode
chown system system /sys/devices/platform/soc/ae00000.qcom,mdss_mdp/main_display/hbm

on post-fs-data
mkdir /data/misc/display 0770 system graphics

service livedisplay-hal-2-0 /system/bin/hw/[email protected]_sdm845
class hal
user system
Expand Down

0 comments on commit 702507f

Please sign in to comment.