summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorYe Li <ye.li@nxp.com>2016-02-24 17:38:54 +0800
committerYe Li <ye.li@nxp.com>2017-04-05 14:04:36 +0800
commitb18995387375111011612aa1e47d203733d16d14 (patch)
treed7fb0cdab2870ae689da9dd074cc2c69e5cb0f6b /arch
parent7e43357e93c2aff021f9d41b4bd4f666ec0402a7 (diff)
downloadu-boot-imx-b18995387375111011612aa1e47d203733d16d14.zip
u-boot-imx-b18995387375111011612aa1e47d203733d16d14.tar.gz
u-boot-imx-b18995387375111011612aa1e47d203733d16d14.tar.bz2
MLK-12444-1 mfgtool: Add mfgtool support
If boot from usb, reset environment to default value. Auto apply mfgtools setting and boot mfgtools kernel. Porting this from fsl uboot to uboot 2016. The 7dsabresd has already added the environment and usb boot related functions. No need to add them more. Only need to add NAND parts environment for mfgtools. Signed-off-by: Ye Li <ye.li@nxp.com> (cherry picked from commit a352ed3c5184b95c4c9f7468f5fbb5f43de5e412)
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/include/asm/arch-mx6/imx-regs.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/arch/arm/include/asm/arch-mx6/imx-regs.h b/arch/arm/include/asm/arch-mx6/imx-regs.h
index 177ce66..3bdca27 100644
--- a/arch/arm/include/asm/arch-mx6/imx-regs.h
+++ b/arch/arm/include/asm/arch-mx6/imx-regs.h
@@ -1091,5 +1091,12 @@ struct dbg_monitor_regs {
u32 version[4]; /* Version */
};
+/*
+ * If ROM fail back to USB recover mode, USBPH0_PWD will be clear to use USB
+ * If boot from the other mode, USB0_PWD will keep reset value
+ */
+#define is_boot_from_usb(void) (!(readl(USB_PHY0_BASE_ADDR) & (1<<20)))
+#define disconnect_from_pc(void) writel(0x0, OTG_BASE_ADDR + 0x140)
+
#endif /* __ASSEMBLER__*/
#endif /* __ASM_ARCH_MX6_IMX_REGS_H__ */