aboutsummaryrefslogtreecommitdiff
path: root/drivers/media/video/em28xx/em28xx-core.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2008-02-05 22:29:26 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-02-18 11:15:14 -0300
commit7463dda2ae868d3e0a6c98f65d6331481fc73ca3 (patch)
treeaf31fbb1dfddf4edc74d7629d24ecf682d31429d /drivers/media/video/em28xx/em28xx-core.c
parent1685a6fed210b110ac8abeff24e2ffd1713cb3fb (diff)
V4L/DVB (7158): Fix em28xx audio initialization
AC97 register initialization seem to always be needed. This patch fixes audio for Prolink/Pixelview USB2 board. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/em28xx/em28xx-core.c')
-rw-r--r--drivers/media/video/em28xx/em28xx-core.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/drivers/media/video/em28xx/em28xx-core.c b/drivers/media/video/em28xx/em28xx-core.c
index 33d323cbce7..4ffb8d0bc52 100644
--- a/drivers/media/video/em28xx/em28xx-core.c
+++ b/drivers/media/video/em28xx/em28xx-core.c
@@ -274,7 +274,6 @@ int em28xx_set_audio_source(struct em28xx *dev)
static char *disable = "\x08\x88";
char *video = enable, *line = disable;
int ret;
- int no_ac97 = 0;
u8 input;
if (dev->is_em2800) {
@@ -294,11 +293,9 @@ int em28xx_set_audio_source(struct em28xx *dev)
switch (dev->ctl_ainput) {
case EM28XX_AMUX_VIDEO:
input = EM28XX_AUDIO_SRC_TUNER;
- no_ac97 = 1;
break;
case EM28XX_AMUX_LINE_IN:
input = EM28XX_AUDIO_SRC_LINE;
- no_ac97 = 1;
break;
case EM28XX_AMUX_AC97_VIDEO:
input = EM28XX_AUDIO_SRC_LINE;
@@ -315,11 +312,9 @@ int em28xx_set_audio_source(struct em28xx *dev)
if (ret < 0)
return ret;
- if (no_ac97)
- return 0;
-
- /* Sets AC97 mixer registers */
-
+ /* Sets AC97 mixer registers
+ This is seems to be needed, even for non-ac97 configs
+ */
ret = em28xx_write_ac97(dev, VIDEO_AC97, video);
if (ret < 0)
return ret;