husy394 / rpms / kernel

Forked from rpms/kernel 3 years ago
Clone
Pablo Greco d6c4c4
From patchwork Wed Apr  6 07:54:05 2016
Pablo Greco d6c4c4
Content-Type: text/plain; charset="utf-8"
Pablo Greco d6c4c4
MIME-Version: 1.0
Pablo Greco d6c4c4
Content-Transfer-Encoding: 7bit
Pablo Greco d6c4c4
Subject: usb: phy: tegra: Add 38.4MHz clock table entry
Pablo Greco d6c4c4
From: Hunter Laux <hunterlaux@gmail.com>
Pablo Greco d6c4c4
X-Patchwork-Id: 606877
Pablo Greco d6c4c4
Message-Id: <1459929245-23449-1-git-send-email-hunterlaux@gmail.com>
Pablo Greco d6c4c4
To: Stephen Warren <swarren@wwwdotorg.org>,
Pablo Greco d6c4c4
 Thierry Reding <thierry.reding@gmail.com>,
Pablo Greco d6c4c4
 Alexandre Courbot <gnurou@gmail.com>, linux-tegra@vger.kernel.org
Pablo Greco d6c4c4
Cc: Hunter Laux <hunterlaux@gmail.com>
Pablo Greco d6c4c4
Date: Wed,  6 Apr 2016 00:54:05 -0700
Pablo Greco d6c4c4
Pablo Greco d6c4c4
The Tegra210 uses a 38.4MHz OSC. This clock table entry is required to
Pablo Greco d6c4c4
use the ehci phy on the Jetson TX1.
Pablo Greco d6c4c4
Pablo Greco d6c4c4
The xtal_freq_count is actually a 12 bit value, so it should be a u16
Pablo Greco d6c4c4
instead of u8.
Pablo Greco d6c4c4
Pablo Greco d6c4c4
Signed-off-by: Hunter Laux <hunterlaux@gmail.com>
Pablo Greco d6c4c4
---
Pablo Greco d6c4c4
 drivers/usb/phy/phy-tegra-usb.c | 10 +++++++++-
Pablo Greco d6c4c4
 1 file changed, 9 insertions(+), 1 deletion(-)
Pablo Greco d6c4c4
Pablo Greco d6c4c4
diff --git a/drivers/usb/phy/phy-tegra-usb.c b/drivers/usb/phy/phy-tegra-usb.c
Pablo Greco d6c4c4
index 5fe4a57..f0431f0 100644
Pablo Greco d6c4c4
--- a/drivers/usb/phy/phy-tegra-usb.c
Pablo Greco d6c4c4
+++ b/drivers/usb/phy/phy-tegra-usb.c
Pablo Greco d6c4c4
@@ -164,7 +164,7 @@ struct tegra_xtal_freq {
Pablo Greco d6c4c4
 	u8 enable_delay;
Pablo Greco d6c4c4
 	u8 stable_count;
Pablo Greco d6c4c4
 	u8 active_delay;
Pablo Greco d6c4c4
-	u8 xtal_freq_count;
Pablo Greco d6c4c4
+	u16 xtal_freq_count;
Pablo Greco d6c4c4
 	u16 debounce;
Pablo Greco d6c4c4
 };
Pablo Greco d6c4c4
 
Pablo Greco d6c4c4
@@ -201,6 +201,14 @@ static const struct tegra_xtal_freq tegra_freq_table[] = {
Pablo Greco d6c4c4
 		.xtal_freq_count = 0xFE,
Pablo Greco d6c4c4
 		.debounce = 0xFDE8,
Pablo Greco d6c4c4
 	},
Pablo Greco d6c4c4
+	{
Pablo Greco d6c4c4
+		.freq = 38400000,
Pablo Greco d6c4c4
+		.enable_delay = 0x00,
Pablo Greco d6c4c4
+		.stable_count = 0x00,
Pablo Greco d6c4c4
+		.active_delay = 0x18,
Pablo Greco d6c4c4
+		.xtal_freq_count = 0x177,
Pablo Greco d6c4c4
+		.debounce = 0xBB80,
Pablo Greco d6c4c4
+	},
Pablo Greco d6c4c4
 };
Pablo Greco d6c4c4
 
Pablo Greco d6c4c4
 static void set_pts(struct tegra_usb_phy *phy, u8 pts_val)