Merge "power: smb1351-charger: Disable parallel charging in shutdown path"
This commit is contained in:
commit
188c08e1bf
1 changed files with 9 additions and 0 deletions
|
@ -3264,6 +3264,14 @@ static int smb1351_charger_remove(struct i2c_client *client)
|
|||
return 0;
|
||||
}
|
||||
|
||||
static void smb1351_charger_shutdown(struct i2c_client *client)
|
||||
{
|
||||
struct smb1351_charger *chip = i2c_get_clientdata(client);
|
||||
|
||||
if (chip->chg_present)
|
||||
smb1351_usb_suspend(chip, USER, true);
|
||||
}
|
||||
|
||||
static int smb1351_suspend(struct device *dev)
|
||||
{
|
||||
struct i2c_client *client = to_i2c_client(dev);
|
||||
|
@ -3343,6 +3351,7 @@ static struct i2c_driver smb1351_charger_driver = {
|
|||
},
|
||||
.probe = smb1351_charger_probe,
|
||||
.remove = smb1351_charger_remove,
|
||||
.shutdown = smb1351_charger_shutdown,
|
||||
.id_table = smb1351_charger_id,
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue