Commit 2b58e1b76d2630f67e642a273f0975a11ead428d

Authored by Masahiro Yamada
Committed by Marek Vasut
1 parent 96d8284bd5

usb: add (move) CONFIG_USB_HOST to Kconfig

The meaning of CONFIG_USB in U-Boot is different from that in Linux.

As you see in drivers/usb/Kconfig of Linux, CONFIG_USB enables the
USB host controller support, while CONFIG_USB_SUPPORT is used to
enable the whole of the USB sub-system.

When I added CONFIG_USB into Kconfig by commit 6e7e9294d321 ("usb:
add basic USB configs in Kconfig"), I planned to follow the Linux's
convention, i.e. CONFIG_USB to enable/disable the USB host support.

Then, commit 68f7c5db2d1e ("usb: Generic USB Kconfig option, that
fits both host and gadget and comments") changed the logic of the
CONFIG_USB to point to the whole of the USB sub-system.  As a result,
currently we do not have an option for USB host.

This commit adds CONFIG_USB_HOST, which will be useful to compile
in the USB host support code.

CONFIG_USB_HOST is not referenced at all, but strangely some boards
define it in board headers.  I removed them because USB_HOST will be
selected in Kconfig going forward.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>

Showing 9 changed files with 7 additions and 8 deletions Side-by-side Diff

drivers/usb/host/Kconfig
... ... @@ -3,8 +3,12 @@
3 3 #
4 4 comment "USB Host Controller Drivers"
5 5  
  6 +config USB_HOST
  7 + bool
  8 +
6 9 config USB_XHCI_HCD
7 10 bool "xHCI HCD (USB 3.0) support"
  11 + select USB_HOST
8 12 ---help---
9 13 The eXtensible Host Controller Interface (xHCI) is standard for USB 3.0
10 14 "SuperSpeed" host controller hardware.
... ... @@ -28,6 +32,7 @@
28 32  
29 33 config USB_EHCI_HCD
30 34 bool "EHCI HCD (USB 2.0) support"
  35 + select USB_HOST
31 36 ---help---
32 37 The Enhanced Host Controller Interface (EHCI) is standard for USB 2.0
33 38 "high speed" (480 Mbit/sec, 60 Mbyte/sec) host controller hardware.
... ... @@ -128,6 +133,7 @@
128 133 bool "Support for generic OHCI USB controller"
129 134 depends on OF_CONTROL
130 135 depends on DM_USB
  136 + select USB_HOST
131 137 ---help---
132 138 Enables support for generic OHCI controller.
133 139  
... ... @@ -135,6 +141,7 @@
135 141  
136 142 config USB_UHCI_HCD
137 143 bool "UHCI HCD (most Intel and VIA) support"
  144 + select USB_HOST
138 145 ---help---
139 146 The Universal Host Controller Interface is a standard by Intel for
140 147 accessing the USB hardware in the PC (which is also called the USB
include/configs/am43xx_evm.h
... ... @@ -98,7 +98,6 @@
98 98  
99 99 #if defined(CONFIG_SPL_USB_HOST_SUPPORT) || !defined(CONFIG_SPL_BUILD)
100 100 #define CONFIG_SYS_USB_FAT_BOOT_PARTITION 1
101   -#define CONFIG_USB_HOST
102 101 #define CONFIG_USB_XHCI_OMAP
103 102 #define CONFIG_USB_STORAGE
104 103 #define CONFIG_SYS_USB_XHCI_MAX_ROOT_PORTS 2
include/configs/am57xx_evm.h
... ... @@ -63,7 +63,6 @@
63 63 #define CONFIG_SUPPORT_EMMC_BOOT
64 64  
65 65 /* USB xHCI HOST */
66   -#define CONFIG_USB_HOST
67 66 #define CONFIG_USB_XHCI_OMAP
68 67 #define CONFIG_USB_STORAGE
69 68 #define CONFIG_SYS_USB_XHCI_MAX_ROOT_PORTS 2
include/configs/cm_t43.h
... ... @@ -60,7 +60,6 @@
60 60 #define CONFIG_SYS_RX_ETH_BUFFER 64
61 61  
62 62 /* USB support */
63   -#define CONFIG_USB_HOST
64 63 #define CONFIG_USB_XHCI_OMAP
65 64 #define CONFIG_USB_STORAGE
66 65 #define CONFIG_SYS_USB_XHCI_MAX_ROOT_PORTS 2
include/configs/cm_t54.h
... ... @@ -69,7 +69,6 @@
69 69 #define CONFIG_SYS_SCSI_MAX_DEVICE (CONFIG_SYS_SCSI_MAX_SCSI_ID * \
70 70 CONFIG_SYS_SCSI_MAX_LUN)
71 71 /* USB UHH support options */
72   -#define CONFIG_USB_HOST
73 72 #define CONFIG_USB_EHCI
74 73 #define CONFIG_USB_EHCI_OMAP
75 74 #define CONFIG_USB_STORAGE
include/configs/dra7xx_evm.h
... ... @@ -209,7 +209,6 @@
209 209 #define CONFIG_SUPPORT_EMMC_BOOT
210 210  
211 211 /* USB xHCI HOST */
212   -#define CONFIG_USB_HOST
213 212 #define CONFIG_USB_XHCI_OMAP
214 213 #define CONFIG_USB_STORAGE
215 214 #define CONFIG_SYS_USB_XHCI_MAX_ROOT_PORTS 2
include/configs/duovero.h
... ... @@ -29,7 +29,6 @@
29 29 #define CONFIG_SYS_DEFAULT_LPDDR2_TIMINGS
30 30  
31 31 /* USB UHH support options */
32   -#define CONFIG_USB_HOST
33 32 #define CONFIG_USB_EHCI
34 33 #define CONFIG_USB_EHCI_OMAP
35 34 #define CONFIG_USB_STORAGE
include/configs/omap4_panda.h
... ... @@ -17,7 +17,6 @@
17 17 */
18 18  
19 19 /* USB UHH support options */
20   -#define CONFIG_USB_HOST
21 20 #define CONFIG_USB_EHCI
22 21 #define CONFIG_USB_EHCI_OMAP
23 22 #define CONFIG_USB_STORAGE
include/configs/omap5_uevm.h
... ... @@ -88,7 +88,6 @@
88 88 #define CONFIG_SYS_I2C_TCA642X_ADDR 0x22
89 89  
90 90 /* USB UHH support options */
91   -#define CONFIG_USB_HOST
92 91 #define CONFIG_USB_EHCI
93 92 #define CONFIG_USB_EHCI_OMAP
94 93 #define CONFIG_USB_STORAGE