summaryrefslogtreecommitdiff
path: root/drivers/video/fbdev/xilinxfb.c
diff options
context:
space:
mode:
authorYang Li <yang.lee@linux.alibaba.com>2023-03-14 08:42:19 +0300
committerHelge Deller <deller@gmx.de>2023-03-14 20:49:40 +0300
commit4c7e8e05bca577380d03a2731a14b3cb5652b4f3 (patch)
treeb2ea1d833c2b9baaeff4175f5dde917ea0fe74b3 /drivers/video/fbdev/xilinxfb.c
parentbe66c2cbc05ed84821f3dde6439044ab44506525 (diff)
downloadlinux-4c7e8e05bca577380d03a2731a14b3cb5652b4f3.tar.xz
fbdev: xilinxfb: Use devm_platform_get_and_ioremap_resource()
According to commit 890cc39a8799 ("drivers: provide devm_platform_get_and_ioremap_resource()"), convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does. Signed-off-by: Yang Li <yang.lee@linux.alibaba.com> Signed-off-by: Helge Deller <deller@gmx.de>
Diffstat (limited to 'drivers/video/fbdev/xilinxfb.c')
-rw-r--r--drivers/video/fbdev/xilinxfb.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/video/fbdev/xilinxfb.c b/drivers/video/fbdev/xilinxfb.c
index c17cfffd9a84..7911354827dc 100644
--- a/drivers/video/fbdev/xilinxfb.c
+++ b/drivers/video/fbdev/xilinxfb.c
@@ -273,8 +273,7 @@ static int xilinxfb_assign(struct platform_device *pdev,
if (drvdata->flags & BUS_ACCESS_FLAG) {
struct resource *res;
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- drvdata->regs = devm_ioremap_resource(&pdev->dev, res);
+ drvdata->regs = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
if (IS_ERR(drvdata->regs))
return PTR_ERR(drvdata->regs);