power: supply: Fix use-after-free in power_supply_changed()
Status from this message: Applied, thanks!
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 Applied
Reviews trailers per patch
5 of 11 patches have a Reviewed-by or Acked-by.
| Patch | Nikita Travkin | Linus Walleij | Phil Reid | Samuel Kayode |
|---|---|---|---|---|
| 1/11 | R-b | |||
| 2/11 | ||||
| 3/11 | ||||
| 4/11 | ||||
| 5/11 | ||||
| 6/11 | ||||
| 7/11 | R-b | |||
| 8/11 | R-b | |||
| 9/11 | R-b | |||
| 10/11 | ||||
| 11/11 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 4 reviewers.
Cover letter [PATCH 00/11] power: supply: Fix use-after-free in power_supply_changed()
The majority of the drivers in drivers/power/supply/ do the right thing when registering an interrupt handler and the power_supply handle; namely making sure that the interrupt handler only runs while the power_supply handle is valid. The drivers in this patch series do not however. This can lead to a nasty use-after-free as thoroughly explained in the commit message.
These were identified by grepping for request.+irq and power_supply_changed\(, and then manually inspecting and fixing the affected ones. This issue was found when writing a new driver for the upcoming TI BQ25630 [1]. Patch adding support for that one will be sent as soon as TI releases the datasheet publicly, which should be anytime soon...
[1] https://www.ti.com/product/BQ25630
Waqar Hameed (11):
power: supply: ab8500: Fix use-after-free in power_supply_changed()
power: supply: act8945a: Fix use-after-free in power_supply_changed()
power: supply: bq256xx: Fix use-after-free in power_supply_changed()
power: supply: bq25980: Fix use-after-free in power_supply_changed()
power: supply: cpcap-battery: Fix use-after-free in
power_supply_changed()
power: supply: goldfish: Fix use-after-free in power_supply_changed()
power: supply: pf1550: Fix use-after-free in power_supply_changed()
power: supply: pm8916_bms_vm: Fix use-after-free in
power_supply_changed()
power: supply: pm8916_lbc: Fix use-after-free in
power_supply_changed()
power: supply: rt9455: Fix use-after-free in power_supply_changed()
power: supply: sbs-battery: Fix use-after-free in
power_supply_changed()
drivers/power/supply/ab8500_charger.c | 40 ++++++++++++------------- drivers/power/supply/act8945a_charger.c | 16 +++++----- drivers/power/supply/bq256xx_charger.c | 12 ++++---- drivers/power/supply/bq25980_charger.c | 12 ++++---- drivers/power/supply/cpcap-battery.c | 8 ++--- drivers/power/supply/goldfish_battery.c | 12 ++++---- drivers/power/supply/pf1550-charger.c | 32 ++++++++++---------- drivers/power/supply/pm8916_bms_vm.c | 18 +++++------ drivers/power/supply/pm8916_lbc.c | 18 +++++------ drivers/power/supply/rt9455_charger.c | 17 ++++++----- drivers/power/supply/sbs-battery.c | 36 +++++++++++----------- 11 files changed, 111 insertions(+), 110 deletions(-)
base-commit: fa084c35afa13ab07a860ef0936cd987f9aa0460
Signature · 1 line
2.39.5