Skip to content

Commit

Permalink
thermal/drivers/mediatek/auxadc_thermal: Removed call to platform_set…
Browse files Browse the repository at this point in the history
…_drvdata()

This function call was found to be unnecessary as there is no equivalent
platform_get_drvdata() call to access the private data of the driver. Also,
the private data is defined in this driver, so there is no risk of it being
accessed outside of this driver file.

Signed-off-by: Andrei Coardos <aboutphysycs@gmail.com>
Reviewed-by: Alexandru Ardelean <alex@shruggie.ro>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20230811192847.3838-1-aboutphysycs@gmail.com
  • Loading branch information
Andrei Coardos authored and Daniel Lezcano committed Aug 16, 2023
1 parent f4636b5 commit ec6a519
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions drivers/thermal/mediatek/auxadc_thermal.c
Original file line number Diff line number Diff line change
Expand Up @@ -1282,8 +1282,6 @@ static int mtk_thermal_probe(struct platform_device *pdev)
mtk_thermal_init_bank(mt, i, apmixed_phys_base,
auxadc_phys_base, ctrl_id);

platform_set_drvdata(pdev, mt);

tzdev = devm_thermal_of_zone_register(&pdev->dev, 0, mt,
&mtk_thermal_ops);
if (IS_ERR(tzdev))
Expand Down

0 comments on commit ec6a519

Please sign in to comment.