mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-14 00:24:41 -04:00
Merge "usb: dwc3: Enable PHY deep low power mode in L1 suspend"
This commit is contained in:
commit
d905a441da
2 changed files with 9 additions and 0 deletions
|
|
@ -265,6 +265,7 @@
|
|||
#define DWC3_GUCTL1_TX_IPGAP_LINECHECK_DIS BIT(28)
|
||||
#define DWC3_GUCTL1_DEV_L1_EXIT_BY_HW BIT(24)
|
||||
#define DWC3_GUCTL1_IP_GAP_ADD_ON(n) (n << 21)
|
||||
#define DWC3_GUCTL1_L1_SUSP_THRLD_EN_FOR_HOST BIT(8)
|
||||
|
||||
/* Global Status Register */
|
||||
#define DWC3_GSTS_OTG_IP BIT(10)
|
||||
|
|
|
|||
|
|
@ -2436,6 +2436,10 @@ static void dwc3_en_sleep_mode(struct dwc3_msm *mdwc)
|
|||
reg = dwc3_msm_read_reg(mdwc->base, DWC3_GUSB2PHYCFG(0));
|
||||
reg |= DWC3_GUSB2PHYCFG_ENBLSLPM;
|
||||
dwc3_msm_write_reg(mdwc->base, DWC3_GUSB2PHYCFG(0), reg);
|
||||
|
||||
reg = dwc3_msm_read_reg(mdwc->base, DWC3_GUCTL1);
|
||||
reg |= DWC3_GUCTL1_L1_SUSP_THRLD_EN_FOR_HOST;
|
||||
dwc3_msm_write_reg(mdwc->base, DWC3_GUCTL1, reg);
|
||||
}
|
||||
|
||||
static void dwc3_dis_sleep_mode(struct dwc3_msm *mdwc)
|
||||
|
|
@ -2445,6 +2449,10 @@ static void dwc3_dis_sleep_mode(struct dwc3_msm *mdwc)
|
|||
reg = dwc3_msm_read_reg(mdwc->base, DWC3_GUSB2PHYCFG(0));
|
||||
reg &= ~DWC3_GUSB2PHYCFG_ENBLSLPM;
|
||||
dwc3_msm_write_reg(mdwc->base, DWC3_GUSB2PHYCFG(0), reg);
|
||||
|
||||
reg = dwc3_msm_read_reg(mdwc->base, DWC3_GUCTL1);
|
||||
reg &= ~DWC3_GUCTL1_L1_SUSP_THRLD_EN_FOR_HOST;
|
||||
dwc3_msm_write_reg(mdwc->base, DWC3_GUCTL1, reg);
|
||||
}
|
||||
|
||||
static void dwc3_msm_power_collapse_por(struct dwc3_msm *mdwc)
|
||||
|
|
|
|||
Loading…
Reference in a new issue