diff options
author | Russell King <rmk+kernel@arm.linux.org.uk> | 2011-12-19 23:00:22 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-01-26 20:57:24 +0100 |
commit | d9dc878769f521f494d1617d7cd0c92073df75d8 (patch) | |
tree | 79e79c50c211af91e48f38a7beed61e7425495bc /drivers/pcmcia/soc_common.h | |
parent | PCMCIA: soc_common: move common initialization into soc_common (diff) | |
download | linux-d9dc878769f521f494d1617d7cd0c92073df75d8.tar.xz linux-d9dc878769f521f494d1617d7cd0c92073df75d8.zip |
PCMCIA: soc_common: add GPIO support for card status signals
Add GPIO support for reading the card status (card detect, ready,
battery voltage detect) signals into soc_common code. As we want
interrupts from these GPIOs, this takes over the old irq handling
infrastructure for card status signals, which will now be managed
entirely by the soc_common code.
Acked-by: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/pcmcia/soc_common.h')
-rw-r--r-- | drivers/pcmcia/soc_common.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/pcmcia/soc_common.h b/drivers/pcmcia/soc_common.h index 3ff7ead11b1d..ebdfa6c16308 100644 --- a/drivers/pcmcia/soc_common.h +++ b/drivers/pcmcia/soc_common.h @@ -50,6 +50,16 @@ struct soc_pcmcia_socket { struct resource res_attr; void __iomem *virt_io; + struct { + int gpio; + unsigned int irq; + const char *name; + } stat[4]; +#define SOC_STAT_CD 0 /* Card detect */ +#define SOC_STAT_BVD1 1 /* BATDEAD / IOSTSCHG */ +#define SOC_STAT_BVD2 2 /* BATWARN / IOSPKR */ +#define SOC_STAT_RDY 3 /* Ready / Interrupt */ + unsigned int irq_state; struct timer_list poll_timer; |