Commit 68ccab51936d92551e3e65944af172ad64ca2ca9
1 parent
29cb2b3b90
Exists in
smarc_8mq_lf_v2020.04
and in
17 other branches
omap3: Migrate CONFIG_OMAP3_GPIO_X to Kconfig
The symbols CONFIG_OMAP3_GPIO_X control if we enable the clocks for a given GPIO bank in U-Boot. select the required banks for each target. In some cases we need to also migrate from CONFIG_USB_EHCI (deprecated, in include/configs/) to CONFIG_USB_EHCI_HCD as we only require the GPIO bank to be enabled if USB is also enabled. Signed-off-by: Tom Rini <trini@konsulko.com>
Showing 20 changed files with 58 additions and 73 deletions Side-by-side Diff
- arch/arm/mach-omap2/omap3/Kconfig
- configs/eco5pk_defconfig
- configs/mcx_defconfig
- configs/mt_ventoux_defconfig
- configs/twister_defconfig
- include/configs/cm_t35.h
- include/configs/cm_t3517.h
- include/configs/mcx.h
- include/configs/mt_ventoux.h
- include/configs/omap3_beagle.h
- include/configs/omap3_igep00x0.h
- include/configs/omap3_logic.h
- include/configs/omap3_overo.h
- include/configs/omap3_pandora.h
- include/configs/sniper.h
- include/configs/tam3517-common.h
- include/configs/tao3530.h
- include/configs/tricorder.h
- include/configs/twister.h
- scripts/config_whitelist.txt
arch/arm/mach-omap2/omap3/Kconfig
1 | 1 | if OMAP34XX |
2 | 2 | |
3 | +# We only enable the clocks for the GPIO banks that a given board requies. | |
4 | +config OMAP3_GPIO_2 | |
5 | + bool | |
6 | + | |
7 | +config OMAP3_GPIO_3 | |
8 | + bool | |
9 | + | |
10 | +config OMAP3_GPIO_4 | |
11 | + bool | |
12 | + | |
13 | +config OMAP3_GPIO_5 | |
14 | + bool | |
15 | + | |
16 | +config OMAP3_GPIO_6 | |
17 | + bool | |
18 | + | |
3 | 19 | choice |
4 | 20 | prompt "OMAP3 board select" |
5 | 21 | optional |
6 | 22 | |
7 | 23 | |
8 | 24 | |
... | ... | @@ -9,18 +25,28 @@ |
9 | 25 | |
10 | 26 | config TARGET_MT_VENTOUX |
11 | 27 | bool "TeeJet Mt.Ventoux" |
28 | + select OMAP3_GPIO_4 | |
29 | + select OMAP3_GPIO_5 if USB_EHCI_HCD | |
12 | 30 | |
13 | 31 | config TARGET_OMAP3_BEAGLE |
14 | 32 | bool "TI OMAP3 BeagleBoard" |
15 | 33 | select DM |
16 | 34 | select DM_SERIAL |
17 | 35 | select DM_GPIO |
36 | + select OMAP3_GPIO_5 | |
37 | + select OMAP3_GPIO_6 | |
18 | 38 | |
19 | 39 | config TARGET_CM_T35 |
20 | 40 | bool "CompuLab CM-T3530 and CM-T3730 boards" |
41 | + select OMAP3_GPIO_2 | |
42 | + select OMAP3_GPIO_5 | |
43 | + select OMAP3_GPIO_6 if LED_STATUS | |
21 | 44 | |
22 | 45 | config TARGET_CM_T3517 |
23 | 46 | bool "CompuLab CM-T3517 boards" |
47 | + select OMAP3_GPIO_2 | |
48 | + select OMAP3_GPIO_5 | |
49 | + select OMAP3_GPIO_6 if LED_STATUS | |
24 | 50 | |
25 | 51 | config TARGET_DEVKIT8000 |
26 | 52 | bool "TimLL OMAP3 Devkit8000" |
27 | 53 | |
... | ... | @@ -36,12 +62,20 @@ |
36 | 62 | select DM |
37 | 63 | select DM_SERIAL |
38 | 64 | select DM_GPIO |
65 | + select OMAP3_GPIO_3 | |
66 | + select OMAP3_GPIO_5 | |
67 | + select OMAP3_GPIO_6 | |
39 | 68 | |
40 | 69 | config TARGET_OMAP3_OVERO |
41 | 70 | bool "OMAP35xx Gumstix Overo" |
42 | 71 | select DM |
43 | 72 | select DM_SERIAL |
44 | 73 | select DM_GPIO |
74 | + select OMAP3_GPIO_2 | |
75 | + select OMAP3_GPIO_3 | |
76 | + select OMAP3_GPIO_4 | |
77 | + select OMAP3_GPIO_5 | |
78 | + select OMAP3_GPIO_6 | |
45 | 79 | |
46 | 80 | config TARGET_OMAP3_ZOOM1 |
47 | 81 | bool "TI Zoom1" |
48 | 82 | |
49 | 83 | |
50 | 84 | |
... | ... | @@ -54,16 +88,22 @@ |
54 | 88 | |
55 | 89 | config TARGET_OMAP3_PANDORA |
56 | 90 | bool "OMAP3 Pandora" |
91 | + select OMAP3_GPIO_4 | |
92 | + select OMAP3_GPIO_6 | |
57 | 93 | |
58 | 94 | config TARGET_ECO5PK |
59 | 95 | bool "ECO5PK" |
96 | + select OMAP3_GPIO_5 if USB_EHCI_HCD | |
60 | 97 | |
61 | 98 | config TARGET_TRICORDER |
62 | 99 | bool "Tricorder" |
100 | + select OMAP3_GPIO_2 | |
63 | 101 | |
64 | 102 | config TARGET_MCX |
65 | 103 | bool "MCX" |
66 | 104 | select BOARD_LATE_INIT |
105 | + select OMAP3_GPIO_2 if USB_EHCI_HCD | |
106 | + select OMAP3_GPIO_5 if USB_EHCI_HCD | |
67 | 107 | |
68 | 108 | config TARGET_OMAP3_LOGIC |
69 | 109 | bool "OMAP3 Logic" |
70 | 110 | |
71 | 111 | |
... | ... | @@ -71,15 +111,24 @@ |
71 | 111 | select DM |
72 | 112 | select DM_SERIAL |
73 | 113 | select DM_GPIO |
114 | + select OMAP3_GPIO_4 | |
115 | + select OMAP3_GPIO_6 | |
74 | 116 | |
75 | 117 | config TARGET_NOKIA_RX51 |
76 | 118 | bool "Nokia RX51" |
77 | 119 | |
78 | 120 | config TARGET_TAO3530 |
79 | 121 | bool "TAO3530" |
122 | + select OMAP3_GPIO_2 | |
123 | + select OMAP3_GPIO_3 | |
124 | + select OMAP3_GPIO_4 | |
125 | + select OMAP3_GPIO_5 | |
126 | + select OMAP3_GPIO_6 | |
80 | 127 | |
81 | 128 | config TARGET_TWISTER |
82 | 129 | bool "Twister" |
130 | + select OMAP3_GPIO_2 | |
131 | + select OMAP3_GPIO_5 if USB_EHCI_HCD | |
83 | 132 | |
84 | 133 | config TARGET_OMAP3_CAIRO |
85 | 134 | bool "QUIPOS CAIRO" |
... | ... | @@ -92,6 +141,11 @@ |
92 | 141 | select DM |
93 | 142 | select DM_SERIAL |
94 | 143 | select DM_GPIO |
144 | + select OMAP3_GPIO_2 | |
145 | + select OMAP3_GPIO_3 | |
146 | + select OMAP3_GPIO_4 | |
147 | + select OMAP3_GPIO_5 | |
148 | + select OMAP3_GPIO_6 | |
95 | 149 | |
96 | 150 | endchoice |
97 | 151 |
configs/eco5pk_defconfig
configs/mcx_defconfig
configs/mt_ventoux_defconfig
configs/twister_defconfig
include/configs/cm_t35.h
... | ... | @@ -246,14 +246,7 @@ |
246 | 246 | |
247 | 247 | #define CONFIG_SPLASHIMAGE_GUARD |
248 | 248 | |
249 | -/* GPIO banks */ | |
250 | -#ifdef CONFIG_LED_STATUS | |
251 | -#define CONFIG_OMAP3_GPIO_6 /* GPIO186 is in GPIO bank 6 */ | |
252 | -#endif | |
253 | - | |
254 | 249 | /* Display Configuration */ |
255 | -#define CONFIG_OMAP3_GPIO_2 | |
256 | -#define CONFIG_OMAP3_GPIO_5 | |
257 | 250 | #define CONFIG_VIDEO_OMAP3 |
258 | 251 | #define LCD_BPP LCD_COLOR16 |
259 | 252 |
include/configs/cm_t3517.h
... | ... | @@ -247,14 +247,7 @@ |
247 | 247 | /* Status LED */ |
248 | 248 | #define GREEN_LED_GPIO 186 /* CM-T3517 Green LED is GPIO186 */ |
249 | 249 | |
250 | -/* GPIO banks */ | |
251 | -#ifdef CONFIG_LED_STATUS | |
252 | -#define CONFIG_OMAP3_GPIO_6 /* GPIO186 is in GPIO bank 6 */ | |
253 | -#endif | |
254 | - | |
255 | 250 | /* Display Configuration */ |
256 | -#define CONFIG_OMAP3_GPIO_2 | |
257 | -#define CONFIG_OMAP3_GPIO_5 | |
258 | 251 | #define CONFIG_VIDEO_OMAP3 |
259 | 252 | #define LCD_BPP LCD_COLOR16 |
260 | 253 |
include/configs/mcx.h
include/configs/mt_ventoux.h
include/configs/omap3_beagle.h
... | ... | @@ -66,10 +66,6 @@ |
66 | 66 | #define CONFIG_USB_ETHER_MCS7830 |
67 | 67 | #define CONFIG_USB_ETHER_SMSC95XX |
68 | 68 | |
69 | -/* GPIO banks */ | |
70 | -#define CONFIG_OMAP3_GPIO_5 /* GPIO128..159 is in GPIO bank 5 */ | |
71 | -#define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO bank 6 */ | |
72 | - | |
73 | 69 | /* commands to include */ |
74 | 70 | |
75 | 71 | #define MTDIDS_DEFAULT "nand0=nand" |
include/configs/omap3_igep00x0.h
... | ... | @@ -37,11 +37,6 @@ |
37 | 37 | #endif |
38 | 38 | #endif |
39 | 39 | |
40 | -/* GPIO banks */ | |
41 | -#define CONFIG_OMAP3_GPIO_3 /* GPIO64 .. 95 is in GPIO bank 3 */ | |
42 | -#define CONFIG_OMAP3_GPIO_5 /* GPIO128..159 is in GPIO bank 5 */ | |
43 | -#define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO bank 6 */ | |
44 | - | |
45 | 40 | /* USB */ |
46 | 41 | #define CONFIG_USB_MUSB_UDC 1 |
47 | 42 | #define CONFIG_USB_OMAP3 1 |
include/configs/omap3_logic.h
... | ... | @@ -49,10 +49,6 @@ |
49 | 49 | |
50 | 50 | /* Hardware drivers */ |
51 | 51 | |
52 | -/* GPIO banks */ | |
53 | -#define CONFIG_OMAP3_GPIO_4 /* GPIO 96..128 is in GPIO bank 4 */ | |
54 | -#define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO bank 6 */ | |
55 | - | |
56 | 52 | #define CONFIG_USB_OMAP3 |
57 | 53 | |
58 | 54 | /* commands to include */ |
include/configs/omap3_overo.h
... | ... | @@ -45,13 +45,6 @@ |
45 | 45 | #define CONFIG_OMAP_EHCI_PHY1_RESET_GPIO 183 |
46 | 46 | #define CONFIG_SYS_USB_EHCI_MAX_ROOT_PORTS 3 |
47 | 47 | |
48 | -/* Initialize GPIOs by default */ | |
49 | -#define CONFIG_OMAP3_GPIO_2 /* GPIO32..63 is in GPIO Bank 2 */ | |
50 | -#define CONFIG_OMAP3_GPIO_3 /* GPIO64..95 is in GPIO Bank 3 */ | |
51 | -#define CONFIG_OMAP3_GPIO_4 /* GPIO96..127 is in GPIO Bank 4 */ | |
52 | -#define CONFIG_OMAP3_GPIO_5 /* GPIO128..159 is in GPIO Bank 5 */ | |
53 | -#define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO Bank 6 */ | |
54 | - | |
55 | 48 | /* commands to include */ |
56 | 49 | |
57 | 50 | #ifdef CONFIG_NAND |
include/configs/omap3_pandora.h
... | ... | @@ -35,10 +35,6 @@ |
35 | 35 | /* TWL4030 LED */ |
36 | 36 | #define CONFIG_TWL4030_LED |
37 | 37 | |
38 | -/* Initialize GPIOs by default */ | |
39 | -#define CONFIG_OMAP3_GPIO_4 /* GPIO96..127 is in GPIO Bank 4 */ | |
40 | -#define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO Bank 6 */ | |
41 | - | |
42 | 38 | /* |
43 | 39 | * NS16550 Configuration |
44 | 40 | */ |
include/configs/sniper.h
... | ... | @@ -56,15 +56,6 @@ |
56 | 56 | #define CONFIG_SYS_MALLOC_LEN (1024 * 1024 + CONFIG_ENV_SIZE) |
57 | 57 | |
58 | 58 | /* |
59 | - * GPIO | |
60 | - */ | |
61 | -#define CONFIG_OMAP3_GPIO_2 | |
62 | -#define CONFIG_OMAP3_GPIO_3 | |
63 | -#define CONFIG_OMAP3_GPIO_4 | |
64 | -#define CONFIG_OMAP3_GPIO_5 | |
65 | -#define CONFIG_OMAP3_GPIO_6 | |
66 | - | |
67 | -/* | |
68 | 59 | * I2C |
69 | 60 | */ |
70 | 61 |
include/configs/tam3517-common.h
... | ... | @@ -67,8 +67,6 @@ |
67 | 67 | #define CONFIG_SYS_BAUDRATE_TABLE {4800, 9600, 19200, 38400, 57600,\ |
68 | 68 | 115200} |
69 | 69 | /* EHCI */ |
70 | -#define CONFIG_OMAP3_GPIO_5 | |
71 | -#define CONFIG_USB_EHCI | |
72 | 70 | #define CONFIG_USB_EHCI_OMAP |
73 | 71 | #define CONFIG_OMAP_EHCI_PHY1_RESET_GPIO 25 |
74 | 72 | #define CONFIG_SYS_USB_EHCI_MAX_ROOT_PORTS 3 |
include/configs/tao3530.h
... | ... | @@ -61,13 +61,6 @@ |
61 | 61 | /* allow to overwrite serial and ethaddr */ |
62 | 62 | #define CONFIG_ENV_OVERWRITE |
63 | 63 | |
64 | -/* GPIO banks */ | |
65 | -#define CONFIG_OMAP3_GPIO_2 /* GPIO32 ..63 is in GPIO bank 2 */ | |
66 | -#define CONFIG_OMAP3_GPIO_3 /* GPIO64 ..95 is in GPIO bank 3 */ | |
67 | -#define CONFIG_OMAP3_GPIO_4 /* GPIO96 ..127 is in GPIO bank 4 */ | |
68 | -#define CONFIG_OMAP3_GPIO_5 /* GPIO128..159 is in GPIO bank 5 */ | |
69 | -#define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO bank 6 */ | |
70 | - | |
71 | 64 | /* commands to include */ |
72 | 65 | #define CONFIG_CMD_MTDPARTS /* Enable MTD parts commands */ |
73 | 66 | #define CONFIG_MTD_DEVICE /* needed for mtdparts commands */ |
include/configs/tricorder.h
... | ... | @@ -46,11 +46,6 @@ |
46 | 46 | |
47 | 47 | /* Hardware drivers */ |
48 | 48 | |
49 | -/* GPIO banks */ | |
50 | -#define CONFIG_OMAP3_GPIO_2 /* GPIO32..63 are in GPIO bank 2 */ | |
51 | - | |
52 | -/* LED support */ | |
53 | - | |
54 | 49 | /* NS16550 Configuration */ |
55 | 50 | #define CONFIG_SYS_NS16550_SERIAL |
56 | 51 | #define CONFIG_SYS_NS16550_REG_SIZE (-4) |
include/configs/twister.h
scripts/config_whitelist.txt
... | ... | @@ -1979,11 +1979,6 @@ |
1979 | 1979 | CONFIG_OF_SPI_FLASH |
1980 | 1980 | CONFIG_OF_STDOUT_PATH |
1981 | 1981 | CONFIG_OF_SUPPORT_OLD_DEVICE_TREES |
1982 | -CONFIG_OMAP3_GPIO_2 | |
1983 | -CONFIG_OMAP3_GPIO_3 | |
1984 | -CONFIG_OMAP3_GPIO_4 | |
1985 | -CONFIG_OMAP3_GPIO_5 | |
1986 | -CONFIG_OMAP3_GPIO_6 | |
1987 | 1982 | CONFIG_OMAP3_LOGIC_USE_NEW_PRODUCT_ID |
1988 | 1983 | CONFIG_OMAP3_MICRON_DDR |
1989 | 1984 | CONFIG_OMAP3_SPI_D0_D1_SWAPPED |