summaryrefslogtreecommitdiffstats
path: root/drivers/ssb/driver_chipcommon.c
diff options
context:
space:
mode:
authorAurelien Jarno <aurelien@aurel32.net>2008-02-22 16:14:58 +0100
committerJohn W. Linville <linville@tuxdriver.com>2008-02-29 21:41:43 +0100
commit28de57d1a9eb7e67badb731297197fcbef0cc19e (patch)
tree950fe43f059f03659c4fd87755a73610af5b20c4 /drivers/ssb/driver_chipcommon.c
parentmac80211: fix IBSS code (diff)
downloadlinux-28de57d1a9eb7e67badb731297197fcbef0cc19e.tar.xz
linux-28de57d1a9eb7e67badb731297197fcbef0cc19e.zip
ssb: Add CHIPCO IRQ access functions
This patch adds functions to setup and read the CHIPCO IRQ. Signed-off-by: Aurelien Jarno <aurelien@aurel32.net> Signed-off-by: Michael Buesch <mb@bu3sch.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/ssb/driver_chipcommon.c')
-rw-r--r--drivers/ssb/driver_chipcommon.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/ssb/driver_chipcommon.c b/drivers/ssb/driver_chipcommon.c
index e586321a473a..45b672a69003 100644
--- a/drivers/ssb/driver_chipcommon.c
+++ b/drivers/ssb/driver_chipcommon.c
@@ -353,6 +353,16 @@ void ssb_chipco_watchdog_timer_set(struct ssb_chipcommon *cc, u32 ticks)
chipco_write32(cc, SSB_CHIPCO_WATCHDOG, ticks);
}
+void ssb_chipco_irq_mask(struct ssb_chipcommon *cc, u32 mask, u32 value)
+{
+ chipco_write32_masked(cc, SSB_CHIPCO_IRQMASK, mask, value);
+}
+
+u32 ssb_chipco_irq_status(struct ssb_chipcommon *cc, u32 mask)
+{
+ return chipco_read32(cc, SSB_CHIPCO_IRQSTAT) & mask;
+}
+
u32 ssb_chipco_gpio_in(struct ssb_chipcommon *cc, u32 mask)
{
return chipco_read32(cc, SSB_CHIPCO_GPIOIN) & mask;