summaryrefslogtreecommitdiff
path: root/drivers/usb/dwc3/core.c
diff options
context:
space:
mode:
authorHuang Rui <ray.huang@amd.com>2014-10-28 11:54:27 (GMT)
committerFelipe Balbi <balbi@ti.com>2014-11-03 16:03:36 (GMT)
commit9a5b2f3167c1f98b879d6a800ab138f04e34f9d5 (patch)
treecb0d1900039e1ecef1f267d05b78c84ad25b1285 /drivers/usb/dwc3/core.c
parent80caf7d21adca10c4621d511f6eb01f7ed2b342c (diff)
downloadlinux-9a5b2f3167c1f98b879d6a800ab138f04e34f9d5.tar.xz
usb: dwc3: add u2exit lfps quirk
This patch adds u2exit lfps quirk, and some special platforms can configure that if it is needed. [ balbi@ti.com : added DeviceTree binding documentation ] Signed-off-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/dwc3/core.c')
-rw-r--r--drivers/usb/dwc3/core.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index 6f9e5b8..33cbea5 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -473,6 +473,9 @@ static int dwc3_core_init(struct dwc3 *dwc)
else
reg &= ~DWC3_GCTL_DISSCRAMBLE;
+ if (dwc->u2exit_lfps_quirk)
+ reg |= DWC3_GCTL_U2EXIT_LFPS;
+
/*
* WORKAROUND: DWC3 revisions <1.90a have a bug
* where the device can fail to connect at SuperSpeed
@@ -729,6 +732,8 @@ static int dwc3_probe(struct platform_device *pdev)
dwc->disable_scramble_quirk = of_property_read_bool(node,
"snps,disable_scramble_quirk");
+ dwc->u2exit_lfps_quirk = of_property_read_bool(node,
+ "snps,u2exit_lfps_quirk");
} else if (pdata) {
dwc->maximum_speed = pdata->maximum_speed;
dwc->has_lpm_erratum = pdata->has_lpm_erratum;
@@ -739,6 +744,7 @@ static int dwc3_probe(struct platform_device *pdev)
dwc->dr_mode = pdata->dr_mode;
dwc->disable_scramble_quirk = pdata->disable_scramble_quirk;
+ dwc->u2exit_lfps_quirk = pdata->u2exit_lfps_quirk;
}
/* default to superspeed if no maximum_speed passed */