提交 58a0f23f 编写于 作者: P Pratyush Anand 提交者: Felipe Balbi

USB: DWC3: Issue device soft reset before core soft reset

Synopsys specification clearly states under section "Device Power-On or
Soft Reset" that DCTL.CSftRst=1 should be first step.  So, just follow
what specification says.
Signed-off-by: NPratyush Anand <pratyush.anand@st.com>
Signed-off-by: NFelipe Balbi <balbi@ti.com>
上级 45627ac6
...@@ -335,8 +335,6 @@ static int __devinit dwc3_core_init(struct dwc3 *dwc) ...@@ -335,8 +335,6 @@ static int __devinit dwc3_core_init(struct dwc3 *dwc)
} }
dwc->revision = reg; dwc->revision = reg;
dwc3_core_soft_reset(dwc);
/* issue device SoftReset too */ /* issue device SoftReset too */
timeout = jiffies + msecs_to_jiffies(500); timeout = jiffies + msecs_to_jiffies(500);
dwc3_writel(dwc->regs, DWC3_DCTL, DWC3_DCTL_CSFTRST); dwc3_writel(dwc->regs, DWC3_DCTL, DWC3_DCTL_CSFTRST);
...@@ -354,6 +352,8 @@ static int __devinit dwc3_core_init(struct dwc3 *dwc) ...@@ -354,6 +352,8 @@ static int __devinit dwc3_core_init(struct dwc3 *dwc)
cpu_relax(); cpu_relax();
} while (true); } while (true);
dwc3_core_soft_reset(dwc);
dwc3_cache_hwparams(dwc); dwc3_cache_hwparams(dwc);
reg = dwc3_readl(dwc->regs, DWC3_GCTL); reg = dwc3_readl(dwc->regs, DWC3_GCTL);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册