Skip to content

Commit d3bff62

Browse files
committed
Merge branch 'thermal-misc'
Merge thermal control changes related to switching over platform drivers to using void remove callbacks. * thermal-misc: (31 commits) thermal: amlogic: Convert to platform remove callback returning void thermal: uniphier: Convert to platform remove callback returning void thermal: ti-bandgap: Convert to platform remove callback returning void thermal: tegra-bpmp: Convert to platform remove callback returning void thermal: soctherm: Convert to platform remove callback returning void thermal: stm: Convert to platform remove callback returning void thermal: sprd: Convert to platform remove callback returning void thermal: spear: Convert to platform remove callback returning void thermal: exynos_tmu: Convert to platform remove callback returning void thermal: rzg2l: Convert to platform remove callback returning void thermal: rockchip: Convert to platform remove callback returning void thermal: rcar: Convert to platform remove callback returning void thermal: rcar_gen3: Convert to platform remove callback returning void thermal: tsens: Convert to platform remove callback returning void thermal: lvts: Convert to platform remove callback returning void thermal: kirkwood: Convert to platform remove callback returning void thermal: k3_j72xx_bandgap: Convert to platform remove callback returning void thermal: k3_bandgap: Convert to platform remove callback returning void thermal: int3406: Convert to platform remove callback returning void thermal: int3403: Convert to platform remove callback returning void ...
2 parents c996260 + eea6c26 commit d3bff62

31 files changed

+64
-120
lines changed

drivers/thermal/amlogic_thermal.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -291,11 +291,11 @@ static int amlogic_thermal_probe(struct platform_device *pdev)
291291
return ret;
292292
}
293293

294-
static int amlogic_thermal_remove(struct platform_device *pdev)
294+
static void amlogic_thermal_remove(struct platform_device *pdev)
295295
{
296296
struct amlogic_thermal *data = platform_get_drvdata(pdev);
297297

298-
return amlogic_thermal_disable(data);
298+
amlogic_thermal_disable(data);
299299
}
300300

301301
static int __maybe_unused amlogic_thermal_suspend(struct device *dev)
@@ -321,8 +321,8 @@ static struct platform_driver amlogic_thermal_driver = {
321321
.pm = &amlogic_thermal_pm_ops,
322322
.of_match_table = of_amlogic_thermal_match,
323323
},
324-
.probe = amlogic_thermal_probe,
325-
.remove = amlogic_thermal_remove,
324+
.probe = amlogic_thermal_probe,
325+
.remove_new = amlogic_thermal_remove,
326326
};
327327

328328
module_platform_driver(amlogic_thermal_driver);

drivers/thermal/armada_thermal.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -965,19 +965,17 @@ static int armada_thermal_probe(struct platform_device *pdev)
965965
return 0;
966966
}
967967

968-
static int armada_thermal_exit(struct platform_device *pdev)
968+
static void armada_thermal_exit(struct platform_device *pdev)
969969
{
970970
struct armada_drvdata *drvdata = platform_get_drvdata(pdev);
971971

972972
if (drvdata->type == LEGACY)
973973
thermal_zone_device_unregister(drvdata->data.tz);
974-
975-
return 0;
976974
}
977975

