diff options
-rw-r--r-- | drivers/thermal/samsung/exynos_tmu.c | 276 | ||||
-rw-r--r-- | drivers/thermal/samsung/exynos_tmu.h | 5 | ||||
-rw-r--r-- | drivers/thermal/samsung/exynos_tmu_data.c | 11 |
3 files changed, 159 insertions, 133 deletions
diff --git a/drivers/thermal/samsung/exynos_tmu.c b/drivers/thermal/samsung/exynos_tmu.c index 6e82fdd860b0..736ef7885878 100644 --- a/drivers/thermal/samsung/exynos_tmu.c +++ b/drivers/thermal/samsung/exynos_tmu.c | |||
@@ -52,6 +52,7 @@ | |||
52 | * @temp_error2: fused value of the second point trim. | 52 | * @temp_error2: fused value of the second point trim. |
53 | * @regulator: pointer to the TMU regulator structure. | 53 | * @regulator: pointer to the TMU regulator structure. |
54 | * @reg_conf: pointer to structure to register with core thermal. | 54 | * @reg_conf: pointer to structure to register with core thermal. |
55 | * @tmu_initialize: SoC specific TMU initialization method | ||
55 | */ | 56 | */ |
56 | struct exynos_tmu_data { | 57 | struct exynos_tmu_data { |
57 | int id; | 58 | int id; |
@@ -66,6 +67,7 @@ struct exynos_tmu_data { | |||
66 | u8 temp_error1, temp_error2; | 67 | u8 temp_error1, temp_error2; |
67 | struct regulator *regulator; | 68 | struct regulator *regulator; |
68 | struct thermal_sensor_conf *reg_conf; | 69 | struct thermal_sensor_conf *reg_conf; |
70 | int (*tmu_initialize)(struct platform_device *pdev); | ||
69 | }; | 71 | }; |
70 | 72 | ||
71 | /* | 73 | /* |
@@ -180,118 +182,13 @@ static u32 get_th_reg(struct exynos_tmu_data *data, u32 threshold, bool falling) | |||
180 | static int exynos_tmu_initialize(struct platform_device *pdev) | 182 | static int exynos_tmu_initialize(struct platform_device *pdev) |
181 | { | 183 | { |
182 | struct exynos_tmu_data *data = platform_get_drvdata(pdev); | 184 | struct exynos_tmu_data *data = platform_get_drvdata(pdev); |
183 | struct exynos_tmu_platform_data *pdata = data->pdata; | 185 | int ret; |
184 | const struct exynos_tmu_registers *reg = pdata->registers; | ||
185 | unsigned int status, trim_info = 0, con, ctrl; | ||
186 | unsigned int rising_threshold = 0, falling_threshold = 0; | ||
187 | int ret = 0, threshold_code, i; | ||
188 | 186 | ||
189 | mutex_lock(&data->lock); | 187 | mutex_lock(&data->lock); |
190 | clk_enable(data->clk); | 188 | clk_enable(data->clk); |
191 | if (!IS_ERR(data->clk_sec)) | 189 | if (!IS_ERR(data->clk_sec)) |
192 | clk_enable(data->clk_sec); | 190 | clk_enable(data->clk_sec); |
193 | 191 | ret = data->tmu_initialize(pdev); | |
194 | if (data->soc != SOC_ARCH_EXYNOS5440) { | ||
195 | status = readb(data->base + EXYNOS_TMU_REG_STATUS); | ||
196 | if (!status) { | ||
197 | ret = -EBUSY; | ||
198 | goto out; | ||
199 | } | ||
200 | } | ||
201 | |||
202 | if (data->soc == SOC_ARCH_EXYNOS3250 || | ||
203 | data->soc == SOC_ARCH_EXYNOS4412 || | ||
204 | data->soc == SOC_ARCH_EXYNOS5250) { | ||
205 | if (data->soc == SOC_ARCH_EXYNOS3250) { | ||
206 | ctrl = readl(data->base + EXYNOS_TMU_TRIMINFO_CON1); | ||
207 | ctrl |= EXYNOS_TRIMINFO_RELOAD_ENABLE; | ||
208 | writel(ctrl, data->base + EXYNOS_TMU_TRIMINFO_CON1); | ||
209 | } | ||
210 | ctrl = readl(data->base + EXYNOS_TMU_TRIMINFO_CON2); | ||
211 | ctrl |= EXYNOS_TRIMINFO_RELOAD_ENABLE; | ||
212 | writel(ctrl, data->base + EXYNOS_TMU_TRIMINFO_CON2); | ||
213 | } | ||
214 | |||
215 | /* Save trimming info in order to perform calibration */ | ||
216 | if (data->soc == SOC_ARCH_EXYNOS5440) { | ||
217 | /* | ||
218 | * For exynos5440 soc triminfo value is swapped between TMU0 and | ||
219 | * TMU2, so the below logic is needed. | ||
220 | */ | ||
221 | switch (data->id) { | ||
222 | case 0: | ||
223 | trim_info = readl(data->base + | ||
224 | EXYNOS5440_EFUSE_SWAP_OFFSET + EXYNOS5440_TMU_S0_7_TRIM); | ||
225 | break; | ||
226 | case 1: | ||
227 | trim_info = readl(data->base + EXYNOS5440_TMU_S0_7_TRIM); | ||
228 | break; | ||
229 | case 2: | ||
230 | trim_info = readl(data->base - | ||
231 | EXYNOS5440_EFUSE_SWAP_OFFSET + EXYNOS5440_TMU_S0_7_TRIM); | ||
232 | } | ||
233 | } else { | ||
234 | /* On exynos5420 the triminfo register is in the shared space */ | ||
235 | if (data->soc == SOC_ARCH_EXYNOS5420_TRIMINFO) | ||
236 | trim_info = readl(data->base_second + | ||
237 | EXYNOS_TMU_REG_TRIMINFO); | ||
238 | else | ||
239 | trim_info = readl(data->base + EXYNOS_TMU_REG_TRIMINFO); | ||
240 | } | ||
241 | sanitize_temp_error(data, trim_info); | ||
242 | |||
243 | if (data->soc == SOC_ARCH_EXYNOS4210) { | ||
244 | /* Write temperature code for threshold */ | ||
245 | threshold_code = temp_to_code(data, pdata->threshold); | ||
246 | writeb(threshold_code, | ||
247 | data->base + EXYNOS4210_TMU_REG_THRESHOLD_TEMP); | ||
248 | for (i = 0; i < pdata->non_hw_trigger_levels; i++) | ||
249 | writeb(pdata->trigger_levels[i], data->base + | ||
250 | reg->threshold_th0 + i * sizeof(reg->threshold_th0)); | ||
251 | |||
252 | exynos_tmu_clear_irqs(data); | ||
253 | } else { | ||
254 | /* Write temperature code for rising and falling threshold */ | ||
255 | rising_threshold = readl(data->base + reg->threshold_th0); | ||
256 | rising_threshold = get_th_reg(data, rising_threshold, false); | ||
257 | if (data->soc != SOC_ARCH_EXYNOS5440) | ||
258 | falling_threshold = get_th_reg(data, 0, true); | ||
259 | |||
260 | writel(rising_threshold, | ||
261 | data->base + reg->threshold_th0); | ||
262 | writel(falling_threshold, | ||
263 | data->base + reg->threshold_th1); | ||
264 | |||
265 | exynos_tmu_clear_irqs(data); | ||
266 | |||
267 | /* if last threshold limit is also present */ | ||
268 | i = pdata->max_trigger_level - 1; | ||
269 | if (pdata->trigger_levels[i] && | ||
270 | (pdata->trigger_type[i] == HW_TRIP)) { | ||
271 | threshold_code = temp_to_code(data, | ||
272 | pdata->trigger_levels[i]); | ||
273 | if (data->soc != SOC_ARCH_EXYNOS5440) { | ||
274 | /* 1-4 level to be assigned in th0 reg */ | ||
275 | rising_threshold &= ~(0xff << 8 * i); | ||
276 | rising_threshold |= threshold_code << 8 * i; | ||
277 | writel(rising_threshold, | ||
278 | data->base + EXYNOS_THD_TEMP_RISE); | ||
279 | } else { | ||
280 | /* 5th level to be assigned in th2 reg */ | ||
281 | rising_threshold = | ||
282 | threshold_code << EXYNOS5440_TMU_TH_RISE4_SHIFT; | ||
283 | writel(rising_threshold, | ||
284 | data->base + EXYNOS5440_TMU_S0_7_TH2); | ||
285 | } | ||
286 | con = readl(data->base + reg->tmu_ctrl); | ||
287 | con |= (1 << EXYNOS_TMU_THERM_TRIP_EN_SHIFT); | ||
288 | writel(con, data->base + reg->tmu_ctrl); | ||
289 | } | ||
290 | } | ||
291 | /*Clear the PMIN in the common TMU register*/ | ||
292 | if (data->soc == SOC_ARCH_EXYNOS5440 && !data->id) | ||
293 | writel(0, data->base_second + EXYNOS5440_TMU_PMIN); | ||
294 | out: | ||
295 | clk_disable(data->clk); | 192 | clk_disable(data->clk); |
296 | mutex_unlock(&data->lock); | 193 | mutex_unlock(&data->lock); |
297 | if (!IS_ERR(data->clk_sec)) | 194 | if (!IS_ERR(data->clk_sec)) |
@@ -347,6 +244,143 @@ static void exynos_tmu_control(struct platform_device *pdev, bool on) | |||
347 | mutex_unlock(&data->lock); | 244 | mutex_unlock(&data->lock); |
348 | } | 245 | } |
349 | 246 | ||
247 | static int exynos4210_tmu_initialize(struct platform_device *pdev) | ||
248 | { | ||
249 | struct exynos_tmu_data *data = platform_get_drvdata(pdev); | ||
250 | struct exynos_tmu_platform_data *pdata = data->pdata; | ||
251 | unsigned int status; | ||
252 | int ret = 0, threshold_code, i; | ||
253 | |||
254 | status = readb(data->base + EXYNOS_TMU_REG_STATUS); | ||
255 | if (!status) { | ||
256 | ret = -EBUSY; | ||
257 | goto out; | ||
258 | } | ||
259 | |||
260 | sanitize_temp_error(data, readl(data->base + EXYNOS_TMU_REG_TRIMINFO)); | ||
261 | |||
262 | /* Write temperature code for threshold */ | ||
263 | threshold_code = temp_to_code(data, pdata->threshold); | ||
264 | writeb(threshold_code, data->base + EXYNOS4210_TMU_REG_THRESHOLD_TEMP); | ||
265 | |||
266 | for (i = 0; i < pdata->non_hw_trigger_levels; i++) | ||
267 | writeb(pdata->trigger_levels[i], data->base + | ||
268 | EXYNOS4210_TMU_REG_TRIG_LEVEL0 + i * 4); | ||
269 | |||
270 | exynos_tmu_clear_irqs(data); | ||
271 | out: | ||
272 | return ret; | ||
273 | } | ||
274 | |||
275 | static int exynos4412_tmu_initialize(struct platform_device *pdev) | ||
276 | { | ||
277 | struct exynos_tmu_data *data = platform_get_drvdata(pdev); | ||
278 | struct exynos_tmu_platform_data *pdata = data->pdata; | ||
279 | unsigned int status, trim_info, con, ctrl, rising_threshold; | ||
280 | int ret = 0, threshold_code, i; | ||
281 | |||
282 | status = readb(data->base + EXYNOS_TMU_REG_STATUS); | ||
283 | if (!status) { | ||
284 | ret = -EBUSY; | ||
285 | goto out; | ||
286 | } | ||
287 | |||
288 | if (data->soc == SOC_ARCH_EXYNOS3250 || | ||
289 | data->soc == SOC_ARCH_EXYNOS4412 || | ||
290 | data->soc == SOC_ARCH_EXYNOS5250) { | ||
291 | if (data->soc == SOC_ARCH_EXYNOS3250) { | ||
292 | ctrl = readl(data->base + EXYNOS_TMU_TRIMINFO_CON1); | ||
293 | ctrl |= EXYNOS_TRIMINFO_RELOAD_ENABLE; | ||
294 | writel(ctrl, data->base + EXYNOS_TMU_TRIMINFO_CON1); | ||
295 | } | ||
296 | ctrl = readl(data->base + EXYNOS_TMU_TRIMINFO_CON2); | ||
297 | ctrl |= EXYNOS_TRIMINFO_RELOAD_ENABLE; | ||
298 | writel(ctrl, data->base + EXYNOS_TMU_TRIMINFO_CON2); | ||
299 | } | ||
300 | |||
301 | /* On exynos5420 the triminfo register is in the shared space */ | ||
302 | if (data->soc == SOC_ARCH_EXYNOS5420_TRIMINFO) | ||
303 | trim_info = readl(data->base_second + EXYNOS_TMU_REG_TRIMINFO); | ||
304 | else | ||
305 | trim_info = readl(data->base + EXYNOS_TMU_REG_TRIMINFO); | ||
306 | |||
307 | sanitize_temp_error(data, trim_info); | ||
308 | |||
309 | /* Write temperature code for rising and falling threshold */ | ||
310 | rising_threshold = readl(data->base + EXYNOS_THD_TEMP_RISE); | ||
311 | rising_threshold = get_th_reg(data, rising_threshold, false); | ||
312 | writel(rising_threshold, data->base + EXYNOS_THD_TEMP_RISE); | ||
313 | writel(get_th_reg(data, 0, true), data->base + EXYNOS_THD_TEMP_FALL); | ||
314 | |||
315 | exynos_tmu_clear_irqs(data); | ||
316 | |||
317 | /* if last threshold limit is also present */ | ||
318 | i = pdata->max_trigger_level - 1; | ||
319 | if (pdata->trigger_levels[i] && pdata->trigger_type[i] == HW_TRIP) { | ||
320 | threshold_code = temp_to_code(data, pdata->trigger_levels[i]); | ||
321 | /* 1-4 level to be assigned in th0 reg */ | ||
322 | rising_threshold &= ~(0xff << 8 * i); | ||
323 | rising_threshold |= threshold_code << 8 * i; | ||
324 | writel(rising_threshold, data->base + EXYNOS_THD_TEMP_RISE); | ||
325 | con = readl(data->base + EXYNOS_TMU_REG_CONTROL); | ||
326 | con |= (1 << EXYNOS_TMU_THERM_TRIP_EN_SHIFT); | ||
327 | writel(con, data->base + EXYNOS_TMU_REG_CONTROL); | ||
328 | } | ||
329 | out: | ||
330 | return ret; | ||
331 | } | ||
332 | |||
333 | static int exynos5440_tmu_initialize(struct platform_device *pdev) | ||
334 | { | ||
335 | struct exynos_tmu_data *data = platform_get_drvdata(pdev); | ||
336 | struct exynos_tmu_platform_data *pdata = data->pdata; | ||
337 | unsigned int trim_info = 0, con, rising_threshold; | ||
338 | int ret = 0, threshold_code, i; | ||
339 | |||
340 | /* | ||
341 | * For exynos5440 soc triminfo value is swapped between TMU0 and | ||
342 | * TMU2, so the below logic is needed. | ||
343 | */ | ||
344 | switch (data->id) { | ||
345 | case 0: | ||
346 | trim_info = readl(data->base + EXYNOS5440_EFUSE_SWAP_OFFSET + | ||
347 | EXYNOS5440_TMU_S0_7_TRIM); | ||
348 | break; | ||
349 | case 1: | ||
350 | trim_info = readl(data->base + EXYNOS5440_TMU_S0_7_TRIM); | ||
351 | break; | ||
352 | case 2: | ||
353 | trim_info = readl(data->base - EXYNOS5440_EFUSE_SWAP_OFFSET + | ||
354 | EXYNOS5440_TMU_S0_7_TRIM); | ||
355 | } | ||
356 | sanitize_temp_error(data, trim_info); | ||
357 | |||
358 | /* Write temperature code for rising and falling threshold */ | ||
359 | rising_threshold = readl(data->base + EXYNOS5440_TMU_S0_7_TH0); | ||
360 | rising_threshold = get_th_reg(data, rising_threshold, false); | ||
361 | writel(rising_threshold, data->base + EXYNOS5440_TMU_S0_7_TH0); | ||
362 | writel(0, data->base + EXYNOS5440_TMU_S0_7_TH1); | ||
363 | |||
364 | exynos_tmu_clear_irqs(data); | ||
365 | |||
366 | /* if last threshold limit is also present */ | ||
367 | i = pdata->max_trigger_level - 1; | ||
368 | if (pdata->trigger_levels[i] && pdata->trigger_type[i] == HW_TRIP) { | ||
369 | threshold_code = temp_to_code(data, pdata->trigger_levels[i]); | ||
370 | /* 5th level to be assigned in th2 reg */ | ||
371 | rising_threshold = | ||
372 | threshold_code << EXYNOS5440_TMU_TH_RISE4_SHIFT; | ||
373 | writel(rising_threshold, data->base + EXYNOS5440_TMU_S0_7_TH2); | ||
374 | con = readl(data->base + EXYNOS5440_TMU_S0_7_CTRL); | ||
375 | con |= (1 << EXYNOS_TMU_THERM_TRIP_EN_SHIFT); | ||
376 | writel(con, data->base + EXYNOS5440_TMU_S0_7_CTRL); | ||
377 | } | ||
378 | /* Clear the PMIN in the common TMU register */ | ||
379 | if (!data->id) | ||
380 | writel(0, data->base_second + EXYNOS5440_TMU_PMIN); | ||
381 | return ret; | ||
382 | } | ||
383 | |||
350 | static int exynos_tmu_read(struct exynos_tmu_data *data) | 384 | static int exynos_tmu_read(struct exynos_tmu_data *data) |
351 | { | 385 | { |
352 | struct exynos_tmu_platform_data *pdata = data->pdata; | 386 | struct exynos_tmu_platform_data *pdata = data->pdata; |
@@ -639,16 +673,24 @@ static int exynos_tmu_probe(struct platform_device *pdev) | |||
639 | goto err_clk_sec; | 673 | goto err_clk_sec; |
640 | } | 674 | } |
641 | 675 | ||
642 | if (pdata->type == SOC_ARCH_EXYNOS3250 || | 676 | data->soc = pdata->type; |
643 | pdata->type == SOC_ARCH_EXYNOS4210 || | 677 | |
644 | pdata->type == SOC_ARCH_EXYNOS4412 || | 678 | switch (data->soc) { |
645 | pdata->type == SOC_ARCH_EXYNOS5250 || | 679 | case SOC_ARCH_EXYNOS4210: |
646 | pdata->type == SOC_ARCH_EXYNOS5260 || | 680 | data->tmu_initialize = exynos4210_tmu_initialize; |
647 | pdata->type == SOC_ARCH_EXYNOS5420 || | 681 | break; |
648 | pdata->type == SOC_ARCH_EXYNOS5420_TRIMINFO || | 682 | case SOC_ARCH_EXYNOS3250: |
649 | pdata->type == SOC_ARCH_EXYNOS5440) | 683 | case SOC_ARCH_EXYNOS4412: |
650 | data->soc = pdata->type; | 684 | case SOC_ARCH_EXYNOS5250: |
651 | else { | 685 | case SOC_ARCH_EXYNOS5260: |
686 | case SOC_ARCH_EXYNOS5420: | ||
687 | case SOC_ARCH_EXYNOS5420_TRIMINFO: | ||
688 | data->tmu_initialize = exynos4412_tmu_initialize; | ||
689 | break; | ||
690 | case SOC_ARCH_EXYNOS5440: | ||
691 | data->tmu_initialize = exynos5440_tmu_initialize; | ||
692 | break; | ||
693 | default: | ||
652 | ret = -EINVAL; | 694 | ret = -EINVAL; |
653 | dev_err(&pdev->dev, "Platform not supported\n"); | 695 | dev_err(&pdev->dev, "Platform not supported\n"); |
654 | goto err_clk; | 696 | goto err_clk; |
diff --git a/drivers/thermal/samsung/exynos_tmu.h b/drivers/thermal/samsung/exynos_tmu.h index adecc7ff5b8a..f186f4ff44c4 100644 --- a/drivers/thermal/samsung/exynos_tmu.h +++ b/drivers/thermal/samsung/exynos_tmu.h | |||
@@ -73,8 +73,6 @@ enum soc_type { | |||
73 | * slightly across different exynos SOC's. | 73 | * slightly across different exynos SOC's. |
74 | * @tmu_ctrl: TMU main controller register. | 74 | * @tmu_ctrl: TMU main controller register. |
75 | * @tmu_cur_temp: register containing the current temperature of the TMU. | 75 | * @tmu_cur_temp: register containing the current temperature of the TMU. |
76 | * @threshold_th0: Register containing first set of rising levels. | ||
77 | * @threshold_th1: Register containing second set of rising levels. | ||
78 | * @tmu_inten: register containing the different threshold interrupt | 76 | * @tmu_inten: register containing the different threshold interrupt |
79 | enable bits. | 77 | enable bits. |
80 | * @inten_rise0_shift: shift bits of rising 0 interrupt bits. | 78 | * @inten_rise0_shift: shift bits of rising 0 interrupt bits. |
@@ -91,9 +89,6 @@ struct exynos_tmu_registers { | |||
91 | 89 | ||
92 | u32 tmu_cur_temp; | 90 | u32 tmu_cur_temp; |
93 | 91 | ||
94 | u32 threshold_th0; | ||
95 | u32 threshold_th1; | ||
96 | |||
97 | u32 tmu_inten; | 92 | u32 tmu_inten; |
98 | u32 inten_rise0_shift; | 93 | u32 inten_rise0_shift; |
99 | u32 inten_rise1_shift; | 94 | u32 inten_rise1_shift; |
diff --git a/drivers/thermal/samsung/exynos_tmu_data.c b/drivers/thermal/samsung/exynos_tmu_data.c index 1ed8bdc117a0..db3b3bc53f76 100644 --- a/drivers/thermal/samsung/exynos_tmu_data.c +++ b/drivers/thermal/samsung/exynos_tmu_data.c | |||
@@ -28,7 +28,6 @@ | |||
28 | static const struct exynos_tmu_registers exynos4210_tmu_registers = { | 28 | static const struct exynos_tmu_registers exynos4210_tmu_registers = { |
29 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, | 29 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, |
30 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, | 30 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, |
31 | .threshold_th0 = EXYNOS4210_TMU_REG_TRIG_LEVEL0, | ||
32 | .tmu_inten = EXYNOS_TMU_REG_INTEN, | 31 | .tmu_inten = EXYNOS_TMU_REG_INTEN, |
33 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, | 32 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, |
34 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, | 33 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, |
@@ -83,8 +82,6 @@ struct exynos_tmu_init_data const exynos4210_default_tmu_data = { | |||
83 | static const struct exynos_tmu_registers exynos3250_tmu_registers = { | 82 | static const struct exynos_tmu_registers exynos3250_tmu_registers = { |
84 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, | 83 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, |
85 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, | 84 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, |
86 | .threshold_th0 = EXYNOS_THD_TEMP_RISE, | ||
87 | .threshold_th1 = EXYNOS_THD_TEMP_FALL, | ||
88 | .tmu_inten = EXYNOS_TMU_REG_INTEN, | 85 | .tmu_inten = EXYNOS_TMU_REG_INTEN, |
89 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, | 86 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, |
90 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, | 87 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, |
@@ -152,8 +149,6 @@ struct exynos_tmu_init_data const exynos3250_default_tmu_data = { | |||
152 | static const struct exynos_tmu_registers exynos4412_tmu_registers = { | 149 | static const struct exynos_tmu_registers exynos4412_tmu_registers = { |
153 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, | 150 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, |
154 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, | 151 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, |
155 | .threshold_th0 = EXYNOS_THD_TEMP_RISE, | ||
156 | .threshold_th1 = EXYNOS_THD_TEMP_FALL, | ||
157 | .tmu_inten = EXYNOS_TMU_REG_INTEN, | 152 | .tmu_inten = EXYNOS_TMU_REG_INTEN, |
158 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, | 153 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, |
159 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, | 154 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, |
@@ -234,8 +229,6 @@ struct exynos_tmu_init_data const exynos5250_default_tmu_data = { | |||
234 | static const struct exynos_tmu_registers exynos5260_tmu_registers = { | 229 | static const struct exynos_tmu_registers exynos5260_tmu_registers = { |
235 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, | 230 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, |
236 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, | 231 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, |
237 | .threshold_th0 = EXYNOS_THD_TEMP_RISE, | ||
238 | .threshold_th1 = EXYNOS_THD_TEMP_FALL, | ||
239 | .tmu_inten = EXYNOS5260_TMU_REG_INTEN, | 232 | .tmu_inten = EXYNOS5260_TMU_REG_INTEN, |
240 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, | 233 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, |
241 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, | 234 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, |
@@ -306,8 +299,6 @@ struct exynos_tmu_init_data const exynos5260_default_tmu_data = { | |||
306 | static const struct exynos_tmu_registers exynos5420_tmu_registers = { | 299 | static const struct exynos_tmu_registers exynos5420_tmu_registers = { |
307 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, | 300 | .tmu_ctrl = EXYNOS_TMU_REG_CONTROL, |
308 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, | 301 | .tmu_cur_temp = EXYNOS_TMU_REG_CURRENT_TEMP, |
309 | .threshold_th0 = EXYNOS_THD_TEMP_RISE, | ||
310 | .threshold_th1 = EXYNOS_THD_TEMP_FALL, | ||
311 | .tmu_inten = EXYNOS_TMU_REG_INTEN, | 302 | .tmu_inten = EXYNOS_TMU_REG_INTEN, |
312 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, | 303 | .inten_rise0_shift = EXYNOS_TMU_INTEN_RISE0_SHIFT, |
313 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, | 304 | .inten_rise1_shift = EXYNOS_TMU_INTEN_RISE1_SHIFT, |
@@ -385,8 +376,6 @@ struct exynos_tmu_init_data const exynos5420_default_tmu_data = { | |||
385 | static const struct exynos_tmu_registers exynos5440_tmu_registers = { | 376 | static const struct exynos_tmu_registers exynos5440_tmu_registers = { |
386 | .tmu_ctrl = EXYNOS5440_TMU_S0_7_CTRL, | 377 | .tmu_ctrl = EXYNOS5440_TMU_S0_7_CTRL, |
387 | .tmu_cur_temp = EXYNOS5440_TMU_S0_7_TEMP, | 378 | .tmu_cur_temp = EXYNOS5440_TMU_S0_7_TEMP, |
388 | .threshold_th0 = EXYNOS5440_TMU_S0_7_TH0, | ||
389 | .threshold_th1 = EXYNOS5440_TMU_S0_7_TH1, | ||
390 | .tmu_inten = EXYNOS5440_TMU_S0_7_IRQEN, | 379 | .tmu_inten = EXYNOS5440_TMU_S0_7_IRQEN, |
391 | .inten_rise0_shift = EXYNOS5440_TMU_INTEN_RISE0_SHIFT, | 380 | .inten_rise0_shift = EXYNOS5440_TMU_INTEN_RISE0_SHIFT, |
392 | .inten_rise1_shift = EXYNOS5440_TMU_INTEN_RISE1_SHIFT, | 381 | .inten_rise1_shift = EXYNOS5440_TMU_INTEN_RISE1_SHIFT, |