linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/3] video: exynos_mipi_dsi: Convert to devm_ioremap_resource()
@ 2013-01-31 10:25 Sachin Kamat
  2013-01-31 10:25 ` [PATCH 2/3] Input: tegra-kbc- " Sachin Kamat
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Sachin Kamat @ 2013-01-31 10:25 UTC (permalink / raw)
  To: linux-kernel
  Cc: thierry.reding, gregkh, sachin.kamat, Donghwa Lee,
	Florian Tobias Schandinat, linux-fbdev

Use the newly introduced devm_ioremap_resource() instead of
devm_request_and_ioremap() which provides more consistent error handling.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Donghwa Lee <dh09.lee@samsung.com>
Cc: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Cc: linux-fbdev@vger.kernel.org
---
 drivers/video/exynos/exynos_mipi_dsi.c |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/video/exynos/exynos_mipi_dsi.c b/drivers/video/exynos/exynos_mipi_dsi.c
index fac7df6..a29715f 100644
--- a/drivers/video/exynos/exynos_mipi_dsi.c
+++ b/drivers/video/exynos/exynos_mipi_dsi.c
@@ -32,6 +32,7 @@
 #include <linux/notifier.h>
 #include <linux/regulator/consumer.h>
 #include <linux/pm_runtime.h>
+#include <linux/err.h>
 
 #include <video/exynos_mipi_dsim.h>
 
@@ -384,10 +385,10 @@ static int exynos_mipi_dsi_probe(struct platform_device *pdev)
 
 	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
 
-	dsim->reg_base = devm_request_and_ioremap(&pdev->dev, res);
-	if (!dsim->reg_base) {
+	dsim->reg_base = devm_ioremap_resource(&pdev->dev, res);
+	if (IS_ERR(dsim->reg_base)) {
 		dev_err(&pdev->dev, "failed to remap io region\n");
-		ret = -ENOMEM;
+		ret = PTR_ERR(dsim->reg_base);
 		goto error;
 	}
 
-- 
1.7.4.1


^ permalink raw reply related	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2013-03-18  5:57 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-01-31 10:25 [PATCH 1/3] video: exynos_mipi_dsi: Convert to devm_ioremap_resource() Sachin Kamat
2013-01-31 10:25 ` [PATCH 2/3] Input: tegra-kbc- " Sachin Kamat
2013-01-31 10:25 ` [PATCH 3/3] serial: tegra: " Sachin Kamat
2013-01-31 17:00   ` Stephen Warren
2013-02-01  4:20     ` Sachin Kamat
2013-02-01  4:24       ` Stephen Warren
2013-02-01  9:49         ` Sachin Kamat
2013-02-01 17:18           ` Stephen Warren
     [not found]             ` <CAK9yfHx1jLPpdCHAb-pC-C7wt81gQLgTnpuvK+0aNKkhuXHcDQ@mail.gmail.com>
2013-03-15 16:38               ` gregkh
2013-03-15 17:14                 ` Stephen Warren
2013-03-15 17:33                   ` gregkh
2013-03-18  5:57                     ` Sachin Kamat
2013-01-31 10:42 ` [PATCH 1/3] video: exynos_mipi_dsi: " Thierry Reding
2013-01-31 11:20   ` Sachin Kamat

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).