[PATCH 2/3] soc: mediatek: mutex: Drop empty platform remove function

Uwe Kleine-König posted 3 patches 1 year, 9 months ago
[PATCH 2/3] soc: mediatek: mutex: Drop empty platform remove function
Posted by Uwe Kleine-König 1 year, 9 months ago
A remove callback just returning 0 is equivalent to no remove callback
at all. So drop the useless function.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
 drivers/soc/mediatek/mtk-mutex.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/soc/mediatek/mtk-mutex.c b/drivers/soc/mediatek/mtk-mutex.c
index c1a33d52038e..85f7fd67d7c6 100644
--- a/drivers/soc/mediatek/mtk-mutex.c
+++ b/drivers/soc/mediatek/mtk-mutex.c
@@ -832,11 +832,6 @@ static int mtk_mutex_probe(struct platform_device *pdev)
 	return 0;
 }
 
-static int mtk_mutex_remove(struct platform_device *pdev)
-{
-	return 0;
-}
-
 static const struct of_device_id mutex_driver_dt_match[] = {
 	{ .compatible = "mediatek,mt2701-disp-mutex",
 	  .data = &mt2701_mutex_driver_data},
@@ -866,7 +861,6 @@ MODULE_DEVICE_TABLE(of, mutex_driver_dt_match);
 
 static struct platform_driver mtk_mutex_driver = {
 	.probe		= mtk_mutex_probe,
-	.remove		= mtk_mutex_remove,
 	.driver		= {
 		.name	= "mediatek-mutex",
 		.owner	= THIS_MODULE,
-- 
2.38.1

Re: [PATCH 2/3] soc: mediatek: mutex: Drop empty platform remove function
Posted by AngeloGioacchino Del Regno 1 year, 9 months ago
Il 12/12/22 23:25, Uwe Kleine-König ha scritto:
> A remove callback just returning 0 is equivalent to no remove callback
> at all. So drop the useless function.
> 
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

Totally agree.

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>

Re: [PATCH 2/3] soc: mediatek: mutex: Drop empty platform remove function
Posted by Matthias Brugger 1 year, 9 months ago

On 13/12/2022 10:50, AngeloGioacchino Del Regno wrote:
> Il 12/12/22 23:25, Uwe Kleine-König ha scritto:
>> A remove callback just returning 0 is equivalent to no remove callback
>> at all. So drop the useless function.
>>
>> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> 
> Totally agree.
> 
> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> 

Applied thanks