thermal/drivers/mediatek/auxadc_thermal: Removed call to platform_set_drvdata()
authorAndrei Coardos <aboutphysycs@gmail.com>
Fri, 11 Aug 2023 19:28:47 +0000 (22:28 +0300)
committerDaniel Lezcano <daniel.lezcano@linaro.org>
Wed, 16 Aug 2023 10:33:11 +0000 (12:33 +0200)
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
drivers/thermal/mediatek/auxadc_thermal.c

index c537aed7101778b6a43cbbd57d6ba8aebf54ac00..843214d30bd8b2e80037b28bfcb04169bb8e85aa 100644 (file)
@@ -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))