[Armadeus-commitlog] armadeus branch, master, updated. armadeus-6.0-92-g4cedb7c
Brought to you by:
sszy
|
From: Sébastien S. <ss...@us...> - 2016-07-01 08:47:13
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "armadeus".
The branch, master has been updated
via 4cedb7ca6c5653f94472e6eacaac7061994d5bc6 (commit)
from 52e5376f0e38076791e8fe004acee43558dd8c54 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 4cedb7ca6c5653f94472e6eacaac7061994d5bc6
Author: Sébastien Szymanski <seb...@ar...>
Date: Fri Jul 1 10:48:14 2016 +0200
[LINUX] 2.6.29: apf27: add support for USB3320 phy on apf27v2
-----------------------------------------------------------------------
Summary of changes:
.../2.6.29/444-armadeus-add-apf27v2-support.patch | 72 ++++++++++++++++++++
1 files changed, 72 insertions(+), 0 deletions(-)
create mode 100644 patches/linux/2.6.29/444-armadeus-add-apf27v2-support.patch
diff --git a/patches/linux/2.6.29/444-armadeus-add-apf27v2-support.patch b/patches/linux/2.6.29/444-armadeus-add-apf27v2-support.patch
new file mode 100644
index 0000000..fbf72d3
--- /dev/null
+++ b/patches/linux/2.6.29/444-armadeus-add-apf27v2-support.patch
@@ -0,0 +1,72 @@
+Index: linux-2.6.29.6/arch/arm/mach-mx2/apf27.c
+===================================================================
+--- linux-2.6.29.6.orig/arch/arm/mach-mx2/apf27.c
++++ linux-2.6.29.6/arch/arm/mach-mx2/apf27.c
+@@ -61,6 +61,8 @@
+ #include "devices.h"
+ #include "crm_regs.h"
+
++static int apf27v2 = 0;
++
+ extern void apf27_baseboard_init(void);
+ #ifdef CONFIG_PM
+ extern void apf27_baseboard_resume(void);
+@@ -255,9 +257,17 @@ static int isp1504_check_presence(void _
+ ulpi_read(ISP1504_PID_LOW, view);
+
+ pr_info("ULPI OTG Vendor ID 0x%x Product ID 0x%x\n", vid, pid);
+- if (vid != 0x4cc || pid != 0x1504) {
+- pr_err("No ISP1504 found\n");
+- return -1;
++
++ if (apf27v2) {
++ if (vid != 0x424 || pid != 0x7) {
++ pr_err("No USB3320 found\n");
++ return -1;
++ }
++ } else {
++ if (vid != 0x4cc || pid != 0x1504) {
++ pr_err("No ISP1504 found\n");
++ return -1;
++ }
+ }
+
+ return 0;
+@@ -318,6 +328,9 @@ static void isp1504_suspend(void __iomem
+
+ static void isp1504_resume(void __iomem *view)
+ {
++ if (apf27v2)
++ return;
++
+ /* uggly but the STP line must be set to 1 before the first PHY access
+ in order to wake up the ULPI clock of the PHY. */
+ gpio_set_value(GPIO_PORTE | 1, 1);
+@@ -368,6 +381,14 @@ static int apf27_usbotg_init(struct plat
+ int ret;
+ uint32_t temp;
+
++ if (apf27v2) {
++ gpio_set_value(GPIO_PORTF | 8, 0);
++ mxc_gpio_mode(GPIO_PORTF | 8 | GPIO_OUT | GPIO_GPIO);
++ mdelay(1);
++ gpio_set_value(GPIO_PORTF | 8, 1);
++ mdelay(1);
++ }
++
+ ret = mxc_gpio_setup_multiple_pins(mxc_usbotg_pins,
+ ARRAY_SIZE(mxc_usbotg_pins), "USB OTG");
+ if (ret)
+@@ -695,6 +716,12 @@ static void __init apf27_init(void)
+ #ifdef CONFIG_WATCHDOG
+ mxc_register_device(&mxc_wdt, NULL);
+ #endif
++
++ mxc_gpio_mode(GPIO_PORTE | 17 | GPIO_IN | GPIO_GPIO);
++ apf27v2 = !gpio_get_value(GPIO_PORTE | 17);
++
++ printk("APF27 version %d\n", apf27v2 ? 2 : 1);
++
+ if (otg_mode_host) {
+ mxc_register_device(&mxc_otg_host, &ehci0_pdata);
+ } else {
hooks/post-receive
--
armadeus
|