Skip to content
Commit f4f95adf authored by Dan Carpenter's avatar Dan Carpenter Committed by Anton Vorontsov
Browse files

da9052-battery: Don't free IRQ that wasn't requested



We should decrement "i" before doing the free_irq().  If we call this
because request_threaded_irq() failed then we don't want to free the
thing which failed.  Or in the case where we get here because
power_supply_register() failed then the original codes does a read past
the end of the array.

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarAnton Vorontsov <anton.vorontsov@linaro.org>
parent a22b41a3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment