aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Documentation/devicetree/bindings/usb/dwc3.txt1
-rw-r--r--drivers/usb/dwc3/core.c6
-rw-r--r--drivers/usb/dwc3/core.h2
-rw-r--r--drivers/usb/dwc3/platform_data.h1
4 files changed, 10 insertions, 0 deletions
diff --git a/Documentation/devicetree/bindings/usb/dwc3.txt b/Documentation/devicetree/bindings/usb/dwc3.txt
index b724b2e78549..08b394ebeb3e 100644
--- a/Documentation/devicetree/bindings/usb/dwc3.txt
+++ b/Documentation/devicetree/bindings/usb/dwc3.txt
@@ -32,6 +32,7 @@ Optional properties:
32 - snps,tx_de_emphasis_quirk: when set core will set Tx de-emphasis value. 32 - snps,tx_de_emphasis_quirk: when set core will set Tx de-emphasis value.
33 - snps,tx_de_emphasis: the value driven to the PHY is controlled by the 33 - snps,tx_de_emphasis: the value driven to the PHY is controlled by the
34 LTSSM during USB3 Compliance mode. 34 LTSSM during USB3 Compliance mode.
35 - snps,dis_u3_susphy_quirk: when set core will disable USB3 suspend phy.
35 36
36This is usually a subnode to DWC3 glue to which it is connected. 37This is usually a subnode to DWC3 glue to which it is connected.
37 38
diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index c3dfb195f79c..87ffb86bc2f2 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -404,6 +404,9 @@ static void dwc3_phy_setup(struct dwc3 *dwc)
404 if (dwc->tx_de_emphasis_quirk) 404 if (dwc->tx_de_emphasis_quirk)
405 reg |= DWC3_GUSB3PIPECTL_TX_DEEPH(dwc->tx_de_emphasis); 405 reg |= DWC3_GUSB3PIPECTL_TX_DEEPH(dwc->tx_de_emphasis);
406 406
407 if (dwc->dis_u3_susphy_quirk && dwc->is_fpga)
408 reg &= ~DWC3_GUSB3PIPECTL_SUSPHY;
409
407 dwc3_writel(dwc->regs, DWC3_GUSB3PIPECTL(0), reg); 410 dwc3_writel(dwc->regs, DWC3_GUSB3PIPECTL(0), reg);
408 411
409 mdelay(100); 412 mdelay(100);
@@ -812,6 +815,8 @@ static int dwc3_probe(struct platform_device *pdev)
812 "snps,lfps_filter_quirk"); 815 "snps,lfps_filter_quirk");
813 dwc->rx_detect_poll_quirk = of_property_read_bool(node, 816 dwc->rx_detect_poll_quirk = of_property_read_bool(node,
814 "snps,rx_detect_poll_quirk"); 817 "snps,rx_detect_poll_quirk");
818 dwc->dis_u3_susphy_quirk = of_property_read_bool(node,
819 "snps,dis_u3_susphy_quirk");
815 820
816 dwc->tx_de_emphasis_quirk = of_property_read_bool(node, 821 dwc->tx_de_emphasis_quirk = of_property_read_bool(node,
817 "snps,tx_de_emphasis_quirk"); 822 "snps,tx_de_emphasis_quirk");
@@ -834,6 +839,7 @@ static int dwc3_probe(struct platform_device *pdev)
834 dwc->del_phy_power_chg_quirk = pdata->del_phy_power_chg_quirk; 839 dwc->del_phy_power_chg_quirk = pdata->del_phy_power_chg_quirk;
835 dwc->lfps_filter_quirk = pdata->lfps_filter_quirk; 840 dwc->lfps_filter_quirk = pdata->lfps_filter_quirk;
836 dwc->rx_detect_poll_quirk = pdata->rx_detect_poll_quirk; 841 dwc->rx_detect_poll_quirk = pdata->rx_detect_poll_quirk;
842 dwc->dis_u3_susphy_quirk = pdata->dis_u3_susphy_quirk;
837 843
838 dwc->tx_de_emphasis_quirk = pdata->tx_de_emphasis_quirk; 844 dwc->tx_de_emphasis_quirk = pdata->tx_de_emphasis_quirk;
839 if (pdata->tx_de_emphasis) 845 if (pdata->tx_de_emphasis)
diff --git a/drivers/usb/dwc3/core.h b/drivers/usb/dwc3/core.h
index cf9aaca6add0..fa778b0a5ab7 100644
--- a/drivers/usb/dwc3/core.h
+++ b/drivers/usb/dwc3/core.h
@@ -697,6 +697,7 @@ struct dwc3_scratchpad_array {
697 * @del_phy_power_chg_quirk: set if we enable delay phy power change quirk 697 * @del_phy_power_chg_quirk: set if we enable delay phy power change quirk
698 * @lfps_filter_quirk: set if we enable LFPS filter quirk 698 * @lfps_filter_quirk: set if we enable LFPS filter quirk
699 * @rx_detect_poll_quirk: set if we enable rx_detect to polling lfps quirk 699 * @rx_detect_poll_quirk: set if we enable rx_detect to polling lfps quirk
700 * @dis_u3_susphy_quirk: set if we disable usb3 suspend phy
700 * @tx_de_emphasis_quirk: set if we enable Tx de-emphasis quirk 701 * @tx_de_emphasis_quirk: set if we enable Tx de-emphasis quirk
701 * @tx_de_emphasis: Tx de-emphasis value 702 * @tx_de_emphasis: Tx de-emphasis value
702 * 0 - -6dB de-emphasis 703 * 0 - -6dB de-emphasis
@@ -818,6 +819,7 @@ struct dwc3 {
818 unsigned del_phy_power_chg_quirk:1; 819 unsigned del_phy_power_chg_quirk:1;
819 unsigned lfps_filter_quirk:1; 820 unsigned lfps_filter_quirk:1;
820 unsigned rx_detect_poll_quirk:1; 821 unsigned rx_detect_poll_quirk:1;
822 unsigned dis_u3_susphy_quirk:1;
821 823
822 unsigned tx_de_emphasis_quirk:1; 824 unsigned tx_de_emphasis_quirk:1;
823 unsigned tx_de_emphasis:2; 825 unsigned tx_de_emphasis:2;
diff --git a/drivers/usb/dwc3/platform_data.h b/drivers/usb/dwc3/platform_data.h
index e1ab900a8623..0f1d5adc657d 100644
--- a/drivers/usb/dwc3/platform_data.h
+++ b/drivers/usb/dwc3/platform_data.h
@@ -36,6 +36,7 @@ struct dwc3_platform_data {
36 unsigned del_phy_power_chg_quirk:1; 36 unsigned del_phy_power_chg_quirk:1;
37 unsigned lfps_filter_quirk:1; 37 unsigned lfps_filter_quirk:1;
38 unsigned rx_detect_poll_quirk:1; 38 unsigned rx_detect_poll_quirk:1;
39 unsigned dis_u3_susphy_quirk:1;
39 40
40 unsigned tx_de_emphasis_quirk:1; 41 unsigned tx_de_emphasis_quirk:1;
41 unsigned tx_de_emphasis:2; 42 unsigned tx_de_emphasis:2;