If power down command to AIC23 is sent after the clocks are stopped,
the chip remains in a state where it's consuming some extra milliamps.
Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com>
Signed-off-by: Juha Yrjola <juha.yrjola@nokia.com>
down(&audio_pwr_sem);
if (audio_pwr_state == -1)
tlv320aic23_power_down();
+ clk_disable(dspxor_ck);
up(&audio_pwr_sem);
}
static void nokia770_audio_pwr_down(void)
{
- clk_disable(dspxor_ck);
-
/* Turn off amplifier */
omap_set_gpio_dataout(AMPLIFIER_CTRL_GPIO, 0);
{
down(&audio_pwr_sem);
switch (stage) {
- case 1:
- if (audio_pwr_state == 0)
- audio_pwr_state = 1;
- break;
- case 2:
- if (audio_pwr_state == 1) {
- nokia770_audio_pwr_down();
- audio_pwr_state = -1;
- }
- break;
+ case 1:
+ if (audio_pwr_state == 0)
+ audio_pwr_state = 1;
+ break;
+ case 2:
+ if (audio_pwr_state == 1) {
+ nokia770_audio_pwr_down();
+ audio_pwr_state = -1;
+ }
+ break;
}
up(&audio_pwr_sem);
}