Skip to content

Commit 92ad897

Browse files
Yangtao Lidlezcano
authored andcommitted
thermal: sun8i: Add A100's THS controller support
This patch add thermal sensor controller support for A100, which is similar to the previous ones. Signed-off-by: Yangtao Li <frank@allwinnertech.com> Acked-by: Maxime Ripard <mripard@kernel.org> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/48cc75920b5c69027134626157089d8b94942711.1595572867.git.frank@allwinnertech.com
1 parent 771151b commit 92ad897

1 file changed

Lines changed: 14 additions & 0 deletions

File tree

drivers/thermal/sun8i_thermal.c

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -590,6 +590,19 @@ static const struct ths_thermal_chip sun50i_a64_ths = {
590590
.calc_temp = sun8i_ths_calc_temp,
591591
};
592592

593+
static const struct ths_thermal_chip sun50i_a100_ths = {
594+
.sensor_num = 3,
595+
.has_bus_clk_reset = true,
596+
.ft_deviation = 8000,
597+
.offset = 187744,
598+
.scale = 672,
599+
.temp_data_base = SUN50I_H6_THS_TEMP_DATA,
600+
.calibrate = sun50i_h6_ths_calibrate,
601+
.init = sun50i_h6_thermal_init,
602+
.irq_ack = sun50i_h6_irq_ack,
603+
.calc_temp = sun8i_ths_calc_temp,
604+
};
605+
593606
static const struct ths_thermal_chip sun50i_h5_ths = {
594607
.sensor_num = 2,
595608
.has_mod_clk = true,
@@ -619,6 +632,7 @@ static const struct of_device_id of_ths_match[] = {
619632
{ .compatible = "allwinner,sun8i-h3-ths", .data = &sun8i_h3_ths },
620633
{ .compatible = "allwinner,sun8i-r40-ths", .data = &sun8i_r40_ths },
621634
{ .compatible = "allwinner,sun50i-a64-ths", .data = &sun50i_a64_ths },
635+
{ .compatible = "allwinner,sun50i-a100-ths", .data = &sun50i_a100_ths },
622636
{ .compatible = "allwinner,sun50i-h5-ths", .data = &sun50i_h5_ths },
623637
{ .compatible = "allwinner,sun50i-h6-ths", .data = &sun50i_h6_ths },
624638
{ /* sentinel */ },

0 commit comments

Comments
 (0)