Skip to content

Commit 5b5e17a

Browse files
miquelraynalEduardo Valentin
authored andcommitted
thermal: armada: dissociate a380 and cp110 ->init() hooks
Until now, Armada 380 and CP110 could share the same ->init() function because their use was identical. Prepare the support of multi-sensors support and overheat interrupt feature by separating the initialization paths before they actually diverge. Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
1 parent 8b4c271 commit 5b5e17a

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

drivers/thermal/armada_thermal.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,12 @@ static void armada_ap806_init(struct platform_device *pdev,
200200
armada_wait_sensor_validity(priv);
201201
}
202202

203+
static void armada_cp110_init(struct platform_device *pdev,
204+
struct armada_thermal_priv *priv)
205+
{
206+
armada380_init(pdev, priv);
207+
}
208+
203209
static bool armada_is_valid(struct armada_thermal_priv *priv)
204210
{
205211
u32 reg = readl_relaxed(priv->status);
@@ -306,7 +312,7 @@ static const struct armada_thermal_data armada_ap806_data = {
306312

307313
static const struct armada_thermal_data armada_cp110_data = {
308314
.is_valid = armada_is_valid,
309-
.init = armada380_init,
315+
.init = armada_cp110_init,
310316
.is_valid_bit = BIT(10),
311317
.temp_shift = 0,
312318
.temp_mask = 0x3ff,

0 commit comments

Comments
 (0)