Patchwork [U-Boot,v3,3/3] Tegra: Config: Enable Tegra30/Tegra114 USB function

login
register
mail settings
Submitter Jim Lin
Date June 17, 2013, 9:09 a.m.
Message ID <1371460197-17912-3-git-send-email-jilin@nvidia.com>
Download mbox | patch
Permalink /patch/251789/
State Superseded
Delegated to: Tom Warren
Headers show

Comments

Jim Lin - June 17, 2013, 9:09 a.m.
Add USB EHCI, storage and network support.

Tested on Tegra30 Cardhu, and Tegra114 Dalmore
platforms. All works well.

Signed-off-by: Jim Lin <jilin@nvidia.com>
---
Changes in v2:
  - Add support for Beaver board.
Changes in v3:
  - None

 include/configs/beaver.h          |   14 ++++++++++++++
 include/configs/cardhu.h          |   14 ++++++++++++++
 include/configs/dalmore.h         |   14 ++++++++++++++
 include/configs/tegra114-common.h |    3 +++
 include/configs/tegra30-common.h  |    3 +++
 5 files changed, 48 insertions(+), 0 deletions(-)
Stephen Warren - June 17, 2013, 4:48 p.m.
On 06/17/2013 03:09 AM, Jim Lin wrote:
> Add USB EHCI, storage and network support.
> 
> Tested on Tegra30 Cardhu, and Tegra114 Dalmore
> platforms. All works well.

> diff --git a/include/configs/beaver.h b/include/configs/beaver.h

> +/* USB Host support */

I notice that some Tegra20 boards include the following line here:

#define CONFIG_USB_MAX_CONTROLLER_COUNT 3

Is this necessary here too?

If it doesn't serve any purpose, can you send an extra patch to remove
this from seaboard.h, harmony.h, trimslice.h, and colibtri_t20_iris.h.
Thanks.

> +#define CONFIG_USB_EHCI
> +#define CONFIG_USB_EHCI_TEGRA
> +#define CONFIG_USB_STORAGE
> +#define CONFIG_CMD_USB
Marek Vasut - June 17, 2013, 8:41 p.m.
Dear Stephen Warren,

> On 06/17/2013 03:09 AM, Jim Lin wrote:
> > Add USB EHCI, storage and network support.
> > 
> > Tested on Tegra30 Cardhu, and Tegra114 Dalmore
> > platforms. All works well.
> > 
> > diff --git a/include/configs/beaver.h b/include/configs/beaver.h
> > 
> > +/* USB Host support */
> 
> I notice that some Tegra20 boards include the following line here:
> 
> #define CONFIG_USB_MAX_CONTROLLER_COUNT 3
> 
> Is this necessary here too?
> 
> If it doesn't serve any purpose, can you send an extra patch to remove
> this from seaboard.h, harmony.h, trimslice.h, and colibtri_t20_iris.h.
> Thanks.

The default value is 1, if you have multiple EHCI controllers on the board/chip, 
you want to configure this accordingly.

Best regards,
Marek Vasut

Patch

diff --git a/include/configs/beaver.h b/include/configs/beaver.h
index 058da4f..165de13 100644
--- a/include/configs/beaver.h
+++ b/include/configs/beaver.h
@@ -71,6 +71,20 @@ 
 #define CONFIG_CMD_SF
 #define CONFIG_SPI_FLASH_SIZE          (4 << 20)
 
+/* USB Host support */
+#define CONFIG_USB_EHCI
+#define CONFIG_USB_EHCI_TEGRA
+#define CONFIG_USB_STORAGE
+#define CONFIG_CMD_USB
+
+/* USB networking support */
+#define CONFIG_USB_HOST_ETHER
+#define CONFIG_USB_ETHER_ASIX
+
+/* General networking support */
+#define CONFIG_CMD_NET
+#define CONFIG_CMD_DHCP
+
 #include "tegra-common-post.h"
 
 #endif /* __CONFIG_H */
diff --git a/include/configs/cardhu.h b/include/configs/cardhu.h
index 6a99175..fd46083 100644
--- a/include/configs/cardhu.h
+++ b/include/configs/cardhu.h
@@ -70,6 +70,20 @@ 
 #define CONFIG_CMD_SF
 #define CONFIG_SPI_FLASH_SIZE          (4 << 20)
 
+/* USB Host support */
+#define CONFIG_USB_EHCI
+#define CONFIG_USB_EHCI_TEGRA
+#define CONFIG_USB_STORAGE
+#define CONFIG_CMD_USB
+
+/* USB networking support */
+#define CONFIG_USB_HOST_ETHER
+#define CONFIG_USB_ETHER_ASIX
+
+/* General networking support */
+#define CONFIG_CMD_NET
+#define CONFIG_CMD_DHCP
+
 #include "tegra-common-post.h"
 
 #endif /* __CONFIG_H */
diff --git a/include/configs/dalmore.h b/include/configs/dalmore.h
index 7b68f7c..2723843 100644
--- a/include/configs/dalmore.h
+++ b/include/configs/dalmore.h
@@ -75,6 +75,20 @@ 
 #define CONFIG_CMD_SF
 #define CONFIG_SPI_FLASH_SIZE          (4 << 20)
 
+/* USB Host support */
+#define CONFIG_USB_EHCI
+#define CONFIG_USB_EHCI_TEGRA
+#define CONFIG_USB_STORAGE
+#define CONFIG_CMD_USB
+
+/* USB networking support */
+#define CONFIG_USB_HOST_ETHER
+#define CONFIG_USB_ETHER_ASIX
+
+/* General networking support */
+#define CONFIG_CMD_NET
+#define CONFIG_CMD_DHCP
+
 #include "tegra-common-post.h"
 
 #endif /* __CONFIG_H */
diff --git a/include/configs/tegra114-common.h b/include/configs/tegra114-common.h
index 721b29c..44e98e5 100644
--- a/include/configs/tegra114-common.h
+++ b/include/configs/tegra114-common.h
@@ -77,4 +77,7 @@ 
 /* Total I2C ports on Tegra114 */
 #define TEGRA_I2C_NUM_CONTROLLERS	5
 
+/* For USB EHCI controller */
+#define CONFIG_EHCI_IS_TDI
+
 #endif /* _TEGRA114_COMMON_H_ */
diff --git a/include/configs/tegra30-common.h b/include/configs/tegra30-common.h
index ed36e11..7ea36be 100644
--- a/include/configs/tegra30-common.h
+++ b/include/configs/tegra30-common.h
@@ -90,4 +90,7 @@ 
 /* Total I2C ports on Tegra30 */
 #define TEGRA_I2C_NUM_CONTROLLERS	5
 
+/* For USB EHCI controller */
+#define CONFIG_EHCI_IS_TDI
+
 #endif /* _TEGRA30_COMMON_H_ */