mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-10 14:19:09 -04:00
charging: enable irq wake up
when system suspend and then inserted charger, the system can't wake up and update charger info. Change-Id: Idb69dfc330b93d5929ce1b10b5c95491d6997aff Signed-off-by: mahj8 <mahj8@motorola.com> Reviewed-on: https://gerrit.mot.com/2155893 SME-Granted: SME Approvals Granted SLTApproved: Slta Waiver Tested-by: Jira Key Reviewed-by: Huosheng Liao <liaohs@motorola.com> Submit-Approved: Jira Key
This commit is contained in:
parent
ffbae57032
commit
c73d42c876
1 changed files with 12 additions and 7 deletions
|
|
@ -2710,13 +2710,18 @@ static int bq2589x_charger_probe(struct i2c_client *client,
|
|||
goto err_irq;
|
||||
}
|
||||
|
||||
ret = devm_request_threaded_irq(dev, client->irq, NULL,
|
||||
bq2589x_charger_interrupt, IRQF_TRIGGER_FALLING | IRQF_ONESHOT, BQ25890_IRQ_PIN, bq);
|
||||
if (ret) {
|
||||
dev_err(dev, "%s:Request IRQ %d failed: %d\n", __func__, client->irq, ret);
|
||||
goto err_irq;
|
||||
} else {
|
||||
dev_info(dev, "%s:irq = %d\n", __func__, client->irq);
|
||||
if (client->irq) {
|
||||
ret = devm_request_threaded_irq(dev, client->irq, NULL,
|
||||
bq2589x_charger_interrupt,
|
||||
IRQF_TRIGGER_FALLING | IRQF_ONESHOT,
|
||||
BQ25890_IRQ_PIN, bq);
|
||||
if (ret) {
|
||||
dev_err(dev, "%s:Request IRQ %d failed: %d\n", __func__, client->irq, ret);
|
||||
goto err_irq;
|
||||
} else {
|
||||
dev_info(dev, "%s:irq = %d\n", __func__, client->irq);
|
||||
enable_irq_wake(client->irq);
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef CONFIG_MMI_QC3P_TURBO_CHARGER
|
||||
|
|
|
|||
Loading…
Reference in a new issue