* [PATCH -next] watchdog: rt2880_wdt: fix return value check in rt288x_wdt_probe()
@ 2013-10-31 7:50 Wei Yongjun
2013-10-31 16:30 ` Wim Van Sebroeck
0 siblings, 1 reply; 2+ messages in thread
From: Wei Yongjun @ 2013-10-31 7:50 UTC (permalink / raw)
To: wim, grant.likely, rob.herring; +Cc: yongjun_wei, linux-watchdog
From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
In case of error, the function devm_request_and_ioremap() returns NULL
pointer not ERR_PTR(). Fix it by using devm_ioremap_resource() instead
of devm_request_and_ioremap().
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
---
drivers/watchdog/rt2880_wdt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/watchdog/rt2880_wdt.c b/drivers/watchdog/rt2880_wdt.c
index a9f8491..53d37fe 100644
--- a/drivers/watchdog/rt2880_wdt.c
+++ b/drivers/watchdog/rt2880_wdt.c
@@ -144,7 +144,7 @@ static int rt288x_wdt_probe(struct platform_device *pdev)
int ret;
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- rt288x_wdt_base = devm_request_and_ioremap(&pdev->dev, res);
+ rt288x_wdt_base = devm_ioremap_resource(&pdev->dev, res);
if (IS_ERR(rt288x_wdt_base))
return PTR_ERR(rt288x_wdt_base);
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH -next] watchdog: rt2880_wdt: fix return value check in rt288x_wdt_probe()
2013-10-31 7:50 [PATCH -next] watchdog: rt2880_wdt: fix return value check in rt288x_wdt_probe() Wei Yongjun
@ 2013-10-31 16:30 ` Wim Van Sebroeck
0 siblings, 0 replies; 2+ messages in thread
From: Wim Van Sebroeck @ 2013-10-31 16:30 UTC (permalink / raw)
To: Wei Yongjun; +Cc: grant.likely, rob.herring, yongjun_wei, linux-watchdog
Hi Wei,
> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
>
> In case of error, the function devm_request_and_ioremap() returns NULL
> pointer not ERR_PTR(). Fix it by using devm_ioremap_resource() instead
> of devm_request_and_ioremap().
>
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> ---
> drivers/watchdog/rt2880_wdt.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/watchdog/rt2880_wdt.c b/drivers/watchdog/rt2880_wdt.c
> index a9f8491..53d37fe 100644
> --- a/drivers/watchdog/rt2880_wdt.c
> +++ b/drivers/watchdog/rt2880_wdt.c
> @@ -144,7 +144,7 @@ static int rt288x_wdt_probe(struct platform_device *pdev)
> int ret;
>
> res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> - rt288x_wdt_base = devm_request_and_ioremap(&pdev->dev, res);
> + rt288x_wdt_base = devm_ioremap_resource(&pdev->dev, res);
> if (IS_ERR(rt288x_wdt_base))
> return PTR_ERR(rt288x_wdt_base);
>
Patch added to linux-watchdog-next.
Kind regards,
Wim.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-10-31 16:30 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-10-31 7:50 [PATCH -next] watchdog: rt2880_wdt: fix return value check in rt288x_wdt_probe() Wei Yongjun
2013-10-31 16:30 ` Wim Van Sebroeck
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.