summaryrefslogtreecommitdiffstats
path: root/drivers/thermal/ti-soc-thermal/dra752-thermal-data.c
diff options
context:
space:
mode:
authorKeerthy <j-keerthy@ti.com>2015-04-22 18:21:41 +0530
committerEduardo Valentin <edubezval@gmail.com>2015-05-08 17:55:46 -0700
commit79010636174c78209e20c4f44370b2b13312e08c (patch)
tree02eb7bf5e3833df37a6e9179ebc8f13a31008bc9 /drivers/thermal/ti-soc-thermal/dra752-thermal-data.c
parent5ebe6afaf0057ac3eaeb98defd5456894b446d22 (diff)
downloadlinux-79010636174c78209e20c4f44370b2b13312e08c.tar.bz2
thermal: ti-soc-thermal: dra7: Implement Workaround for Errata i814
Bandgap Temperature read Dtemp can be corrupted DESCRIPTION Read accesses to registers listed below can be corrupted due to incorrect resynchronization between clock domains. Read access to registers below can be corrupted : • CTRL_CORE_DTEMP_MPU/GPU/CORE/DSPEVE/IVA_n (n = 0 to 4) • CTRL_CORE_TEMP_SENSOR_MPU/GPU/CORE/DSPEVE/IVA_n WORKAROUND Multiple reads to CTRL_CORE_TEMP_SENSOR_MPU/GPU/CORE/DSPEVE/IVA[9:0]: BGAP_DTEMPMPU/GPU/CORE/DSPEVE/IVA is needed to discard false value and read right value: 1. Perform two successive reads to BGAP_DTEMP bit field. (a) If read1 returns Val1 and read2 returns Val1, then right value is Val1. (b) If read1 returns Val1, read 2 returns Val2, a third read is needed. 2. Perform third read (a) If read3 returns Val2 then right value is Val2. (b) If read3 returns Val3, then right value is Val3. The above in gist means if val1 and val2 are the same then we can go ahead with that value else we need a third read which will be right since synchronization will be complete by then. Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
Diffstat (limited to 'drivers/thermal/ti-soc-thermal/dra752-thermal-data.c')
-rw-r--r--drivers/thermal/ti-soc-thermal/dra752-thermal-data.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/thermal/ti-soc-thermal/dra752-thermal-data.c b/drivers/thermal/ti-soc-thermal/dra752-thermal-data.c
index a4929272074f..58b5c6694cd4 100644
--- a/drivers/thermal/ti-soc-thermal/dra752-thermal-data.c
+++ b/drivers/thermal/ti-soc-thermal/dra752-thermal-data.c
@@ -420,7 +420,8 @@ const struct ti_bandgap_data dra752_data = {
TI_BANDGAP_FEATURE_FREEZE_BIT |
TI_BANDGAP_FEATURE_TALERT |
TI_BANDGAP_FEATURE_COUNTER_DELAY |
- TI_BANDGAP_FEATURE_HISTORY_BUFFER,
+ TI_BANDGAP_FEATURE_HISTORY_BUFFER |
+ TI_BANDGAP_FEATURE_ERRATA_814,
.fclock_name = "l3instr_ts_gclk_div",
.div_ck_name = "l3instr_ts_gclk_div",
.conv_table = dra752_adc_to_temp,