summaryrefslogtreecommitdiffstats
path: root/include/linux/mfd/wm8350
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2012-05-07 10:03:21 +0100
committerSamuel Ortiz <sameo@linux.intel.com>2012-05-07 11:32:08 +0200
commitb7b142d9fc056e98e6fdef82dca3e87067517340 (patch)
treeb7ec58d3c576080cdf94435f9d227bf6496b8150 /include/linux/mfd/wm8350
parentce7e4e11221dd7fbe82c8ad28d1875b0dfa20de4 (diff)
mfd: Convert wm8350 physical I/O to regmap API
The driver still uses a custom cache implementation but the underlying physical I/O is now done using the regmap API, saving some code and avoiding allocating enormous scratch arrays on the stack. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'include/linux/mfd/wm8350')
-rw-r--r--include/linux/mfd/wm8350/core.h9
1 files changed, 2 insertions, 7 deletions
diff --git a/include/linux/mfd/wm8350/core.h b/include/linux/mfd/wm8350/core.h
index 98fcc977e82..9192b6404a7 100644
--- a/include/linux/mfd/wm8350/core.h
+++ b/include/linux/mfd/wm8350/core.h
@@ -602,6 +602,7 @@ extern const u16 wm8352_mode2_defaults[];
extern const u16 wm8352_mode3_defaults[];
struct wm8350;
+struct regmap;
struct wm8350_hwmon {
struct platform_device *pdev;
@@ -612,13 +613,7 @@ struct wm8350 {
struct device *dev;
/* device IO */
- union {
- struct i2c_client *i2c_client;
- struct spi_device *spi_device;
- };
- int (*read_dev)(struct wm8350 *wm8350, char reg, int size, void *dest);
- int (*write_dev)(struct wm8350 *wm8350, char reg, int size,
- void *src);
+ struct regmap *regmap;
u16 *reg_cache;
struct mutex auxadc_mutex;