[PATCH next] power: supply: fix a double free on error in probe()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



In this code, if devm_add_action_or_reset() fails, it will call
max1720x_unregister_ancillary() which in turn calls
i2c_unregister_device().  Thus the call to i2c_unregister_device() on the
following line is not required and is a double unregister.  Delete it.

Fixes: 47271a935619 ("power: supply: max1720x: add read support for nvmem")
Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
---

[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux