diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-12-05 11:10:15 -0500 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-12-05 11:13:31 -0500 |
commit | 209a600623cf13a8168b2f6b83643db7825abb9a (patch) | |
tree | 4e18c677d51bbdf6fc8771ca13b38c74431f1e4a /drivers/base | |
parent | d23511f9590870effa5ace575b59aac18c47175f (diff) |
regmap: Add irq_base accessor to regmap_irq
Allows devices to discover their own interrupt without having to remember
it themselves.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'drivers/base')
-rw-r--r-- | drivers/base/regmap/regmap-irq.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/base/regmap/regmap-irq.c b/drivers/base/regmap/regmap-irq.c index 6b8a74c3ed18..428836fc5835 100644 --- a/drivers/base/regmap/regmap-irq.c +++ b/drivers/base/regmap/regmap-irq.c | |||
@@ -287,3 +287,16 @@ void regmap_del_irq_chip(int irq, struct regmap_irq_chip_data *d) | |||
287 | kfree(d); | 287 | kfree(d); |
288 | } | 288 | } |
289 | EXPORT_SYMBOL_GPL(regmap_del_irq_chip); | 289 | EXPORT_SYMBOL_GPL(regmap_del_irq_chip); |
290 | |||
291 | /** | ||
292 | * regmap_irq_chip_get_base(): Retrieve interrupt base for a regmap IRQ chip | ||
293 | * | ||
294 | * Useful for drivers to request their own IRQs. | ||
295 | * | ||
296 | * @data: regmap_irq controller to operate on. | ||
297 | */ | ||
298 | int regmap_irq_chip_get_base(struct regmap_irq_chip_data *data) | ||
299 | { | ||
300 | return data->irq_base; | ||
301 | } | ||
302 | EXPORT_SYMBOL_GPL(regmap_irq_chip_get_base); | ||