diff options
author | Alex Hong <rurumihong@google.com> | 2020-03-23 16:32:07 +0000 |
---|---|---|
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | 2020-03-23 16:32:07 +0000 |
commit | 08972b2fe3179702d6f052f90e49d68b702395dc (patch) | |
tree | e44ef7ce8091922eeecdcfe001df8f9712d840c4 | |
parent | 178c0f6ce3cd0461f69dd6451380f19d18e09c0e (diff) | |
parent | e473ba3d583e4c7fe3cfbe389403c67ff19fb01c (diff) | |
download | thermal-08972b2fe3179702d6f052f90e49d68b702395dc.tar.gz |
Merge remote-tracking branch 'goog/qcom/release/LA.UM.7.8.9.C2.08.00.00.618.012' into rvc-dev am: 30ce54b7b0 am: e473ba3d58android-11.0.0_r48android-11.0.0_r47android-11.0.0_r46android-11.0.0_r45android-11.0.0_r44android-11.0.0_r43android-11.0.0_r42android-11.0.0_r41android-11.0.0_r40android-11.0.0_r39android-11.0.0_r38android-11.0.0_r37android-11.0.0_r36android-11.0.0_r35android-11.0.0_r34android-11.0.0_r33android-11.0.0_r32android-11.0.0_r31android-11.0.0_r30android-11.0.0_r29android-11.0.0_r28android-11.0.0_r27android-11.0.0_r26android-11.0.0_r24android-11.0.0_r23android-11.0.0_r22android-11.0.0_r21android-11.0.0_r20android-11.0.0_r19android-11.0.0_r18android11-qpr3-s1-releaseandroid11-qpr3-releaseandroid11-qpr2-releaseandroid11-qpr1-s2-releaseandroid11-qpr1-s1-releaseandroid11-qpr1-releaseandroid11-qpr1-d-s1-releaseandroid11-qpr1-d-releaseandroid11-qpr1-c-releaseandroid11-d2-release
Change-Id: I1ed80fe1e4165962501e5bde5761510ee37bdef7
-rw-r--r-- | thermal_common.h | 4 | ||||
-rw-r--r-- | thermal_target.c | 47 |
2 files changed, 49 insertions, 2 deletions
diff --git a/thermal_common.h b/thermal_common.h index 76bcff6..8e55868 100644 --- a/thermal_common.h +++ b/thermal_common.h @@ -1,4 +1,4 @@ -/* Copyright (c) 2018, The Linux Foundation. All rights reserved. +/* Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -44,6 +44,8 @@ enum therm_msm_id { THERM_MSM_8917, THERM_TRINKET, THERM_KONA, + THERM_LITO, + THERM_ATOLL, }; struct target_therm_cfg { diff --git a/thermal_target.c b/thermal_target.c index 7298f59..4332554 100644 --- a/thermal_target.c +++ b/thermal_target.c @@ -1,4 +1,4 @@ -/* Copyright (c) 2018, The Linux Foundation. All rights reserved. +/* Copyright (c) 2018-2019, The Linux Foundation. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are @@ -67,6 +67,7 @@ static struct therm_msm_soc_type msm_soc_table[] = { {THERM_SDM_439, 363}, {THERM_SDM_439, 364}, {THERM_MSMNILE, 339}, + {THERM_MSMNILE, 361}, {THERM_MSMNILE, 362}, {THERM_MSMNILE, 367}, {THERM_KONA, 356}, @@ -78,6 +79,8 @@ static struct therm_msm_soc_type msm_soc_table[] = { {THERM_MSM_8917, 309}, {THERM_MSM_8917, 386}, // This SOC ID is for QM215 {THERM_TRINKET, 394}, + {THERM_LITO, 400}, + {THERM_ATOLL, 407}, }; static char *cpu_sensors_talos[] = @@ -178,6 +181,43 @@ static struct target_therm_cfg sensor_cfg_sdmmagpie[] = { } }; +static char *misc_sensors_lito[] = +{ + "gpuss-0-usr", + "battery", + "xo-therm-usr" +}; + +static struct target_therm_cfg sensor_cfg_lito[] = { + { + .type = DEVICE_TEMPERATURE_CPU, + .sensor_list = cpu_sensors_sdmmagpie, + .sens_cnt = ARRAY_SIZE(cpu_sensors_sdmmagpie), + .mult = 0.001, + }, + { + .type = DEVICE_TEMPERATURE_GPU, + .sensor_list = &misc_sensors_lito[0], + .sens_cnt = 1, + .mult = 0.001, + .label = "GPU", + }, + { + .type = DEVICE_TEMPERATURE_BATTERY, + .sensor_list = &misc_sensors_lito[1], + .sens_cnt = 1, + .mult = 0.001, + .label = "battery", + }, + { + .type = DEVICE_TEMPERATURE_SKIN, + .sensor_list = &misc_sensors_lito[2], + .sens_cnt = 1, + .mult = 0.001, + .label = "skin", + } +}; + static char *cpu_sensors_trinket[] = { "cpuss-0-usr", @@ -705,6 +745,11 @@ ssize_t get_temperatures(thermal_module_t *module, temperature_t *list, size_t s cfg = sensor_cfg_trinket; num_cfg = ARRAY_SIZE(sensor_cfg_trinket); break; + case THERM_LITO: + case THERM_ATOLL: + cfg = sensor_cfg_lito; + num_cfg = ARRAY_SIZE(sensor_cfg_lito); + break; default: cfg = NULL; num_cfg = 0; |