Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9bcac9cc authored by Aditya Bavanari's avatar Aditya Bavanari Committed by Gerrit - the friendly Code Review server
Browse files

hal: spkr_prot: Update the thermal zone path to physical path

When symbolic link is used instead of physical path to access
the thermal zones, hal fails to access the zones sometimes
due to insufficient access rights to sysfs.
Update the thermal zone path to sys/devices/virtual/thermal from
sys/class/thermal which is a symbolic link in order to access
the zones without fail.

Change-Id: I0850444f662ffe7dc7cc4076adeba8dc36fbc687
parent 988d22ea
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -103,9 +103,9 @@

#define MAX_PATH             (256)
#define MAX_STR_SIZE         (1024)
#define THERMAL_SYSFS "/sys/class/thermal"
#define TZ_TYPE "/sys/class/thermal/thermal_zone%d/type"
#define TZ_WSA "/sys/class/thermal/thermal_zone%d/temp"
#define THERMAL_SYSFS "/sys/devices/virtual/thermal"
#define TZ_TYPE "/sys/devices/virtual/thermal/thermal_zone%d/type"
#define TZ_WSA "/sys/devices/virtual/thermal/thermal_zone%d/temp"

#define AUDIO_PARAMETER_KEY_SPKR_TZ_1     "spkr_1_tz_name"
#define AUDIO_PARAMETER_KEY_SPKR_TZ_2     "spkr_2_tz_name"