diff options
author | Simon Glass <sjg@chromium.org> | 2021-08-08 12:20:24 -0600 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2021-09-04 12:26:02 -0400 |
commit | b2f9bac0e703631b12f1e40c1a8b15345923a29a (patch) | |
tree | 798e90b42511d476d27569884a2f4ed2901e60c7 | |
parent | 80a4876c86bbf4c05ebe387d0cfa6236d444ebd9 (diff) | |
download | u-boot-b2f9bac0e703631b12f1e40c1a8b15345923a29a.zip u-boot-b2f9bac0e703631b12f1e40c1a8b15345923a29a.tar.gz u-boot-b2f9bac0e703631b12f1e40c1a8b15345923a29a.tar.bz2 |
gpio: Add a GPIO config
At present we have SPL_GPIO and TPL_GPIO but not piain GPIO. This
works because there is a special build rule in Makefile that always
includes the drivers/gpio directory.
It is better to have all driver directories included by drivers/Makefile
and there is already a rule in there for this purpose. It just needs a
Kconfig for U-Boot proper, so add one.
Enable the option always for now, since this mimics current behaviour.
This can be updated once DM_GPIO is used everywhere.
Signed-off-by: Simon Glass <sjg@chromium.org>
-rw-r--r-- | Makefile | 1 | ||||
-rw-r--r-- | drivers/gpio/Kconfig | 16 |
2 files changed, 14 insertions, 3 deletions
@@ -813,7 +813,6 @@ libs-y += fs/ libs-y += net/ libs-y += disk/ libs-y += drivers/ -libs-y += drivers/gpio/ libs-y += drivers/net/ libs-y += drivers/net/phy/ libs-y += drivers/power/ \ diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig index ab9adbd..afb4c69 100644 --- a/drivers/gpio/Kconfig +++ b/drivers/gpio/Kconfig @@ -2,7 +2,19 @@ # GPIO infrastructure and drivers # -menu "GPIO Support" +menuconfig GPIO + bool "GPIO support" + default y + help + Enable support for GPIOs (General-purpose Input/Output) in U-Boot. + GPIOs allow U-Boot to read the state of an input line (high or + low) and set the state of an output line. This can be used to + drive LEDs, control power to various system parts and read user + input. GPIOs can be useful to enable a 'sign-of-life' LED, + for example. Enable this option to build the drivers in + drivers/gpio as part of an U-Boot build. + +if GPIO config DM_GPIO bool "Enable Driver Model for GPIO drivers" @@ -503,4 +515,4 @@ config NOMADIK_GPIO into a number of banks each with 32 GPIOs. The GPIOs for a device are defined in the device tree with one node for each bank. -endmenu +endif |