mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2025-01-21 21:34:58 +08:00
mfd: ipaq-micro: Delete redundant return value check of platform_get_resource()
devm_ioremap_resource does checks on the resource. No need to duplicate this in the driver. Signed-off-by: Belén Sarabia <belensarabia@gmail.com> Signed-off-by: Lee Jones <lee.jones@linaro.org>
This commit is contained in:
parent
85fdaf8eb9
commit
119d53d44c
@ -400,9 +400,6 @@ static int __init micro_probe(struct platform_device *pdev)
|
|||||||
micro->dev = &pdev->dev;
|
micro->dev = &pdev->dev;
|
||||||
|
|
||||||
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
||||||
if (!res)
|
|
||||||
return -EINVAL;
|
|
||||||
|
|
||||||
micro->base = devm_ioremap_resource(&pdev->dev, res);
|
micro->base = devm_ioremap_resource(&pdev->dev, res);
|
||||||
if (IS_ERR(micro->base))
|
if (IS_ERR(micro->base))
|
||||||
return PTR_ERR(micro->base);
|
return PTR_ERR(micro->base);
|
||||||
|
Loading…
Reference in New Issue
Block a user