summaryrefslogtreecommitdiff
path: root/thermal_common.h
diff options
context:
space:
mode:
authorManaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>2018-09-03 18:04:03 +0530
committerManaf Meethalavalappu Pallikunhi <manafm@codeaurora.org>2018-09-07 14:42:16 +0530
commit3cd560ff0b230d8054460c5a77db3d0ef49f4632 (patch)
tree1882e24903a09586e5e41d7d9f4afa3e3b80e3cc /thermal_common.h
parent24ab2c825f3d2fc41c519d5d8ba25e86e39b65d0 (diff)
downloadthermal-3cd560ff0b230d8054460c5a77db3d0ef49f4632.tar.gz
thermal-hal: Update get temperature API support for legacy targets
Add support for get temperature API support for legcay targets including SDM710, QCS605, SDM660, SDM630, MSM8953, SDM632, SDM439 etc. There are targets which are binary compatible, but uses different sensor configuration. Enable soc id based platform detection and use different sensor configuration. Change-Id: I2537476c07887f9131c33b352f5ffd3a4bc0dd31
Diffstat (limited to 'thermal_common.h')
-rw-r--r--thermal_common.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/thermal_common.h b/thermal_common.h
index 4137322..5a07804 100644
--- a/thermal_common.h
+++ b/thermal_common.h
@@ -29,6 +29,17 @@
#include <hardware/thermal.h>
#define ARRAY_SIZE(x) (int)(sizeof(x)/sizeof(x[0]))
+enum therm_msm_id {
+ THERM_MSM_UNKNOWN = 0,
+ THERM_MSM_8953,
+ THERM_SDM_660,
+ THERM_SDM_630,
+ THERM_SDM_710,
+ THERM_QCS_605,
+ THERM_SDM_632,
+ THERM_SDM_439,
+};
+
struct target_therm_cfg {
enum temperature_type type;
char **sensor_list;
@@ -46,6 +57,8 @@ struct vendor_temperature {
temperature_t t;
};
+
+int read_line_from_file(const char *path, char *buf, size_t count);
size_t get_num_cpus();
const char *get_cpu_label(unsigned int cpu_num);
int thermal_zone_init(struct target_therm_cfg *v_sen_t, int cfg_cnt);