summaryrefslogtreecommitdiff
path: root/arch/mips/pci/pci-ar71xx.c
diff options
context:
space:
mode:
authorSilviu-Mihai Popescu <silviupopescu1990@gmail.com>2013-03-12 14:30:05 +0400
committerRalf Baechle <ralf@linux-mips.org>2013-05-08 03:19:07 +0400
commitf560fabdf3f3fe12bd48146a6ccdf03ddf9ab12c (patch)
tree4f3d0c50732a107a36a6e02240b7d2f9cec4d83b /arch/mips/pci/pci-ar71xx.c
parent301896513971d41d737c904ecf267b6f0ea21d55 (diff)
downloadlinux-f560fabdf3f3fe12bd48146a6ccdf03ddf9ab12c.tar.xz
MIPS: pci: convert to devm_ioremap_resource()
Convert all uses of devm_request_and_ioremap() to the newly introduced devm_ioremap_resource() which provides more consistent error handling. Signed-off-by: Silviu-Mihai Popescu <silviupopescu1990@gmail.com> Patchwork: http://patchwork.linux-mips.org/patch/4986/ Acked-by: John Crispin <blogic@openwrt.org>
Diffstat (limited to 'arch/mips/pci/pci-ar71xx.c')
-rw-r--r--arch/mips/pci/pci-ar71xx.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/mips/pci/pci-ar71xx.c b/arch/mips/pci/pci-ar71xx.c
index 412ec025cf55..18517dd0f709 100644
--- a/arch/mips/pci/pci-ar71xx.c
+++ b/arch/mips/pci/pci-ar71xx.c
@@ -366,9 +366,9 @@ static int ar71xx_pci_probe(struct platform_device *pdev)
if (!res)
return -EINVAL;
- apc->cfg_base = devm_request_and_ioremap(&pdev->dev, res);
- if (!apc->cfg_base)
- return -ENOMEM;
+ apc->cfg_base = devm_ioremap_resource(&pdev->dev, res);
+ if (IS_ERR(apc->cfg_base))
+ return PTR_ERR(apc->cfg_base);
apc->irq = platform_get_irq(pdev, 0);
if (apc->irq < 0)