Commit 6946e037 authored by Dimitris Papastamos's avatar Dimitris Papastamos Committed by Mark Brown

ASoC: Fix off-by-one bug in WM8962 register cache size configuration

This is a simple off-by-one bug, the size of the register cache is
incorrectly set to the maximum register index. Fix it by adding one.
Signed-off-by: default avatarDimitris Papastamos <dp@opensource.wolfsonmicro.com>
Acked-by: default avatarLiam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent e5eec34c
...@@ -1780,7 +1780,7 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8962 = { ...@@ -1780,7 +1780,7 @@ static struct snd_soc_codec_driver soc_codec_dev_wm8962 = {
.remove = wm8962_remove, .remove = wm8962_remove,
.resume = wm8962_resume, .resume = wm8962_resume,
.set_bias_level = wm8962_set_bias_level, .set_bias_level = wm8962_set_bias_level,
.reg_cache_size = WM8962_MAX_REGISTER, .reg_cache_size = WM8962_MAX_REGISTER + 1,
.reg_word_size = sizeof(u16), .reg_word_size = sizeof(u16),
.reg_cache_default = wm8962_reg, .reg_cache_default = wm8962_reg,
.volatile_register = wm8962_volatile_register, .volatile_register = wm8962_volatile_register,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment