mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-03 17:14:14 +08:00
fbdev: s3c-fb: use devm_platform_ioremap_resource() to simplify code
Use devm_platform_ioremap_resource() to simplify the code a bit. This is detected by coccinelle. Reported-by: Hulk Robot <hulkci@huawei.com> Signed-off-by: YueHaibing <yuehaibing@huawei.com> Acked-by: Jingoo Han <jingoohan1@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> Link: https://patchwork.freedesktop.org/patch/msgid/20190904115523.25068-1-yuehaibing@huawei.com
This commit is contained in:
parent
1d47d0bb72
commit
8d5598f13f
@ -1411,8 +1411,7 @@ static int s3c_fb_probe(struct platform_device *pdev)
|
||||
|
||||
pm_runtime_enable(sfb->dev);
|
||||
|
||||
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
||||
sfb->regs = devm_ioremap_resource(dev, res);
|
||||
sfb->regs = devm_platform_ioremap_resource(pdev, 0);
|
||||
if (IS_ERR(sfb->regs)) {
|
||||
ret = PTR_ERR(sfb->regs);
|
||||
goto err_lcd_clk;
|
||||
|
Loading…
Reference in New Issue
Block a user