power: pm8921-charger: Enable wakeup interrupts BAT_TEMP_OK and VBATDET_LOW
Enabling the BAT_TEMP_OK and VBATDET_LOW as wakeup interrupts
allows charging to continue in specific use cases when system
is suspended, but a charger is available to charge. The
BAT_TEMP_OK interrupt will wake the device when the battery
has returned to a normal level to continue charging.
CRs-Fixed: 318417
Change-Id: If2a13204080c543f548be30ba4fa00f258d93547
Signed-off-by: David Keitel <dkeitel@codeaurora.org>
diff --git a/drivers/power/pm8921-charger.c b/drivers/power/pm8921-charger.c
index 6b05643..e908799 100644
--- a/drivers/power/pm8921-charger.c
+++ b/drivers/power/pm8921-charger.c
@@ -2783,6 +2783,8 @@
enable_irq_wake(chip->pmic_chg_irq[USBIN_VALID_IRQ]);
enable_irq_wake(chip->pmic_chg_irq[USBIN_OV_IRQ]);
enable_irq_wake(chip->pmic_chg_irq[USBIN_UV_IRQ]);
+ enable_irq_wake(chip->pmic_chg_irq[BAT_TEMP_OK_IRQ]);
+ enable_irq_wake(chip->pmic_chg_irq[VBATDET_LOW_IRQ]);
/*
* if both the cool_temp and warm_temp are zero the device doesnt
* care for jeita compliance