Re: [PATCH] mfd: fix error check return value of platform_get_irq()

From: Lee Jones
Date: Tue Apr 26 2022 - 10:12:23 EST


On Tue, 12 Apr 2022, cgel.zte@xxxxxxxxx wrote:

> From: Lv Ruyi <lv.ruyi@xxxxxxxxxx>
>
> platform_get_irq() return negative value on failure, so null check of
> irq is incorrect. Fix it by comparing whether it is less than zero.
>
> Fixes: dcc21cc09e3c ("mfd: Add driver for Atmel Microcontroller on iPaq h3xxx")
> Reported-by: Zeal Robot <zealci@xxxxxxxxxx>
> Signed-off-by: Lv Ruyi <lv.ruyi@xxxxxxxxxx>
> ---
> drivers/mfd/ipaq-micro.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)

I fixed the subject line for you and applied, thanks.

--
Lee Jones [李琼斯]
Principal Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog