summaryrefslogtreecommitdiff
path: root/drivers/usb/host/ehci-mx6.c
diff options
context:
space:
mode:
authorYe Li <ye.li@nxp.com>2016-03-16 13:50:54 +0800
committerYe Li <ye.li@nxp.com>2017-04-05 14:04:35 +0800
commit2d3b5df8530cd5ef883750378838dea7c40259af (patch)
tree346ff7728eddc05a01e58e4d6277a753c6b8acab /drivers/usb/host/ehci-mx6.c
parent8aef13ebd92f709f4e6b80cf46c7cfe0f69bb211 (diff)
downloadu-boot-imx-2d3b5df8530cd5ef883750378838dea7c40259af.zip
u-boot-imx-2d3b5df8530cd5ef883750378838dea7c40259af.tar.gz
u-boot-imx-2d3b5df8530cd5ef883750378838dea7c40259af.tar.bz2
MLK-12483-4 mx6: Modify drivers to disable fused modules
Add the fuse checking in drivers, when the module is disabled in fuse, the driver will not work. Changed drivers: BEE, GPMI, APBH-DMA, ESDHC, FEC, QSPI, ECSPI, I2C, USB-EHCI, GIS, LCDIF. Signed-off-by: Ye Li <ye.li@nxp.com> (cherry picked from commit 1704e116f9b39aeb99201919a18bc2b1e19a980e)
Diffstat (limited to 'drivers/usb/host/ehci-mx6.c')
-rw-r--r--drivers/usb/host/ehci-mx6.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/usb/host/ehci-mx6.c b/drivers/usb/host/ehci-mx6.c
index 55ac162..db9748e 100644
--- a/drivers/usb/host/ehci-mx6.c
+++ b/drivers/usb/host/ehci-mx6.c
@@ -18,6 +18,7 @@
#include <asm/imx-common/sys_proto.h>
#include <dm.h>
#include <power/regulator.h>
+#include <asm/arch/sys_proto.h>
#include "ehci.h"
@@ -353,6 +354,13 @@ int ehci_hcd_init(int index, enum usb_init_type init,
if (index > 3)
return -EINVAL;
+#if defined(CONFIG_MX6)
+ if (mx6_usb_fused((u32)ehci)) {
+ printf("USB@0x%x is fused, disable it\n", (u32)ehci);
+ return -ENODEV;
+ }
+#endif
+
ret = ehci_mx6_common_init(ehci, index);
if (ret)
return ret;
@@ -511,6 +519,13 @@ static int ehci_usb_probe(struct udevice *dev)
struct ehci_hcor *hcor;
int ret;
+#if defined(CONFIG_MX6)
+ if (mx6_usb_fused((u32)ehci)) {
+ printf("USB@0x%x is fused, disable it\n", (u32)ehci);
+ return -ENODEV;
+ }
+#endif
+
priv->ehci = ehci;
priv->portnr = dev->seq;
priv->init_type = type;