public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [patch] clocksource: timer-imx-gpt: make driver work again
@ 2016-06-16 10:42 Dan Carpenter
  2016-06-16 11:04 ` Daniel Lezcano
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2016-06-16 10:42 UTC (permalink / raw)
  To: Daniel Lezcano; +Cc: Thomas Gleixner, linux-kernel, kernel-janitors

We accidentally made mxc_timer_init_dt() return unconditionally.

Fixes: e93432390ec1 ('clocksource/drivers/timer-imx-gpt: Convert init function to return error')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>

diff --git a/drivers/clocksource/timer-imx-gpt.c b/drivers/clocksource/timer-imx-gpt.c
index 5f64dff..f595460 100644
--- a/drivers/clocksource/timer-imx-gpt.c
+++ b/drivers/clocksource/timer-imx-gpt.c
@@ -485,7 +485,8 @@ static int __init mxc_timer_init_dt(struct device_node *np,  enum imx_gpt_type t
 		return 0;
 
 	imxtm = kzalloc(sizeof(*imxtm), GFP_KERNEL);
-	return -ENOMEM;
+	if (!imxtm)
+		return -ENOMEM;
 
 	imxtm->base = of_iomap(np, 0);
 	if (!imxtm->base)

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

* Re: [patch] clocksource: timer-imx-gpt: make driver work again
  2016-06-16 10:42 [patch] clocksource: timer-imx-gpt: make driver work again Dan Carpenter
@ 2016-06-16 11:04 ` Daniel Lezcano
  0 siblings, 0 replies; 2+ messages in thread
From: Daniel Lezcano @ 2016-06-16 11:04 UTC (permalink / raw)
  To: Dan Carpenter; +Cc: Thomas Gleixner, linux-kernel, kernel-janitors

On 06/16/2016 12:42 PM, Dan Carpenter wrote:
> We accidentally made mxc_timer_init_dt() return unconditionally.
>
> Fixes: e93432390ec1 ('clocksource/drivers/timer-imx-gpt: Convert init function to return error')
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
>

Thanks, I will merge this change with the commit e93432390ec1.

   -- Daniel

-- 
  <http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs

Follow Linaro:  <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog

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

end of thread, other threads:[~2016-06-16 11:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-06-16 10:42 [patch] clocksource: timer-imx-gpt: make driver work again Dan Carpenter
2016-06-16 11:04 ` Daniel Lezcano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox