Re: [PATCH] misc: atmel-ssc: fix error check return value of platform_get_irq()

From: Codrin.Ciubotariu
Date: Fri Apr 15 2022 - 02:47:45 EST


On 13.04.2022 12:32, cgel.zte@xxxxxxxxx wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
>
> From: Lv Ruyi <lv.ruyi@xxxxxxxxxx>
>
> platform_get_irq() return negative value on failure, so null check of
> ssc->irq is incorrect. Fix it by comparing whether it is less than zero.
>
> Reported-by: Zeal Robot <zealci@xxxxxxxxxx>
> Signed-off-by: Lv Ruyi <lv.ruyi@xxxxxxxxxx>

Reviewed-by: Codrin Ciubotariu <codrin.ciubotariu@xxxxxxxxxxxxx>

Thanks!