mirror of
https://github.com/LineageOS/android_kernel_samsung_msm8226.git
synced 2026-09-29 00:00:25 +02:00
The current code does not start the unplug check worker if dc path is used. This is because it assumes an external charger for the DC path. Reorganize the DC insertion handler to check whether an external charger is used. If not, call the unplug check worker since we are running in a configuration where the DC path on pm8921 charger is used. Also update the code such that hkadc calibration is called when a dc charger is plugged in, similar to when the usb charger is plugged in. This is to avoid inaccuracies because of shifts in MBG when a charger (either DC or USB) is inserted. CRs-Fixed: 403147 Change-Id: I11a17fc105dea398140abc1a59e6355e9e55b322 Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>