summaryrefslogtreecommitdiff
path: root/firmware/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/drivers')
-rw-r--r--firmware/drivers/audio/aic3x.c10
-rw-r--r--firmware/drivers/audio/ak4537.c15
-rw-r--r--firmware/drivers/audio/imx233-codec.c2
-rw-r--r--firmware/drivers/audio/mas35xx.c2
-rw-r--r--firmware/drivers/audio/wm8731.c23
5 files changed, 2 insertions, 50 deletions
diff --git a/firmware/drivers/audio/aic3x.c b/firmware/drivers/audio/aic3x.c
index 08c4db3..60330f1 100644
--- a/firmware/drivers/audio/aic3x.c
+++ b/firmware/drivers/audio/aic3x.c
@@ -33,16 +33,6 @@
static char volume_left = 0, volume_right = 0;
-const struct sound_settings_info audiohw_settings[] = {
- [SOUND_VOLUME] = {"dB", 0, 1, VOLUME_MIN/10, VOLUME_MAX/10, -25},
- /* HAVE_SW_TONE_CONTROLS */
- [SOUND_BASS] = {"dB", 0, 1, -24, 24, 0},
- [SOUND_TREBLE] = {"dB", 0, 1, -24, 24, 0},
- [SOUND_BALANCE] = {"%", 0, 1,-100, 100, 0},
- [SOUND_CHANNELS] = {"", 0, 1, 0, 5, 0},
- [SOUND_STEREO_WIDTH] = {"%", 0, 5, 0, 250, 100},
-};
-
/* convert tenth of dB volume to master volume register value */
static int vol_tenthdb2hw(int db)
{
diff --git a/firmware/drivers/audio/ak4537.c b/firmware/drivers/audio/ak4537.c
index 6f4e85a..1628af8 100644
--- a/firmware/drivers/audio/ak4537.c
+++ b/firmware/drivers/audio/ak4537.c
@@ -31,21 +31,6 @@
#include "audiohw.h"
#include "sound.h"
-const struct sound_settings_info audiohw_settings[] = {
- [SOUND_VOLUME] = {"dB", 0, 1,-127, 0, -25},
- /* HAVE_SW_TONE_CONTROLS */
- [SOUND_BASS] = {"dB", 0, 1, -24, 24, 0},
- [SOUND_TREBLE] = {"dB", 0, 1, -24, 24, 0},
- [SOUND_BALANCE] = {"%", 0, 1,-100, 100, 0},
- [SOUND_CHANNELS] = {"", 0, 1, 0, 5, 0},
- [SOUND_STEREO_WIDTH] = {"%", 0, 5, 0, 250, 100},
-#if defined(HAVE_RECORDING)
- [SOUND_LEFT_GAIN] = {"dB", 1, 1, 0, 31, 23},
- [SOUND_RIGHT_GAIN] = {"dB", 1, 1, 0, 31, 23},
- [SOUND_MIC_GAIN] = {"dB", 1, 1, 0, 1, 0},
-#endif
-};
-
static unsigned char akc_regs[AKC_NUM_REGS];
static void akc_write(int reg, unsigned val)
diff --git a/firmware/drivers/audio/imx233-codec.c b/firmware/drivers/audio/imx233-codec.c
index ef4e3ca..f808a73 100644
--- a/firmware/drivers/audio/imx233-codec.c
+++ b/firmware/drivers/audio/imx233-codec.c
@@ -43,7 +43,7 @@ void audiohw_close(void)
imx233_audioin_close();
}
-void audiohw_set_headphone_vol(int vol_l, int vol_r)
+void audiohw_set_volume(int vol_l, int vol_r)
{
imx233_audioout_set_hp_vol(vol_l / 5, vol_r / 5);
}
diff --git a/firmware/drivers/audio/mas35xx.c b/firmware/drivers/audio/mas35xx.c
index deb9223..65c582c 100644
--- a/firmware/drivers/audio/mas35xx.c
+++ b/firmware/drivers/audio/mas35xx.c
@@ -24,7 +24,7 @@
#include "config.h"
#include "system.h" /* MAX MIN macros */
-#include "audiohw.h"
+#include "sound.h"
int channel_configuration = SOUND_CHAN_STEREO;
int stereo_width = 100;
diff --git a/firmware/drivers/audio/wm8731.c b/firmware/drivers/audio/wm8731.c
index 3689a28..f84edc5 100644
--- a/firmware/drivers/audio/wm8731.c
+++ b/firmware/drivers/audio/wm8731.c
@@ -93,29 +93,6 @@ static void wmc_write_masked(int reg, unsigned bits, unsigned mask)
wmc_write(reg, (wmc_regs[reg] & ~mask) | (bits & mask));
}
-int sound_val2phys(int setting, int value)
-{
- int result;
-
- switch(setting)
- {
-#ifdef HAVE_RECORDING
- case SOUND_LEFT_GAIN:
- case SOUND_RIGHT_GAIN:
- result = (value - 23) * 15;
- break;
- case SOUND_MIC_GAIN:
- result = value * 200;
- break;
-#endif
- default:
- result = value;
- break;
- }
-
- return result;
-}
-
/* convert tenth of dB volume (-730..60) to master volume register value */
static int vol_tenthdb2hw(int db)
{