wm9712.c (b3e5ced63e051e8f911b795ac5b06229a5328f7b) wm9712.c (bd1204cb51f15d202f95222e873a94ed5d07b784)
1/*
2 * wm9712.c -- ALSA Soc WM9712 codec support
3 *
4 * Copyright 2006-12 Wolfson Microelectronics PLC.
5 * Author: Liam Girdwood <lrg@slimlogic.co.uk>
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the

--- 632 unchanged lines hidden (view full) ---

641 struct wm9712_priv *wm9712 = snd_soc_codec_get_drvdata(codec);
642 int i, ret;
643 u16 *cache = codec->reg_cache;
644
645 ret = wm9712_reset(codec, 1);
646 if (ret < 0)
647 return ret;
648
1/*
2 * wm9712.c -- ALSA Soc WM9712 codec support
3 *
4 * Copyright 2006-12 Wolfson Microelectronics PLC.
5 * Author: Liam Girdwood <lrg@slimlogic.co.uk>
6 *
7 * This program is free software; you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the

--- 632 unchanged lines hidden (view full) ---

641 struct wm9712_priv *wm9712 = snd_soc_codec_get_drvdata(codec);
642 int i, ret;
643 u16 *cache = codec->reg_cache;
644
645 ret = wm9712_reset(codec, 1);
646 if (ret < 0)
647 return ret;
648
649 wm9712_set_bias_level(codec, SND_SOC_BIAS_STANDBY);
649 snd_soc_codec_force_bias_level(codec, SND_SOC_BIAS_STANDBY);
650
651 if (ret == 0) {
652 /* Sync reg_cache with the hardware after cold reset */
653 for (i = 2; i < ARRAY_SIZE(wm9712_reg) << 1; i += 2) {
654 if (i == AC97_INT_PAGING || i == AC97_POWERDOWN ||
655 (i > 0x58 && i != 0x5c))
656 continue;
657 soc_ac97_ops->write(wm9712->ac97, i, cache[i>>1]);

--- 101 unchanged lines hidden ---
650
651 if (ret == 0) {
652 /* Sync reg_cache with the hardware after cold reset */
653 for (i = 2; i < ARRAY_SIZE(wm9712_reg) << 1; i += 2) {
654 if (i == AC97_INT_PAGING || i == AC97_POWERDOWN ||
655 (i > 0x58 && i != 0x5c))
656 continue;
657 soc_ac97_ops->write(wm9712->ac97, i, cache[i>>1]);

--- 101 unchanged lines hidden ---