diff mbox

[2/2] ASoC: wm8753: Drop wm8753_writeable function

Message ID 1438394692.6442.2.camel@ingics.com (mailing list archive)
State Accepted
Commit b970499878563437a43eab2dd2faa9217142fb98
Headers show

Commit Message

Axel Lin Aug. 1, 2015, 2:04 a.m. UTC
When .max_register is set and .writeable_reg is not implement, registers
between 0 and .max_register are writeable. This is the same as current
implementation of wm8753_writeable(), so just drop implementation for
.writeable_reg callback.

Signed-off-by: Axel Lin <axel.lin@ingics.com>
---
 sound/soc/codecs/wm8753.c | 6 ------
 1 file changed, 6 deletions(-)

Comments

Charles Keepax Aug. 6, 2015, 4:24 p.m. UTC | #1
On Sat, Aug 01, 2015 at 10:04:52AM +0800, Axel Lin wrote:
> When .max_register is set and .writeable_reg is not implement, registers
> between 0 and .max_register are writeable. This is the same as current
> implementation of wm8753_writeable(), so just drop implementation for
> .writeable_reg callback.
> 
> Signed-off-by: Axel Lin <axel.lin@ingics.com>
> ---

Acked-by: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>

Thanks,
Charles
diff mbox

Patch

diff --git a/sound/soc/codecs/wm8753.c b/sound/soc/codecs/wm8753.c
index b5e50ff..ab1b6b8 100644
--- a/sound/soc/codecs/wm8753.c
+++ b/sound/soc/codecs/wm8753.c
@@ -138,11 +138,6 @@  static bool wm8753_volatile(struct device *dev, unsigned int reg)
 	return reg == WM8753_RESET;
 }
 
-static bool wm8753_writeable(struct device *dev, unsigned int reg)
-{
-	return reg <= WM8753_ADCTL2;
-}
-
 /* codec private data */
 struct wm8753_priv {
 	struct regmap *regmap;
@@ -1510,7 +1505,6 @@  static const struct regmap_config wm8753_regmap = {
 	.val_bits = 9,
 
 	.max_register = WM8753_ADCTL2,
-	.writeable_reg = wm8753_writeable,
 	.volatile_reg = wm8753_volatile,
 
 	.cache_type = REGCACHE_RBTREE,