Commit 0e1f991efb85520590fba6ad7955116a7bd499d4
Committed by
Stefano Babic
1 parent
34ee786e5b
Exists in
v2017.01-smarct4x
and in
34 other branches
mx6cuboxi: Skip usb initialization when booting without HDMI
Starting USB initialization is useful for those who use Cuboxi/Hummingboard with HDMI and USB keyboard. However, when booting without a HDMI connection we can skip the usb initialization, which makes the boot faster. Signed-off-by: Jon Nettleton <jon.nettleton@gmail.com> Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com> Tested-By: Vagrant Cascadian <vagrant@aikidev.net>
Showing 1 changed file with 12 additions and 4 deletions Side-by-side Diff
include/configs/mx6cuboxi.h
... | ... | @@ -80,6 +80,7 @@ |
80 | 80 | #define CONFIG_VIDEO_LOGO |
81 | 81 | #define CONFIG_VIDEO_BMP_LOGO |
82 | 82 | #define CONFIG_IMX_HDMI |
83 | +#define CONFIG_CMD_HDMIDETECT | |
83 | 84 | #define CONFIG_IMX_VIDEO_SKIP |
84 | 85 | #define CONFIG_CONSOLE_MUX |
85 | 86 | |
... | ... | @@ -94,7 +95,17 @@ |
94 | 95 | #define CONFIG_USB_MAX_CONTROLLER_COUNT 2 |
95 | 96 | #define CONFIG_USB_KEYBOARD |
96 | 97 | #define CONFIG_SYS_USB_EVENT_POLL |
97 | -#define CONFIG_PREBOOT "usb start" | |
98 | +#define CONFIG_PREBOOT \ | |
99 | + "if hdmidet; then " \ | |
100 | + "usb start; " \ | |
101 | + "setenv stdin serial,usbkbd; "\ | |
102 | + "setenv stdout serial,vga; " \ | |
103 | + "setenv stderr serial,vga; " \ | |
104 | + "else " \ | |
105 | + "setenv stdin serial; " \ | |
106 | + "setenv stdout serial; " \ | |
107 | + "setenv stderr serial; " \ | |
108 | + "fi;" | |
98 | 109 | |
99 | 110 | #define CONFIG_SYS_NO_FLASH |
100 | 111 | |
... | ... | @@ -117,9 +128,6 @@ |
117 | 128 | |
118 | 129 | #define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG |
119 | 130 | #define CONFIG_EXTRA_ENV_SETTINGS \ |
120 | - "stdin=serial,usbkbd\0" \ | |
121 | - "stdout=serial,vga\0" \ | |
122 | - "stderr=serial,vga\0" \ | |
123 | 131 | "script=boot.scr\0" \ |
124 | 132 | "image=zImage\0" \ |
125 | 133 | "fdtfile=undefined\0" \ |