diff options
Diffstat (limited to 'sound/soc/codecs/twl4030.c')
| -rw-r--r-- | sound/soc/codecs/twl4030.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/soc/codecs/twl4030.c b/sound/soc/codecs/twl4030.c index 63ebd176fbe4..df474a5dd357 100644 --- a/sound/soc/codecs/twl4030.c +++ b/sound/soc/codecs/twl4030.c | |||
| @@ -145,7 +145,6 @@ struct twl4030_priv { | |||
| 145 | static inline unsigned int twl4030_read_reg_cache(struct snd_soc_codec *codec, | 145 | static inline unsigned int twl4030_read_reg_cache(struct snd_soc_codec *codec, |
| 146 | unsigned int reg) | 146 | unsigned int reg) |
| 147 | { | 147 | { |
| 148 | u8 *cache = codec->reg_cache; | ||
| 149 | 148 | ||
| 150 | if (reg >= TWL4030_CACHEREGNUM) | 149 | if (reg >= TWL4030_CACHEREGNUM) |
| 151 | return -EIO; | 150 | return -EIO; |
| @@ -204,6 +203,7 @@ static void twl4030_codec_enable(struct snd_soc_codec *codec, int enable) | |||
| 204 | 203 | ||
| 205 | static void twl4030_init_chip(struct snd_soc_codec *codec) | 204 | static void twl4030_init_chip(struct snd_soc_codec *codec) |
| 206 | { | 205 | { |
| 206 | u8 *cache = codec->reg_cache; | ||
| 207 | int i; | 207 | int i; |
| 208 | 208 | ||
| 209 | /* clear CODECPDZ prior to setting register defaults */ | 209 | /* clear CODECPDZ prior to setting register defaults */ |
| @@ -211,7 +211,7 @@ static void twl4030_init_chip(struct snd_soc_codec *codec) | |||
| 211 | 211 | ||
| 212 | /* set all audio section registers to reasonable defaults */ | 212 | /* set all audio section registers to reasonable defaults */ |
| 213 | for (i = TWL4030_REG_OPTION; i <= TWL4030_REG_MISC_SET_2; i++) | 213 | for (i = TWL4030_REG_OPTION; i <= TWL4030_REG_MISC_SET_2; i++) |
| 214 | twl4030_write(codec, i, twl4030_reg[i]); | 214 | twl4030_write(codec, i, cache[i]); |
| 215 | 215 | ||
| 216 | } | 216 | } |
| 217 | 217 | ||
