summaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
Diffstat (limited to 'board')
-rw-r--r--board/freescale/common/recovery.c2
-rw-r--r--board/freescale/mx6sl_arm2/mx6sl_arm2.c33
2 files changed, 34 insertions, 1 deletions
diff --git a/board/freescale/common/recovery.c b/board/freescale/common/recovery.c
index e63a1d4..73f091b 100644
--- a/board/freescale/common/recovery.c
+++ b/board/freescale/common/recovery.c
@@ -85,7 +85,7 @@ void setup_recovery_env(void)
boot_cmd = supported_reco_envs[bootdev].cmd;
if (boot_cmd == NULL) {
- printf("Unsupported bootup device for recovery\n");
+ printf("Unsupported bootup device for recovery: dev: %d\n", bootdev);
return;
}
diff --git a/board/freescale/mx6sl_arm2/mx6sl_arm2.c b/board/freescale/mx6sl_arm2/mx6sl_arm2.c
index cff96c0..60a263f 100644
--- a/board/freescale/mx6sl_arm2/mx6sl_arm2.c
+++ b/board/freescale/mx6sl_arm2/mx6sl_arm2.c
@@ -44,11 +44,23 @@
#include <fsl_esdhc.h>
#endif
+#ifdef CONFIG_MXC_GPIO
+#include <asm/gpio.h>
+#include <asm/arch/gpio.h>
+#endif
+
+#ifdef CONFIG_ANDROID_RECOVERY
+#include <recovery.h>
+#endif
+
DECLARE_GLOBAL_DATA_PTR;
static u32 system_rev;
static enum boot_device boot_dev;
+#define USB_OTG_PWR IMX_GPIO_NR(4, 0)
+#define USB_H1_PWR IMX_GPIO_NR(4, 2)
+
static inline void setup_boot_device(void)
{
uint soc_sbmr = readl(SRC_BASE_ADDR + 0x4);
@@ -757,3 +769,24 @@ int checkboard(void)
}
return 0;
}
+
+#ifdef CONFIG_ANDROID_RECOVERY
+int check_recovery_cmd_file(void)
+{
+ return check_and_clean_recovery_flag();
+}
+#endif
+
+
+#ifdef CONFIG_IMX_UDC
+void udc_pins_setting(void)
+{
+ /* USB_OTG_PWR */
+ mxc_iomux_v3_setup_pad(MX6SL_PAD_KEY_COL4__GPIO_4_0);
+ mxc_iomux_v3_setup_pad(MX6SL_PAD_KEY_COL5__GPIO_4_2);
+ /* USB_OTG_PWR = 0 */
+ gpio_direction_output(USB_OTG_PWR, 0);
+ /* USB_H1_POWER = 1 */
+ gpio_direction_output(USB_H1_PWR, 1);
+}
+#endif