diff mbox series

drm/mediatek: Convert to use devm_platform_ioremap_resource

Message ID 20250128094118.1526-1-oushixiong1025@163.com (mailing list archive)
State New
Headers show
Series drm/mediatek: Convert to use devm_platform_ioremap_resource | expand

Commit Message

Shixiong Ou Jan. 28, 2025, 9:41 a.m. UTC
From: Shixiong Ou <oushixiong@kylinos.cn>

Do not need to get resource, so convert to use
devm_platform_ioremap_resource.

Signed-off-by: Shixiong Ou <oushixiong@kylinos.cn>
---
 drivers/gpu/drm/mediatek/mtk_padding.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/drivers/gpu/drm/mediatek/mtk_padding.c b/drivers/gpu/drm/mediatek/mtk_padding.c
index b4e3e5a3428b..7e302724e74a 100644
--- a/drivers/gpu/drm/mediatek/mtk_padding.c
+++ b/drivers/gpu/drm/mediatek/mtk_padding.c
@@ -95,7 +95,6 @@  static int mtk_padding_probe(struct platform_device *pdev)
 {
 	struct device *dev = &pdev->dev;
 	struct mtk_padding *priv;
-	struct resource *res;
 	int ret;
 
 	priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL);
@@ -107,7 +106,7 @@  static int mtk_padding_probe(struct platform_device *pdev)
 		return dev_err_probe(dev, PTR_ERR(priv->clk),
 				     "failed to get clk\n");
 
-	priv->reg = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
+	priv->reg = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(priv->reg))
 		return dev_err_probe(dev, PTR_ERR(priv->reg),
 				     "failed to do ioremap\n");