Convert CONFIG_USB_MAX_CONTROLLER_COUNT to Kconfig
[platform/kernel/u-boot.git] / include / configs / ge_b1x5v2.h
1 /*
2  * GE B1x5v2
3  *
4  * Copyright 2018-2020 GE Inc.
5  * Copyright 2018-2020 Collabora Ltd.
6  *
7  * SPDX-License-Identifier:    GPL-2.0+
8  */
9
10 #ifndef __GE_B1X5V2_CONFIG_H
11 #define __GE_B1X5V2_CONFIG_H
12
13 #include "mx6_common.h"
14
15 #include "imx6_spl.h"
16
17 /* PWM */
18 #define CONFIG_IMX6_PWM_PER_CLK         66000000
19
20 /* UART */
21 #define CONFIG_MXC_UART_BASE            UART3_BASE
22
23 #if CONFIG_MXC_UART_BASE == UART2_BASE
24 /* UART2 requires CONFIG_DEBUG_UART_BASE=0x21e8000 */
25 #define CONSOLE_DEVICE "ttymxc1" /* System on Module debug connector */
26 #else
27 /* UART3 requires CONFIG_DEBUG_UART_BASE=0x21ec000 */
28 #define CONSOLE_DEVICE "ttymxc2" /* Base board debug connector */
29 #endif
30
31 /* USB */
32 #define CONFIG_MXC_USB_PORTSC           (PORT_PTS_UTMI | PORT_PTS_PTW)
33 #define CONFIG_MXC_USB_FLAGS            0
34 #define CONFIG_USBD_HS
35
36 /* Video */
37 #define CONFIG_HIDE_LOGO_VERSION
38 #define CONFIG_IMX_VIDEO_SKIP
39
40 /* Memory */
41 #define PHYS_SDRAM                     MMDC0_ARB_BASE_ADDR
42
43 #define CONFIG_SYS_SDRAM_BASE          PHYS_SDRAM
44 #define CONFIG_SYS_INIT_RAM_ADDR       IRAM_BASE_ADDR
45 #define CONFIG_SYS_INIT_RAM_SIZE       IRAM_SIZE
46
47 /* Command definition */
48 #define CONFIG_EXTRA_ENV_SETTINGS \
49         "image=/boot/fitImage\0" \
50         "fdt_addr_r=0x18000000\0" \
51         "splash_addr_r=0x20000000\0" \
52         "mmcdev=2\0" \
53         "mmcpart=1\0" \
54         "console=console="CONSOLE_DEVICE",115200\0" \
55         "quiet=quiet loglevel=0\0" \
56         "rootdev=/dev/mmcblk1p\0" \
57         "setargs=setenv bootargs ${console} ${quiet} ${fsckforcerepair} " \
58                 "bootcause=${bootcause} vt.global_cursor_default=0 vt.cur_default=1 " \
59                 "root=${rootdev}${mmcpart} video=HDMI-A-1:${resolution} rootwait ro\0" \
60         "loadimage=load mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
61         "showsplashscreen=load mmc ${mmcdev}:${mmcpart} ${splash_addr_r} /boot/splashscreen-${resolution}.bmp; " \
62                 "bmp display ${splash_addr_r};\0" \
63         "setconfidx=" \
64                 "if test \"${devicetype}\" = \"B105v2\"; then " \
65                         "setenv confidx 1; " \
66                 "elif test \"${devicetype}\" = \"B125v2\"; then " \
67                         "setenv confidx 2; " \
68                 "elif test \"${devicetype}\" = \"B155v2\"; then " \
69                         "setenv confidx 3; " \
70                 "elif test \"${devicetype}\" = \"B105Pv2\"; then " \
71                         "setenv confidx 4; " \
72                 "elif test \"${devicetype}\" = \"B125Pv2\"; then " \
73                         "setenv confidx 5; " \
74                 "fi;\0" \
75         "set_default_type=setenv devicetype B155v2; setenv resolution 1366x768;" \
76                 "setenv fdtfile imx6dl-b155v2.dtb; run setconfidx;\0" \
77         "checkconfidx=env exists confidx || run set_default_type;\0" \
78         "checkfsckforcerepair=" \
79                 "if test \"${bootcount}\" > \"3\" ; then " \
80                         "setenv fsckforcerepair fsck.repair=1; " \
81                 "fi;\0" \
82         "helix=run setconfidx; run checkconfidx; run checkfsckforcerepair; run setargs; " \
83                 "regulator dev LED_VCC; regulator enable; " \
84                 "regulator dev 5V0_AUDIO; regulator enable; " \
85                 "bootm ${loadaddr}#conf@${confidx};\0" \
86         "failbootcmd=" \
87                 "echo reached failbootcmd;" \
88                 "cls; setcurs 5 4; " \
89                 "lcdputs \"Monitor failed to start. Try again, or contact GE Service for support.\"; " \
90                 "bootcount reset; \0" \
91         "hasfirstboot=" \
92                 "load mmc ${mmcdev}:${mmcpart} ${loadaddr} " \
93                 "/boot/bootcause/firstboot;\0" \
94         "swappartitions=" \
95                 "setexpr mmcpart 3 - ${mmcpart};\0" \
96         "doboot=" \
97                 "echo Booting from mmc:${mmcdev}:${mmcpart} ...; " \
98                 "run helix;\0" \
99         "altbootcmd=" \
100                 "setenv mmcpart 1; run hasfirstboot || setenv mmcpart 2; " \
101                 "run hasfirstboot || setenv mmcpart 0; " \
102                 "if test ${mmcpart} != 0; then " \
103                         "setenv bootcause REVERT; " \
104                         "run swappartitions loadimage doboot; " \
105                 "fi; " \
106                 "run failbootcmd\0" \
107         "tryboot=" \
108                 "setenv mmcpart 1; run hasfirstboot || setenv mmcpart 2; " \
109                 "run loadimage || run swappartitions && run loadimage || " \
110                 "setenv mmcpart 0 && echo MISSING IMAGE;" \
111                 "run showsplashscreen; sleep 1; " \
112                 "run doboot; run failbootcmd;\0" \
113
114 #endif /* __GE_B1X5V2_CONFIG_H */