summaryrefslogtreecommitdiffstats
path: root/lib/swiotlb.c
diff options
context:
space:
mode:
authorKrzysztof Kozlowski <k.kozlowski@samsung.com>2015-02-20 14:32:22 +0100
committerSebastian Reichel <sre@kernel.org>2015-02-25 22:18:18 +0100
commit68c3ed6fa7e0d69529ced772d650ab128916a81d (patch)
tree1f6cf0b960169927fe87debf42ed2aac325bf5dc /lib/swiotlb.c
parentcc6405667c633383cf9365731ad91e8a88d39b89 (diff)
downloadop-kernel-dev-68c3ed6fa7e0d69529ced772d650ab128916a81d.zip
op-kernel-dev-68c3ed6fa7e0d69529ced772d650ab128916a81d.tar.gz
power_supply: twl4030_madc: Check return value of power_supply_register
The return value of power_supply_register() call was not checked and even on error probe() function returned 0. If registering failed then during unbind the driver tried to unregister power supply which was not actually registered. This could lead to memory corruption because power_supply_unregister() unconditionally cleans up given power supply. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Fixes: da0a00ebc239 ("power: Add twl4030_madc battery driver.") Cc: <stable@vger.kernel.org> Signed-off-by: Sebastian Reichel <sre@kernel.org>
Diffstat (limited to 'lib/swiotlb.c')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud