aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mfd
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2012-06-03 08:37:22 -0400
committerSamuel Ortiz <sameo@linux.intel.com>2012-07-08 18:16:10 -0400
commit52b461b86a9f6c7a86bdcb858e1bbef089fbe6a0 (patch)
tree9c839b3ce945fb75249d0be0cbde503b44334351 /include/linux/mfd
parentb0ab907d325f99054eb2700a8f8c50776ebfeaf9 (diff)
mfd: Add regmap cache support for wm8350
Use the most simple possible transformation on the existing code so keep the table sitting around, further patches in this series will delete the existing cache code - the main purpose of this patch is to ensure that we always have a cache for bisection. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'include/linux/mfd')
-rw-r--r--include/linux/mfd/wm8350/core.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/linux/mfd/wm8350/core.h b/include/linux/mfd/wm8350/core.h
index 9192b6404a73..cba9bc8f947b 100644
--- a/include/linux/mfd/wm8350/core.h
+++ b/include/linux/mfd/wm8350/core.h
@@ -17,6 +17,7 @@
17#include <linux/mutex.h> 17#include <linux/mutex.h>
18#include <linux/interrupt.h> 18#include <linux/interrupt.h>
19#include <linux/completion.h> 19#include <linux/completion.h>
20#include <linux/regmap.h>
20 21
21#include <linux/mfd/wm8350/audio.h> 22#include <linux/mfd/wm8350/audio.h>
22#include <linux/mfd/wm8350/gpio.h> 23#include <linux/mfd/wm8350/gpio.h>
@@ -66,6 +67,9 @@
66 67
67#define WM8350_MAX_REGISTER 0xFF 68#define WM8350_MAX_REGISTER 0xFF
68 69
70#define WM8350_UNLOCK_KEY 0x0013
71#define WM8350_LOCK_KEY 0x0000
72
69/* 73/*
70 * Field Definitions. 74 * Field Definitions.
71 */ 75 */
@@ -582,6 +586,7 @@
582 586
583#define WM8350_NUM_IRQ_REGS 7 587#define WM8350_NUM_IRQ_REGS 7
584 588
589extern const struct regmap_config wm8350_regmap;
585struct wm8350_reg_access { 590struct wm8350_reg_access {
586 u16 readable; /* Mask of readable bits */ 591 u16 readable; /* Mask of readable bits */
587 u16 writable; /* Mask of writable bits */ 592 u16 writable; /* Mask of writable bits */
@@ -602,7 +607,6 @@ extern const u16 wm8352_mode2_defaults[];
602extern const u16 wm8352_mode3_defaults[]; 607extern const u16 wm8352_mode3_defaults[];
603 608
604struct wm8350; 609struct wm8350;
605struct regmap;
606 610
607struct wm8350_hwmon { 611struct wm8350_hwmon {
608 struct platform_device *pdev; 612 struct platform_device *pdev;
@@ -615,6 +619,7 @@ struct wm8350 {
615 /* device IO */ 619 /* device IO */
616 struct regmap *regmap; 620 struct regmap *regmap;
617 u16 *reg_cache; 621 u16 *reg_cache;
622 bool unlocked;
618 623
619 struct mutex auxadc_mutex; 624 struct mutex auxadc_mutex;
620 struct completion auxadc_done; 625 struct completion auxadc_done;