[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1363015477-29685-1-git-send-email-silviupopescu1990@gmail.com>
Date: Mon, 11 Mar 2013 17:24:37 +0200
From: Silviu-Mihai Popescu <silviupopescu1990@...il.com>
To: linux-mips@...ux-mips.org
Cc: ralf@...ux-mips.org, juhosg@...nwrt.org, blogic@...nwrt.org,
kaloz@...nwrt.org, linux-kernel@...r.kernel.org,
Silviu-Mihai Popescu <silviupopescu1990@...il.com>
Subject: [PATCH] pci: use newly introduced devm_ioremap_resource()
Convert all uses of devm_request_and_ioremap() to the newly introduced
devm_ioremap_resource() which provides more consistent error handling.
devm_ioremap_resource() provides its own error messages so all explicit
error messages can be removed from the failure code paths.
Signed-off-by: Silviu-Mihai Popescu <silviupopescu1990@...il.com>
---
arch/mips/pci/pci-ar71xx.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/arch/mips/pci/pci-ar71xx.c b/arch/mips/pci/pci-ar71xx.c
index 412ec02..18517dd 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)
--
1.7.9.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists