mirror of
https://github.com/LineageOS/android_kernel_samsung_msm8226.git
synced 2026-10-12 00:00:44 +02:00
Allow the pm8921-charger driver to initiate charging on a registered 3rd party charging driver through the power supply class. Also enable the maintenance of charging properties such as online and charge type using the power supply class rather than directly depending on the 3rd party driver. When a external charger is registered using power_supply_register the external_power_changed callback of the charger driver checks for an external charger named "dc". This removes the dependency of a 3rd party charger to call directly into the charger driver. Also, update the isl9519q driver to reflect the changes and utilize power supply class calls to enable charging on the isl chip from PM8921 charger driver. This serves as an example for other 3rd party external chargers supporting PMIC with high current charging. Finally, add pr_fmt macro which automatically adds function name to print statements and remove __func__ from individual print statements. Change-Id: If05e598be260d924ec3263bad33317cf4e7543a1 Signed-off-by: David Keitel <dkeitel@codeaurora.org>