[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210811061053.32081-1-tony@atomide.com>
Date: Wed, 11 Aug 2021 09:10:53 +0300
From: Tony Lindgren <tony@...mide.com>
To: linux-omap@...r.kernel.org
Cc: Dave Gerlach <d-gerlach@...com>, Faiz Abbas <faiz_abbas@...com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Grygorii Strashko <grygorii.strashko@...com>,
Keerthy <j-keerthy@...com>, Nishanth Menon <nm@...com>,
Suman Anna <s-anna@...com>, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, Pavel Machek <pavel@...x.de>,
Jarkko Nikula <jarkko.nikula@...mer.com>
Subject: [PATCH] bus: ti-sysc: Fix error handling for sysc_check_active_timer()
We have changed the return type for sysc_check_active_timer() from -EBUSY
to -ENXIO, but the gpt12 system timer fix still checks for -EBUSY. We are
also not returning on other errors like we did earlier as noted by
Pavel Machek <pavel@...x.de>.
Commit 3ff340e24c9d ("bus: ti-sysc: Fix gpt12 system timer issue with
reserved status") should have been updated for commit 65fb73676112
("bus: ti-sysc: suppress err msg for timers used as clockevent/source").
Let's fix the issue by checking for -ENXIO and returning on any other
errors as suggested by Pavel Machek <pavel@...x.de>.
Fixes: 3ff340e24c9d ("bus: ti-sysc: Fix gpt12 system timer issue with reserved status")
Depends-on: 65fb73676112 ("bus: ti-sysc: suppress err msg for timers used as clockevent/source")
Reported-by: Pavel Machek <pavel@...x.de>
Cc: Grygorii Strashko <grygorii.strashko@...com>
Cc: Jarkko Nikula <jarkko.nikula@...mer.com>
Signed-off-by: Tony Lindgren <tony@...mide.com>
---
drivers/bus/ti-sysc.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/bus/ti-sysc.c b/drivers/bus/ti-sysc.c
--- a/drivers/bus/ti-sysc.c
+++ b/drivers/bus/ti-sysc.c
@@ -3097,8 +3097,10 @@ static int sysc_probe(struct platform_device *pdev)
return error;
error = sysc_check_active_timer(ddata);
- if (error == -EBUSY)
+ if (error == -ENXIO)
ddata->reserved = true;
+ else if (error)
+ return error;
error = sysc_get_clocks(ddata);
if (error)
--
2.32.0
Powered by blists - more mailing lists