[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <23ce10e4-bdb6-9b3a-465b-8ff86d679296@baylibre.com>
Date: Fri, 22 Apr 2022 18:22:24 +0200
From: Neil Armstrong <narmstrong@...libre.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
Daniel Lezcano <daniel.lezcano@...aro.org>,
Thomas Gleixner <tglx@...utronix.de>,
linux-kernel@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-oxnas@...ups.io
Subject: Re: [PATCH] clocksource/drivers/oxnas-rps: Fix irq_of_parse_and_map()
return value
On 22/04/2022 12:41, Krzysztof Kozlowski wrote:
> The irq_of_parse_and_map() returns 0 on failure, not a negative ERRNO.
>
> Fixes: 89355274e1f7 ("clocksource/drivers/oxnas-rps: Add Oxford Semiconductor RPS Dual Timer")
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
> ---
> drivers/clocksource/timer-oxnas-rps.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/clocksource/timer-oxnas-rps.c b/drivers/clocksource/timer-oxnas-rps.c
> index 56c0cc32d0ac..d514b44e67dd 100644
> --- a/drivers/clocksource/timer-oxnas-rps.c
> +++ b/drivers/clocksource/timer-oxnas-rps.c
> @@ -236,7 +236,7 @@ static int __init oxnas_rps_timer_init(struct device_node *np)
> }
>
> rps->irq = irq_of_parse_and_map(np, 0);
> - if (rps->irq < 0) {
> + if (!rps->irq) {
> ret = -EINVAL;
> goto err_iomap;
> }
Reviewed-by: Neil Armstrong <narmstrong@...libre.com>
Powered by blists - more mailing lists