blob: 995efc6d7f32ad80342d5875a34552fd0c6b3ce8 [file] [log] [blame]
Thomas Gleixnerd2912cb2019-06-04 10:11:33 +02001/* SPDX-License-Identifier: GPL-2.0-only */
Mark Brown3cc72982012-06-19 16:31:53 +01002/*
3 * wm5102.h -- WM5102 MFD internals
4 *
5 * Copyright 2012 Wolfson Microelectronics plc
6 *
7 * Author: Mark Brown <broonie@opensource.wolfsonmicro.com>
Mark Brown3cc72982012-06-19 16:31:53 +01008 */
9
10#ifndef _WM5102_H
11#define _WM5102_H
12
Mark Brownd7810092013-03-25 00:11:27 +000013#include <linux/of.h>
Mark Brown3cc72982012-06-19 16:31:53 +010014#include <linux/regmap.h>
15#include <linux/pm.h>
16
Mark Brown3cc72982012-06-19 16:31:53 +010017extern const struct regmap_config wm5102_i2c_regmap;
18extern const struct regmap_config wm5102_spi_regmap;
Mark Browne102bef2012-07-10 12:37:58 +010019
20extern const struct regmap_config wm5110_i2c_regmap;
21extern const struct regmap_config wm5110_spi_regmap;
22
Richard Fitzgeraldea1f3332015-11-03 15:08:32 +000023extern const struct regmap_config cs47l24_spi_regmap;
24
Charles Keepaxdc7d4862013-06-13 09:43:29 +010025extern const struct regmap_config wm8997_i2c_regmap;
26
Richard Fitzgerald6887b042015-07-03 16:16:35 +010027extern const struct regmap_config wm8998_i2c_regmap;
28
Mark Brown3cc72982012-06-19 16:31:53 +010029extern const struct dev_pm_ops arizona_pm_ops;
30
Mark Brownd7810092013-03-25 00:11:27 +000031extern const struct of_device_id arizona_of_match[];
32
Mark Brown3cc72982012-06-19 16:31:53 +010033extern const struct regmap_irq_chip wm5102_aod;
34extern const struct regmap_irq_chip wm5102_irq;
35
Mark Browne102bef2012-07-10 12:37:58 +010036extern const struct regmap_irq_chip wm5110_aod;
37extern const struct regmap_irq_chip wm5110_irq;
Charles Keepax32155012014-07-15 11:21:48 +010038extern const struct regmap_irq_chip wm5110_revd_irq;
Mark Browne102bef2012-07-10 12:37:58 +010039
Richard Fitzgeraldea1f3332015-11-03 15:08:32 +000040extern const struct regmap_irq_chip cs47l24_irq;
41
Charles Keepaxdc7d4862013-06-13 09:43:29 +010042extern const struct regmap_irq_chip wm8997_aod;
43extern const struct regmap_irq_chip wm8997_irq;
44
Richard Fitzgerald6887b042015-07-03 16:16:35 +010045extern struct regmap_irq_chip wm8998_aod;
46extern struct regmap_irq_chip wm8998_irq;
47
Mark Brown3cc72982012-06-19 16:31:53 +010048int arizona_dev_init(struct arizona *arizona);
49int arizona_dev_exit(struct arizona *arizona);
50int arizona_irq_init(struct arizona *arizona);
51int arizona_irq_exit(struct arizona *arizona);
52
Mark Brownd7810092013-03-25 00:11:27 +000053#ifdef CONFIG_OF
Lee Jones942786e2014-07-02 14:28:46 +010054unsigned long arizona_of_get_type(struct device *dev);
Mark Brownd7810092013-03-25 00:11:27 +000055#else
Lee Jones942786e2014-07-02 14:28:46 +010056static inline unsigned long arizona_of_get_type(struct device *dev)
Mark Brownd7810092013-03-25 00:11:27 +000057{
58 return 0;
59}
60#endif
61
Mark Brown3cc72982012-06-19 16:31:53 +010062#endif