diff options
author | Rashed Abdel-Tawab <rashed@linux.com> | 2018-09-17 12:14:16 -0700 |
---|---|---|
committer | Michael Bestas <mkbestas@lineageos.org> | 2018-09-17 23:00:01 +0300 |
commit | bd767ce687270079bf436373a292922b7424f60d (patch) | |
tree | b55b2074ffa10a379f7bcc77e3c9593087089f57 /power-helper.c | |
parent | ab7bde1b685fe5e587d72a43c67440e20ad8ced3 (diff) | |
download | android_hardware_qcom_power-bd767ce687270079bf436373a292922b7424f60d.tar.gz android_hardware_qcom_power-bd767ce687270079bf436373a292922b7424f60d.tar.bz2 android_hardware_qcom_power-bd767ce687270079bf436373a292922b7424f60d.zip |
power: Return empty subsystems power stats and always use Power@1.1
Instead of supporting a 1.0 HAL, always build the 1.1 HAL and just return an empty
subsystems supported count for devices that do not have wifi power stats
Change-Id: I9b4e37fb657b07529136bf7880de0f9fe5115a1c
Diffstat (limited to 'power-helper.c')
-rw-r--r-- | power-helper.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/power-helper.c b/power-helper.c index 1e4c05c..59f3ab7 100644 --- a/power-helper.c +++ b/power-helper.c @@ -75,7 +75,7 @@ Path for QCACLD2 and Prima: /d/wlan_wcnss/power_stats */ -#ifndef V1_0_HAL +#ifndef NO_WLAN_STATS #ifndef WLAN_POWER_STAT #define WLAN_POWER_STAT "/d/wlan0/power_stats" #endif @@ -103,7 +103,7 @@ static const char *rpm_master_param_names[] = { "xo_count" }; -#ifndef V1_0_HAL +#ifndef NO_WLAN_STATS static const char *wlan_param_names[] = { "cumulative_sleep_time_ms", "cumulative_total_on_time_ms", @@ -137,7 +137,7 @@ struct stat_pair rpm_stat_map[] = { }; #endif -#ifndef V1_0_HAL +#ifndef NO_WLAN_STATS const char *wlan_power_stat_params[] = { "cumulative_sleep_time_ms", "cumulative_total_on_time_ms", @@ -456,7 +456,7 @@ int extract_platform_stats(uint64_t *list) { return 0; } -#ifndef V1_0_HAL +#ifndef NO_WLAN_STATS int extract_wlan_stats(uint64_t *list) { int ret; ret = extract_stats(list, WLAN_POWER_STAT, wlan_param_names, WLAN_POWER_PARAMS_COUNT, false); @@ -554,7 +554,7 @@ int extract_platform_stats(uint64_t *list) { return extract_stats(list, RPM_SYSTEM_STAT, rpm_stat_map, ARRAY_SIZE(rpm_stat_map)); } -#ifndef V1_0_HAL +#ifndef NO_WLAN_STATS int extract_wlan_stats(uint64_t *list) { return extract_stats(list, WLAN_POWER_STAT, wlan_stat_map, ARRAY_SIZE(wlan_stat_map)); } |