Loading drivers/power/smb1351-charger.c +13 −11 Original line number Diff line number Diff line Loading @@ -2911,7 +2911,7 @@ end: smb1351_relax(&chip->smb1351_ws, HVDCP_DETECT); } #define HVDCP_NOTIFY_MS 2500 #define HVDCP_NOTIFY_MS 3500 static int smb1351_apsd_complete_handler(struct smb1351_charger *chip, u8 status) { Loading Loading @@ -2943,6 +2943,7 @@ static int smb1351_apsd_complete_handler(struct smb1351_charger *chip, * If defined force hvdcp 2p0 property, * we force to hvdcp 2p0 in the APSD handler. */ if (type == POWER_SUPPLY_TYPE_USB_DCP) { if (chip->force_hvdcp_2p0) { pr_debug("Force set to HVDCP 2.0 mode\n"); smb1351_masked_write(chip, VARIOUS_FUNC_3_REG, Loading @@ -2951,13 +2952,14 @@ static int smb1351_apsd_complete_handler(struct smb1351_charger *chip, CMD_FORCE_HVDCP_2P0_BIT, CMD_FORCE_HVDCP_2P0_BIT); type = POWER_SUPPLY_TYPE_USB_HVDCP; } else if (type == POWER_SUPPLY_TYPE_USB_DCP) { } else { pr_debug("schedule hvdcp detection worker\n"); smb1351_stay_awake(&chip->smb1351_ws, HVDCP_DETECT); smb1351_stay_awake(&chip->smb1351_ws, HVDCP_DETECT); schedule_delayed_work(&chip->hvdcp_det_work, msecs_to_jiffies(HVDCP_NOTIFY_MS)); } } power_supply_set_supply_type(chip->usb_psy, type); /* * SMB is now done sampling the D+/D- lines, Loading Loading
drivers/power/smb1351-charger.c +13 −11 Original line number Diff line number Diff line Loading @@ -2911,7 +2911,7 @@ end: smb1351_relax(&chip->smb1351_ws, HVDCP_DETECT); } #define HVDCP_NOTIFY_MS 2500 #define HVDCP_NOTIFY_MS 3500 static int smb1351_apsd_complete_handler(struct smb1351_charger *chip, u8 status) { Loading Loading @@ -2943,6 +2943,7 @@ static int smb1351_apsd_complete_handler(struct smb1351_charger *chip, * If defined force hvdcp 2p0 property, * we force to hvdcp 2p0 in the APSD handler. */ if (type == POWER_SUPPLY_TYPE_USB_DCP) { if (chip->force_hvdcp_2p0) { pr_debug("Force set to HVDCP 2.0 mode\n"); smb1351_masked_write(chip, VARIOUS_FUNC_3_REG, Loading @@ -2951,13 +2952,14 @@ static int smb1351_apsd_complete_handler(struct smb1351_charger *chip, CMD_FORCE_HVDCP_2P0_BIT, CMD_FORCE_HVDCP_2P0_BIT); type = POWER_SUPPLY_TYPE_USB_HVDCP; } else if (type == POWER_SUPPLY_TYPE_USB_DCP) { } else { pr_debug("schedule hvdcp detection worker\n"); smb1351_stay_awake(&chip->smb1351_ws, HVDCP_DETECT); smb1351_stay_awake(&chip->smb1351_ws, HVDCP_DETECT); schedule_delayed_work(&chip->hvdcp_det_work, msecs_to_jiffies(HVDCP_NOTIFY_MS)); } } power_supply_set_supply_type(chip->usb_psy, type); /* * SMB is now done sampling the D+/D- lines, Loading