Commit a6ba1e45 authored by Frank Li's avatar Frank Li Committed by Greg Kroah-Hartman

usb: dwc3: apply snps,host-vbus-glitches workaround unconditionally

Remove 'snps,host-vbus-glitches-quirk' and apply workaround
unconditionally.

It is safer to keep vbus disabled before handing over to xhci driver. So
needn't 'snps,host-vbus-glitches' property to enable it and apply it
unconditionally.

Remove all host_vbus_glitches variable and call
dwc3_power_off_all_roothub_ports() directly.
Signed-off-by: default avatarFrank Li <Frank.Li@nxp.com>
Acked-by: default avatarThinh Nguyen <Thinh.Nguyen@synopsys.com>
Acked-by: default avatarConor Dooley <conor.dooley@microchip.com>
Link: https://lore.kernel.org/r/20240212-vbus-glitch-v2-2-d71b73a82de1@nxp.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 8c1b6b74
...@@ -1626,9 +1626,6 @@ static void dwc3_get_properties(struct dwc3 *dwc) ...@@ -1626,9 +1626,6 @@ static void dwc3_get_properties(struct dwc3 *dwc)
dwc->dis_split_quirk = device_property_read_bool(dev, dwc->dis_split_quirk = device_property_read_bool(dev,
"snps,dis-split-quirk"); "snps,dis-split-quirk");
dwc->host_vbus_glitches_quirk = device_property_read_bool(dev,
"snps,host-vbus-glitches-quirk");
dwc->lpm_nyet_threshold = lpm_nyet_threshold; dwc->lpm_nyet_threshold = lpm_nyet_threshold;
dwc->tx_de_emphasis = tx_de_emphasis; dwc->tx_de_emphasis = tx_de_emphasis;
......
...@@ -1133,7 +1133,6 @@ struct dwc3_scratchpad_array { ...@@ -1133,7 +1133,6 @@ struct dwc3_scratchpad_array {
* 2 - No de-emphasis * 2 - No de-emphasis
* 3 - Reserved * 3 - Reserved
* @dis_metastability_quirk: set to disable metastability quirk. * @dis_metastability_quirk: set to disable metastability quirk.
* @host_vbus_glitches_quirk: set to avoid vbus glitch during xhci reset.
* @dis_split_quirk: set to disable split boundary. * @dis_split_quirk: set to disable split boundary.
* @wakeup_configured: set if the device is configured for remote wakeup. * @wakeup_configured: set if the device is configured for remote wakeup.
* @suspended: set to track suspend event due to U3/L2. * @suspended: set to track suspend event due to U3/L2.
...@@ -1355,7 +1354,6 @@ struct dwc3 { ...@@ -1355,7 +1354,6 @@ struct dwc3 {
unsigned tx_de_emphasis:2; unsigned tx_de_emphasis:2;
unsigned dis_metastability_quirk:1; unsigned dis_metastability_quirk:1;
unsigned host_vbus_glitches_quirk:1;
unsigned dis_split_quirk:1; unsigned dis_split_quirk:1;
unsigned async_callbacks:1; unsigned async_callbacks:1;
......
...@@ -114,8 +114,7 @@ int dwc3_host_init(struct dwc3 *dwc) ...@@ -114,8 +114,7 @@ int dwc3_host_init(struct dwc3 *dwc)
* Some platforms need to power off all Root hub ports immediately after DWC3 set to host * Some platforms need to power off all Root hub ports immediately after DWC3 set to host
* mode to avoid VBUS glitch happen when xhci get reset later. * mode to avoid VBUS glitch happen when xhci get reset later.
*/ */
if (dwc->host_vbus_glitches_quirk) dwc3_power_off_all_roothub_ports(dwc);
dwc3_power_off_all_roothub_ports(dwc);
irq = dwc3_host_get_irq(dwc); irq = dwc3_host_get_irq(dwc);
if (irq < 0) if (irq < 0)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment