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>
This commit is contained in:
committed by
Samuel Ortiz
parent
bad76991d7
commit
b41511f713
@@ -23,6 +23,8 @@
|
||||
#define __LINUX_MFD_MAX8997_PRIV_H
|
||||
|
||||
#include <linux/i2c.h>
|
||||
#include <linux/export.h>
|
||||
#include <linux/irqdomain.h>
|
||||
|
||||
#define MAX8997_REG_INVALID (0xff)
|
||||
|
||||
@@ -325,7 +327,7 @@ struct max8997_dev {
|
||||
|
||||
int irq;
|
||||
int ono;
|
||||
int irq_base;
|
||||
struct irq_domain *irq_domain;
|
||||
struct mutex irqlock;
|
||||
int irq_masks_cur[MAX8997_IRQ_GROUP_NR];
|
||||
int irq_masks_cache[MAX8997_IRQ_GROUP_NR];
|
||||
|
||||
Reference in New Issue
Block a user