diff options
author | Hauke Mehrtens <hauke@hauke-m.de> | 2012-11-20 17:24:33 -0500 |
---|---|---|
committer | John Crispin <blogic@openwrt.org> | 2012-11-21 15:55:52 -0500 |
commit | ec43b08b5733494ad88aa618ecdf534320dd8207 (patch) | |
tree | 0d11a7fca2c2baef2d8d3b14564f747b6319c20a /include/linux/ssb | |
parent | 394bc7e38be79987ed15de203920c3cddb724cc1 (diff) |
ssb: add GPIO driver
Register a GPIO driver to access the GPIOs provided by the chip.
The GPIOs of the SoC should always start at 0 and the other GPIOs could
start at a random position. There is just one SoC in a system and when
they start at 0 the number is predictable.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
Patchwork: http://patchwork.linux-mips.org/patch/4591
Acked-by: Florian Fainelli <florian@openwrt.org>
Diffstat (limited to 'include/linux/ssb')
-rw-r--r-- | include/linux/ssb/ssb.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/ssb/ssb.h b/include/linux/ssb/ssb.h index bb674c02f306..3862a5bbd73b 100644 --- a/include/linux/ssb/ssb.h +++ b/include/linux/ssb/ssb.h | |||
@@ -6,6 +6,7 @@ | |||
6 | #include <linux/types.h> | 6 | #include <linux/types.h> |
7 | #include <linux/spinlock.h> | 7 | #include <linux/spinlock.h> |
8 | #include <linux/pci.h> | 8 | #include <linux/pci.h> |
9 | #include <linux/gpio.h> | ||
9 | #include <linux/mod_devicetable.h> | 10 | #include <linux/mod_devicetable.h> |
10 | #include <linux/dma-mapping.h> | 11 | #include <linux/dma-mapping.h> |
11 | 12 | ||
@@ -433,6 +434,9 @@ struct ssb_bus { | |||
433 | /* Lock for GPIO register access. */ | 434 | /* Lock for GPIO register access. */ |
434 | spinlock_t gpio_lock; | 435 | spinlock_t gpio_lock; |
435 | #endif /* EMBEDDED */ | 436 | #endif /* EMBEDDED */ |
437 | #ifdef CONFIG_SSB_DRIVER_GPIO | ||
438 | struct gpio_chip gpio; | ||
439 | #endif /* DRIVER_GPIO */ | ||
436 | 440 | ||
437 | /* Internal-only stuff follows. Do not touch. */ | 441 | /* Internal-only stuff follows. Do not touch. */ |
438 | struct list_head list; | 442 | struct list_head list; |