summaryrefslogtreecommitdiffstats
path: root/firmware/drivers/audio
diff options
context:
space:
mode:
authorAmaury Pouly <amaury.pouly@gmail.com>2012-02-03 19:58:25 +0100
committerAmaury Pouly <amaury.pouly@gmail.com>2012-02-03 20:04:39 +0100
commit1a083cdaccb3598de834c3643c5bc02716af804d (patch)
tree05536822b84d48e1d5d71954646b7ae52e03f04a /firmware/drivers/audio
parent7d54ff069ba36702b58d1dd6bb8a8ab03297f9e2 (diff)
downloadrockbox-1a083cdaccb3598de834c3643c5bc02716af804d.tar.gz
rockbox-1a083cdaccb3598de834c3643c5bc02716af804d.zip
imx233/fuze+: fix a typo, handle volume differently because of the line1/dac mode difference.
The headphone volume register value reads differently in Line1 and DAC mode. Since the volume is not set again when switching between playback and radio, we need to remember the hp volume and reapply setting when changing the mode. Change-Id: I8fbd344f78653c19d81a39dd3f680ec6885cb1ec
Diffstat (limited to 'firmware/drivers/audio')
-rw-r--r--firmware/drivers/audio/imx233-codec.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/firmware/drivers/audio/imx233-codec.c b/firmware/drivers/audio/imx233-codec.c
index d99a4d0ca9..20edf005e8 100644
--- a/firmware/drivers/audio/imx233-codec.c
+++ b/firmware/drivers/audio/imx233-codec.c
@@ -69,9 +69,7 @@ void audiohw_close(void)
void audiohw_set_headphone_vol(int vol_l, int vol_r)
{
- /* Use playback volume if <0 and headphone volume if >0 */
- imx233_audioout_set_dac_vol(MIN(0, vol_l), MIN(0, vol_r));
- imx233_audioout_set_hp_vol(MAX(0, vol_l), MAX(0, vol_r));
+ imx233_audioout_set_hp_vol(vol_l, vol_r);
}
void audiohw_set_frequency(int fsel)