button: gpio: handle broken controller
authorCaleb Connolly <caleb.connolly@linaro.org>
Wed, 13 Nov 2024 04:59:24 +0000 (05:59 +0100)
committerTom Rini <trini@konsulko.com>
Wed, 4 Dec 2024 20:06:23 +0000 (14:06 -0600)
commit15299fa5dd8985759b705c7b06d7430924ba2407
tree67f07c7d2089715097addfcddbd5598b716c033d
parent893ae07cc9b0050d635aad704c1bdae41477734a
button: gpio: handle broken controller

Avoid crashing U-Boot when the GPIO controller for a button is disabled
or failed to probe. We also need to check the priv data for each button
since even if a button fails to probe it will still be polled by the
core code.

Signed-off-by: Caleb Connolly <caleb.connolly@linaro.org>
drivers/button/button-gpio.c