summaryrefslogtreecommitdiff
path: root/drivers/media/platform/atmel
diff options
context:
space:
mode:
authorYangtao Li <frank.li@vivo.com>2023-07-06 18:10:49 +0800
committerHans Verkuil <hverkuil-cisco@xs4all.nl>2023-07-19 12:57:48 +0200
commit74db874ef577de97dc335d9ba85139ffacde8014 (patch)
treed112c9481c77ff66ddbe4bf9537c559174626922 /drivers/media/platform/atmel
parent7bf744f2de0a848fb1d717f5831b03db96feae89 (diff)
media: atmel-isi: Convert to devm_platform_ioremap_resource()
Use devm_platform_ioremap_resource() to simplify code. Signed-off-by: Yangtao Li <frank.li@vivo.com> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Diffstat (limited to 'drivers/media/platform/atmel')
-rw-r--r--drivers/media/platform/atmel/atmel-isi.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/media/platform/atmel/atmel-isi.c b/drivers/media/platform/atmel/atmel-isi.c
index c29e04864445..086353198d2a 100644
--- a/drivers/media/platform/atmel/atmel-isi.c
+++ b/drivers/media/platform/atmel/atmel-isi.c
@@ -1187,7 +1187,6 @@ static int atmel_isi_probe(struct platform_device *pdev)
int irq;
struct atmel_isi *isi;
struct vb2_queue *q;
- struct resource *regs;
int ret, i;
isi = devm_kzalloc(&pdev->dev, sizeof(struct atmel_isi), GFP_KERNEL);
@@ -1268,8 +1267,7 @@ static int atmel_isi_probe(struct platform_device *pdev)
list_add(&isi->dma_desc[i].list, &isi->dma_desc_head);
}
- regs = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- isi->regs = devm_ioremap_resource(&pdev->dev, regs);
+ isi->regs = devm_platform_ioremap_resource(pdev, 0);
if (IS_ERR(isi->regs)) {
ret = PTR_ERR(isi->regs);
goto err_ioremap;