power: regulator: lp87565: Cannot test unsigned for being negative
authorAndrew Goodbody <andrew.goodbody@linaro.org>
Thu, 7 Aug 2025 16:35:19 +0000 (17:35 +0100)
committerTom Rini <trini@konsulko.com>
Fri, 29 Aug 2025 22:45:19 +0000 (16:45 -0600)
commit8f90028ccdbfc74487c4b40bd6fe5d34c3309b7a
treeb96fdb18f695a4f458f9ada3e431234134b5e351
parent42f959d0b091b779f235d7d0e54a794d4d857917
power: regulator: lp87565: Cannot test unsigned for being negative

In lp87565_buck_val hex is an unsigned variable being assigned the return
value from a function that returns int. Change hex to be an int so that
the following test for an error as a negative value will work as expected.

This issue was found by Smatch.

Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org>
Reviewed-by: Frieder Schrempf <frieder.schrempf@kontron.de>
drivers/power/regulator/lp87565_regulator.c