]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blame - releases/4.4.15/usb-host-ehci-tegra-grab-the-correct-utmi-pads-reset.patch
drop queue-4.14/mips-make-sure-dt-memory-regions-are-valid.patch
[thirdparty/kernel/stable-queue.git] / releases / 4.4.15 / usb-host-ehci-tegra-grab-the-correct-utmi-pads-reset.patch
CommitLineData
7a49e214
GKH
1From f8a15a9650694feaa0dabf197b0c94d37cd3fb42 Mon Sep 17 00:00:00 2001
2From: Thierry Reding <treding@nvidia.com>
3Date: Thu, 26 May 2016 17:23:29 +0200
4Subject: usb: host: ehci-tegra: Grab the correct UTMI pads reset
5
6From: Thierry Reding <treding@nvidia.com>
7
8commit f8a15a9650694feaa0dabf197b0c94d37cd3fb42 upstream.
9
10There are three EHCI controllers on Tegra SoCs, each with its own reset
11line. However, the first controller contains a set of UTMI configuration
12registers that are shared with its siblings. These registers will only
13be reset as part of the first controller's reset. For proper operation
14it must be ensured that the UTMI configuration registers are reset
15before any of the EHCI controllers are enabled, irrespective of the
16probe order.
17
18Commit a47cc24cd1e5 ("USB: EHCI: tegra: Fix probe order issue leading to
19broken USB") introduced code that ensures the first controller is always
20reset before setting up any of the controllers, and is never again reset
21afterwards.
22
23This code, however, grabs the wrong reset. Each EHCI controller has two
24reset controls attached: 1) the USB controller reset and 2) the UTMI
25pads reset (really the first controller's reset). In order to reset the
26UTMI pads registers the code must grab the second reset, but instead it
27grabbing the first.
28
29Fixes: a47cc24cd1e5 ("USB: EHCI: tegra: Fix probe order issue leading to broken USB")
30Acked-by: Jon Hunter <jonathanh@nvidia.com>
31Signed-off-by: Thierry Reding <treding@nvidia.com>
32Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
33
34---
35 drivers/usb/host/ehci-tegra.c | 2 +-
36 1 file changed, 1 insertion(+), 1 deletion(-)
37
38--- a/drivers/usb/host/ehci-tegra.c
39+++ b/drivers/usb/host/ehci-tegra.c
40@@ -89,7 +89,7 @@ static int tegra_reset_usb_controller(st
41 if (!usb1_reset_attempted) {
42 struct reset_control *usb1_reset;
43
44- usb1_reset = of_reset_control_get(phy_np, "usb");
45+ usb1_reset = of_reset_control_get(phy_np, "utmi-pads");
46 if (IS_ERR(usb1_reset)) {
47 dev_warn(&pdev->dev,
48 "can't get utmi-pads reset from the PHY\n");