978976
static struct platform_driver armada_thermal_driver = {
979977
.probe = armada_thermal_probe,
980-
.remove = armada_thermal_exit,
978+
.remove_new = armada_thermal_exit,
981979
.driver = {
982980
.name = "armada_thermal",
983981
.of_match_table = armada_thermal_id_table,

drivers/thermal/broadcom/bcm2835_thermal.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -282,19 +282,17 @@ static int bcm2835_thermal_probe(struct platform_device *pdev)
282282
return err;
283283
}
284284

285-
static int bcm2835_thermal_remove(struct platform_device *pdev)
285+
static void bcm2835_thermal_remove(struct platform_device *pdev)
286286
{
287287
struct bcm2835_thermal_data *data = platform_get_drvdata(pdev);
288288

289289
debugfs_remove_recursive(data->debugfsdir);
290290
clk_disable_unprepare(data->clk);
291-
292-
return 0;
293291
}
294292

295293
static struct platform_driver bcm2835_thermal_driver = {
296294
.probe = bcm2835_thermal_probe,
297-
.remove = bcm2835_thermal_remove,
295+
.remove_new = bcm2835_thermal_remove,
298296
.driver = {
299297
.name = "bcm2835_thermal",
300298
.of_match_table = bcm2835_thermal_of_match_table,

drivers/thermal/broadcom/ns-thermal.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -65,13 +65,11 @@ static int ns_thermal_probe(struct platform_device *pdev)
6565
return 0;
6666
}
6767

68-
static int ns_thermal_remove(struct platform_device *pdev)
68+
static void ns_thermal_remove(struct platform_device *pdev)
6969
{
7070
void __iomem *pvtmon = platform_get_drvdata(pdev);
7171

7272
iounmap(pvtmon);
73-
74-
return 0;
7573
}
7674

7775
static const struct of_device_id ns_thermal_of_match[] = {
@@ -82,7 +80,7 @@ MODULE_DEVICE_TABLE(of, ns_thermal_of_match);
8280

8381
static struct platform_driver ns_thermal_driver = {
8482
.probe = ns_thermal_probe,
85-
.remove = ns_thermal_remove,
83+
.remove_new = ns_thermal_remove,
8684
.driver = {
8785
.name = "ns-thermal",
8886
.of_match_table = ns_thermal_of_match,

drivers/thermal/da9062-thermal.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -239,19 +239,18 @@ static int da9062_thermal_probe(struct platform_device *pdev)
239239
return ret;
240240
}
241241

242-
static int da9062_thermal_remove(struct platform_device *pdev)
242+
static void da9062_thermal_remove(struct platform_device *pdev)
243243
{
244244
struct da9062_thermal *thermal = platform_get_drvdata(pdev);
245245

246246
free_irq(thermal->irq, thermal);
247247
cancel_delayed_work_sync(&thermal->work);
248248
thermal_zone_device_unregister(thermal->zone);
249-
return 0;
250249
}
251250

252251
static struct platform_driver da9062_thermal_driver = {
253252
.probe = da9062_thermal_probe,
254-
.remove = da9062_thermal_remove,
253+
.remove_new = da9062_thermal_remove,
255254
.driver = {
256255
.name = "da9062-thermal",
257256
.of_match_table = da9062_compatible_reg_id_table,

drivers/thermal/dove_thermal.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -158,21 +158,19 @@ static int dove_thermal_probe(struct platform_device *pdev)
158158
return 0;
159159
}
160160

161-
static int dove_thermal_exit(struct platform_device *pdev)
161+
static void dove_thermal_exit(struct platform_device *pdev)
162162
{
163163
struct thermal_zone_device *dove_thermal =
164164
platform_get_drvdata(pdev);
165165

166166
thermal_zone_device_unregister(dove_thermal);
167-
168-
return 0;
169167
}
170168

171169
MODULE_DEVICE_TABLE(of, dove_thermal_id_table);
172170

173171
static struct platform_driver dove_thermal_driver = {
174172
.probe = dove_thermal_probe,
175-
.remove = dove_thermal_exit,
173+
.remove_new = dove_thermal_exit,
176174
.driver = {
177175
.name = "dove_thermal",
178176
.of_match_table = dove_thermal_id_table,

drivers/thermal/hisi_thermal.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -597,7 +597,7 @@ static int hisi_thermal_probe(struct platform_device *pdev)
597597
return 0;
598598
}
599599

600-
static int hisi_thermal_remove(struct platform_device *pdev)
600+
static void hisi_thermal_remove(struct platform_device *pdev)
601601
{
602602
struct hisi_thermal_data *data = platform_get_drvdata(pdev);
603603
int i;
@@ -608,8 +608,6 @@ static int hisi_thermal_remove(struct platform_device *pdev)
608608
hisi_thermal_toggle_sensor(sensor, false);
609609
data->ops->disable_sensor(sensor);
610610
}
611-
612-
return 0;
613611
}
614612

615613
static int hisi_thermal_suspend(struct device *dev)
@@ -644,7 +642,7 @@ static struct platform_driver hisi_thermal_driver = {
644642
.of_match_table = of_hisi_thermal_match,
645643
},
646644
.probe = hisi_thermal_probe,
647-
.remove = hisi_thermal_remove,
645+
.remove_new = hisi_thermal_remove,
648646
};
649647

650648
module_platform_driver(hisi_thermal_driver);

drivers/thermal/imx8mm_thermal.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,7 @@ static int imx8mm_tmu_probe(struct platform_device *pdev)
363363
return ret;
364364
}
365365

366-
static int imx8mm_tmu_remove(struct platform_device *pdev)
366+
static void imx8mm_tmu_remove(struct platform_device *pdev)
367367
{
368368
struct imx8mm_tmu *tmu = platform_get_drvdata(pdev);
369369

@@ -372,8 +372,6 @@ static int imx8mm_tmu_remove(struct platform_device *pdev)
372372

373373
clk_disable_unprepare(tmu->clk);
374374
platform_set_drvdata(pdev, NULL);
375-
376-
return 0;
377375
}
378376

379377
static struct thermal_soc_data imx8mm_tmu_data = {
@@ -401,7 +399,7 @@ static struct platform_driver imx8mm_tmu = {
401399
.of_match_table = imx8mm_tmu_table,
402400
},
403401
.probe = imx8mm_tmu_probe,
404-
.remove = imx8mm_tmu_remove,
402+
.remove_new = imx8mm_tmu_remove,
405403
};
406404
module_platform_driver(imx8mm_tmu);
407405

drivers/thermal/imx_thermal.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -771,7 +771,7 @@ static int imx_thermal_probe(struct platform_device *pdev)
771771
return ret;
772772
}
773773

774-
static int imx_thermal_remove(struct platform_device *pdev)
774+
static void imx_thermal_remove(struct platform_device *pdev)
775775
{
776776
struct imx_thermal_data *data = platform_get_drvdata(pdev);
777777

@@ -780,8 +780,6 @@ static int imx_thermal_remove(struct platform_device *pdev)
780780

781781
thermal_zone_device_unregister(data->tz);
782782
imx_thermal_unregister_legacy_cooling(data);
783-
784-
return 0;
785783
}
786784

787785
static int __maybe_unused imx_thermal_suspend(struct device *dev)
@@ -880,7 +878,7 @@ static struct platform_driver imx_thermal = {
880878
.of_match_table = of_imx_thermal_match,
881879
},
882880
.probe = imx_thermal_probe,
883-
.remove = imx_thermal_remove,
881+
.remove_new = imx_thermal_remove,
884882
};
885883
module_platform_driver(imx_thermal);
886884

drivers/thermal/intel/int340x_thermal/int3400_thermal.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -674,7 +674,7 @@ static int int3400_thermal_probe(struct platform_device *pdev)
674674
return result;
675675
}
676676

677-
static int int3400_thermal_remove(struct platform_device *pdev)
677+
static void int3400_thermal_remove(struct platform_device *pdev)
678678
{
679679
struct int3400_thermal_priv *priv = platform_get_drvdata(pdev);
680680

@@ -698,7 +698,6 @@ static int int3400_thermal_remove(struct platform_device *pdev)
698698
kfree(priv->trts);
699699
kfree(priv->arts);
700700
kfree(priv);
701-
return 0;
702701
}
703702

704703
static const struct acpi_device_id int3400_thermal_match[] = {
@@ -714,7 +713,7 @@ MODULE_DEVICE_TABLE(acpi, int3400_thermal_match);
714713

715714
static struct platform_driver int3400_thermal_driver = {
716715
.probe = int3400_thermal_probe,
717-
.remove = int3400_thermal_remove,
716+
.remove_new = int3400_thermal_remove,
718717
.driver = {
719718
.name = "int3400 thermal",
720719
.acpi_match_table = ACPI_PTR(int3400_thermal_match),

0 commit comments

Comments
 (0)