[PATCH v3] mailbox: mediatek: Fix handling of platform_get_irq() error

Krzysztof Kozlowski krzk at kernel.org
Fri Oct 2 12:30:00 EDT 2020


On Thu, Aug 27, 2020 at 08:25:07PM +0200, Krzysztof Kozlowski wrote:
> platform_get_irq() returns -ERRNO on error.  In such case casting to u32
> and comparing to 0 would pass the check.
> 
> Fixes: 623a6143a845 ("mailbox: mediatek: Add Mediatek CMDQ driver")
> Signed-off-by: Krzysztof Kozlowski <krzk at kernel.org>
> 
> ---
> 
> Changes since v2:
> 1. Fix subject.
> 
> Changes since v1:
> 1. Correct u32->int,
> 2. Fix left-over '!'.
> ---
>  drivers/mailbox/mtk-cmdq-mailbox.c | 8 +++-----
>  1 file changed, 3 insertions(+), 5 deletions(-)

Any comments here? This is a bugfix.

Best regards,
Krzysztof




More information about the linux-arm-kernel mailing list