thermal: tsens8960: Add api to read max supported sensors
Provide api to report the maximum number of TSENS sensors
supported. Backport this from the 8974 TSENS driver
to support thermal monitor driver compilation.
Change-Id: I712ccd8169eb3df0f1e83189aea1dd98180c3e7d
Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>
diff --git a/include/linux/msm_tsens.h b/include/linux/msm_tsens.h
index e40f301..8aa7c17 100644
--- a/include/linux/msm_tsens.h
+++ b/include/linux/msm_tsens.h
@@ -41,5 +41,10 @@
int32_t tsens_get_temp(struct tsens_device *dev, unsigned long *temp);
int msm_tsens_early_init(struct tsens_platform_data *pdata);
+#if defined(CONFIG_THERMAL_TSENS8974) || defined(CONFIG_THERMAL_TSENS8960)
int tsens_get_max_sensor_num(uint32_t *tsens_num_sensors);
+#else
+static inline int tsens_get_max_sensor_num(uint32_t *tsens_num_sensors)
+{ return -ENXIO; }
+#endif
#endif /*MSM_TSENS_H */