diff options
| author | Thomas Abraham <thomas.abraham@linaro.org> | 2012-03-24 05:49:49 -0400 |
|---|---|---|
| committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-04-16 14:46:55 -0400 |
| commit | 98d8618af37728f6e18e84110ddb99987b47dd12 (patch) | |
| tree | b9b29685a18b2aaf4522b6a2d6fe9a77cf9b09e3 /include/linux | |
| parent | cd22a965c46e249843c049cbbfe3d9f12270ea2b (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.
Signed-off-by: Thomas Abraham <thomas.abraham@linaro.org>
Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Acked-by: Samuel Ortiz <sameo@linux.intel.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'include/linux')
| -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 28726dd540f2..24b1a76540da 100644 --- a/include/linux/mfd/max8997.h +++ b/include/linux/mfd/max8997.h | |||
| @@ -204,7 +204,6 @@ struct max8997_led_platform_data { | |||
| 204 | 204 | ||
| 205 | struct max8997_platform_data { | 205 | struct max8997_platform_data { |
| 206 | /* IRQ */ | 206 | /* IRQ */ |
| 207 | int irq_base; | ||
| 208 | int ono; | 207 | int ono; |
| 209 | int wakeup; | 208 | int wakeup; |
| 210 | 209 | ||
