@@ -697,6 +697,7 @@ static int out_pga_event(struct snd_soc_dapm_widget *w,
697
697
int dcs_mask ;
698
698
int dcs_l , dcs_r ;
699
699
int dcs_l_reg , dcs_r_reg ;
700
+ int an_out_reg ;
700
701
int timeout ;
701
702
int pwr_reg ;
702
703
@@ -712,6 +713,7 @@ static int out_pga_event(struct snd_soc_dapm_widget *w,
712
713
dcs_mask = WM8904_DCS_ENA_CHAN_0 | WM8904_DCS_ENA_CHAN_1 ;
713
714
dcs_r_reg = WM8904_DC_SERVO_8 ;
714
715
dcs_l_reg = WM8904_DC_SERVO_9 ;
716
+ an_out_reg = WM8904_ANALOGUE_OUT1_LEFT ;
715
717
dcs_l = 0 ;
716
718
dcs_r = 1 ;
717
719
break ;
@@ -720,6 +722,7 @@ static int out_pga_event(struct snd_soc_dapm_widget *w,
720
722
dcs_mask = WM8904_DCS_ENA_CHAN_2 | WM8904_DCS_ENA_CHAN_3 ;
721
723
dcs_r_reg = WM8904_DC_SERVO_6 ;
722
724
dcs_l_reg = WM8904_DC_SERVO_7 ;
725
+ an_out_reg = WM8904_ANALOGUE_OUT2_LEFT ;
723
726
dcs_l = 2 ;
724
727
dcs_r = 3 ;
725
728
break ;
@@ -792,6 +795,10 @@ static int out_pga_event(struct snd_soc_dapm_widget *w,
792
795
snd_soc_component_update_bits (component , reg ,
793
796
WM8904_HPL_ENA_OUTP | WM8904_HPR_ENA_OUTP ,
794
797
WM8904_HPL_ENA_OUTP | WM8904_HPR_ENA_OUTP );
798
+
799
+ /* Update volume, requires PGA to be powered */
800
+ val = snd_soc_component_read (component , an_out_reg );
801
+ snd_soc_component_write (component , an_out_reg , val );
795
802
break ;
796
803
797
804
case SND_SOC_DAPM_POST_PMU :
0 commit comments