diff options
author | Thomas Abraham <thomas.abraham@linaro.org> | 2012-07-01 20:02:55 -0400 |
---|---|---|
committer | Samuel Ortiz <sameo@linux.intel.com> | 2012-07-08 18:16:13 -0400 |
commit | b41511f713ccaef666e450fae8cb18909897fe4e (patch) | |
tree | 078c2a625964f7769a1fecc4fa5f6cf24dc2df68 /include/linux/mfd | |
parent | bad76991d7847b7877ae797cc79745d82ffd9120 (diff) |
mfd: Add irq domain support for max8997 interrupts
Add irq domain support for max8997 interrupts. The reverse mapping method
used is linear mapping since the sub-drivers of max8997 such as regulator
and charger drivers can use the max8997 irq_domain to get the linux irq
number for max8997 interrupts. All uses of irq_base in platform data and
max8997 driver private data are removed.
Reviwed-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Thomas Abraham <thomas.abraham@linaro.org>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'include/linux/mfd')
-rw-r--r-- | include/linux/mfd/max8997-private.h | 4 | ||||
-rw-r--r-- | include/linux/mfd/max8997.h | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/include/linux/mfd/max8997-private.h b/include/linux/mfd/max8997-private.h index 3f4deb62d6b0..830152cfae33 100644 --- a/include/linux/mfd/max8997-private.h +++ b/include/linux/mfd/max8997-private.h | |||
@@ -23,6 +23,8 @@ | |||
23 | #define __LINUX_MFD_MAX8997_PRIV_H | 23 | #define __LINUX_MFD_MAX8997_PRIV_H |
24 | 24 | ||
25 | #include <linux/i2c.h> | 25 | #include <linux/i2c.h> |
26 | #include <linux/export.h> | ||
27 | #include <linux/irqdomain.h> | ||
26 | 28 | ||
27 | #define MAX8997_REG_INVALID (0xff) | 29 | #define MAX8997_REG_INVALID (0xff) |
28 | 30 | ||
@@ -325,7 +327,7 @@ struct max8997_dev { | |||
325 | 327 | ||
326 | int irq; | 328 | int irq; |
327 | int ono; | 329 | int ono; |
328 | int irq_base; | 330 | struct irq_domain *irq_domain; |
329 | struct mutex irqlock; | 331 | struct mutex irqlock; |
330 | int irq_masks_cur[MAX8997_IRQ_GROUP_NR]; | 332 | int irq_masks_cur[MAX8997_IRQ_GROUP_NR]; |
331 | int irq_masks_cache[MAX8997_IRQ_GROUP_NR]; | 333 | int irq_masks_cache[MAX8997_IRQ_GROUP_NR]; |
diff --git a/include/linux/mfd/max8997.h b/include/linux/mfd/max8997.h index b40c08cd30bc..328d8e24b533 100644 --- a/include/linux/mfd/max8997.h +++ b/include/linux/mfd/max8997.h | |||
@@ -181,7 +181,6 @@ struct max8997_led_platform_data { | |||
181 | 181 | ||
182 | struct max8997_platform_data { | 182 | struct max8997_platform_data { |
183 | /* IRQ */ | 183 | /* IRQ */ |
184 | int irq_base; | ||
185 | int ono; | 184 | int ono; |
186 | int wakeup; | 185 | int wakeup; |
187 | 186 | ||