diff options
author | Thierry Reding <thierry.reding@avionic-design.de> | 2013-01-21 11:08:56 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-01-25 12:21:45 -0800 |
commit | 7c390a7e956b4bf7b7d6dba4dfb93299c4f0879a (patch) | |
tree | b7ea5ba40b42106a5f3106ff55e576b083f14bf6 /arch/mips/lantiq/xway/dma.c | |
parent | 5857bd98dbd0080e6b27b51087cc9ec24f426e8b (diff) | |
download | blackbird-obmc-linux-7c390a7e956b4bf7b7d6dba4dfb93299c4f0879a.tar.gz blackbird-obmc-linux-7c390a7e956b4bf7b7d6dba4dfb93299c4f0879a.zip |
MIPS: 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.
devm_ioremap_resource() provides its own error messages so all explicit
error messages can be removed from the failure code paths.
Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/mips/lantiq/xway/dma.c')
-rw-r--r-- | arch/mips/lantiq/xway/dma.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/mips/lantiq/xway/dma.c b/arch/mips/lantiq/xway/dma.c index e44a1866653f..08f7ebd9c774 100644 --- a/arch/mips/lantiq/xway/dma.c +++ b/arch/mips/lantiq/xway/dma.c @@ -21,6 +21,7 @@ #include <linux/dma-mapping.h> #include <linux/module.h> #include <linux/clk.h> +#include <linux/err.h> #include <lantiq_soc.h> #include <xway_dma.h> @@ -223,8 +224,8 @@ ltq_dma_init(struct platform_device *pdev) panic("Failed to get dma resource"); /* remap dma register range */ - ltq_dma_membase = devm_request_and_ioremap(&pdev->dev, res); - if (!ltq_dma_membase) + ltq_dma_membase = devm_ioremap_resource(&pdev->dev, res); + if (IS_ERR(ltq_dma_membase)) panic("Failed to remap dma resource"); /* power up and reset the dma engine */ |