]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
max17042: propagate of_node to power supply device
authorPierre Bourdon <delroth@google.com>
Tue, 20 Feb 2018 15:03:18 +0000 (16:03 +0100)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Mon, 27 Aug 2018 14:40:05 +0000 (16:40 +0200)
commita592e54ae4c29856958dbee6a3e8a39a8c1db4bd
tree910ce40d30d89a30bf849add3357c5c53f89e043
parentfcb3f8a63eebdddc782cac98d7881836344fc5b7
max17042: propagate of_node to power supply device

BugLink: http://bugs.launchpad.net/bugs/1786352
[ Upstream commit 66ec32fc7cd116dab5c02603ea8ec28ff92da3b5 ]

max17042_get_status uses the core power_supply_am_i_supplied. That
function relies on DT properties to figure out the power supply
topology, and will error out without DT.

Fixes max17042 battery status being reported as "unknown".

Signed-off-by: Pierre Bourdon <delroth@google.com>
Signed-off-by: Andre Heider <a.heider@gmail.com>
Signed-off-by: Sebastian Reichel <sebastian.reichel@collabora.co.uk>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/power/supply/max17042_battery.c