Commit 23ee0f19 authored by Colin Ian King's avatar Colin Ian King Committed by Linus Walleij
Browse files

pinctrl: actions: fix unsigned less than zero comparison

The check to see if platform_get_irq failed is performed on the
unsigned value of pctrl->irq[i] and the check is never true because
an unsigned cannot be less than zero.  Fix this by assinging the
signed int ret to the return of platform_get_irq and checking ret
instead.

Detected by CoverityScan, CID#1470247 ("Unsigned comparison against 0")

Fixes: 6c5d0736

 ("pinctrl: actions: Add interrupt support for OWL S900 SoC")
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Acked-by: default avatarManivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent 875a92b3
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment