* [PATCH] watchdog: at91rm9200: Correct check for syscon_node_to_regmap() errors
@ 2015-08-17 16:19 Bjorn Andersson
2015-08-17 16:33 ` Guenter Roeck
0 siblings, 1 reply; 2+ messages in thread
From: Bjorn Andersson @ 2015-08-17 16:19 UTC (permalink / raw)
To: Wim Van Sebroeck; +Cc: linux-watchdog, linux-kernel
syscon_node_to_regmap() returns a regmap or an ERR_PTR().
Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
---
drivers/watchdog/at91rm9200_wdt.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/watchdog/at91rm9200_wdt.c b/drivers/watchdog/at91rm9200_wdt.c
index 9ba1153465ae..e12a797cb820 100644
--- a/drivers/watchdog/at91rm9200_wdt.c
+++ b/drivers/watchdog/at91rm9200_wdt.c
@@ -244,7 +244,7 @@ static int at91wdt_probe(struct platform_device *pdev)
}
regmap_st = syscon_node_to_regmap(parent->of_node);
- if (!regmap_st)
+ if (IS_ERR(regmap_st))
return -ENODEV;
res = misc_register(&at91wdt_miscdev);
--
1.8.2.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] watchdog: at91rm9200: Correct check for syscon_node_to_regmap() errors
2015-08-17 16:19 [PATCH] watchdog: at91rm9200: Correct check for syscon_node_to_regmap() errors Bjorn Andersson
@ 2015-08-17 16:33 ` Guenter Roeck
0 siblings, 0 replies; 2+ messages in thread
From: Guenter Roeck @ 2015-08-17 16:33 UTC (permalink / raw)
To: Bjorn Andersson, Wim Van Sebroeck; +Cc: linux-watchdog, linux-kernel
On 08/17/2015 09:19 AM, Bjorn Andersson wrote:
> syscon_node_to_regmap() returns a regmap or an ERR_PTR().
>
> Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
Acked-by: Guenter Roeck <linux@roeck-us.net>
> ---
> drivers/watchdog/at91rm9200_wdt.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/watchdog/at91rm9200_wdt.c b/drivers/watchdog/at91rm9200_wdt.c
> index 9ba1153465ae..e12a797cb820 100644
> --- a/drivers/watchdog/at91rm9200_wdt.c
> +++ b/drivers/watchdog/at91rm9200_wdt.c
> @@ -244,7 +244,7 @@ static int at91wdt_probe(struct platform_device *pdev)
> }
>
> regmap_st = syscon_node_to_regmap(parent->of_node);
> - if (!regmap_st)
> + if (IS_ERR(regmap_st))
> return -ENODEV;
>
> res = misc_register(&at91wdt_miscdev);
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-08-17 16:33 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-17 16:19 [PATCH] watchdog: at91rm9200: Correct check for syscon_node_to_regmap() errors Bjorn Andersson
2015-08-17 16:33 ` Guenter Roeck
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox