diff options
author | Simon Glass <sjg@chromium.org> | 2014-02-26 15:59:24 -0700 |
---|---|---|
committer | Tom Rini <trini@ti.com> | 2014-03-04 12:15:30 -0500 |
commit | 96495d90fe0165cf0cc721083e5a0b83771e3509 (patch) | |
tree | f1d93e0352da249c7822c3291e3b02a33ba438a7 /drivers/gpio/Makefile | |
parent | 39f7611fecc55cbde02c8a84f7c12861abe31b53 (diff) | |
download | u-boot-imx-96495d90fe0165cf0cc721083e5a0b83771e3509.zip u-boot-imx-96495d90fe0165cf0cc721083e5a0b83771e3509.tar.gz u-boot-imx-96495d90fe0165cf0cc721083e5a0b83771e3509.tar.bz2 |
dm: Add GPIO support and tests
Add driver model support for GPIOs. Since existing GPIO drivers do not use
driver model, this feature must be enabled by CONFIG_DM_GPIO. After all
GPO drivers are converted over we can perhaps remove this config.
Tests are provided for the sandbox implementation, and are a sufficient
sanity check for basic operation.
The GPIO uclass understands the concept of named banks of GPIOs, with each
GPIO device providing a single bank. Within each bank the GPIOs are numbered
using an offset from 0 to n-1. For example a bank named 'b' with 20
offsets will provide GPIOs named b0 to b19.
Anonymous GPIO banks are also supported, and are just numbered without any
prefix.
Each time a GPIO driver is added to the uclass, the GPIOs are renumbered
accordinging, so there is always a global GPIO numbering order.
Signed-off-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Marek Vasut <marex@denx.de>
Signed-off-by: Pavel Herrmann <morpheus.ibis@gmail.com>
Signed-off-by: Viktor Křivák <viktor.krivak@gmail.com>
Signed-off-by: Tomas Hlavacek <tmshlvck@gmail.com>
Diffstat (limited to 'drivers/gpio/Makefile')
-rw-r--r-- | drivers/gpio/Makefile | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpio/Makefile b/drivers/gpio/Makefile index ed2c0c7..4e001e1 100644 --- a/drivers/gpio/Makefile +++ b/drivers/gpio/Makefile @@ -5,6 +5,8 @@ # SPDX-License-Identifier: GPL-2.0+ # +obj-$(CONFIG_DM_GPIO) += gpio-uclass.o + obj-$(CONFIG_AT91_GPIO) += at91_gpio.o obj-$(CONFIG_INTEL_ICH6_GPIO) += intel_ich6_gpio.o obj-$(CONFIG_KIRKWOOD_GPIO) += kw_gpio.o |