aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/em28xx/em28xx-reg.h
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2008-11-20 07:06:09 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-12-29 14:53:35 -0500
commit5faff78904d9c07f38ac0e227b322e9f58d5447c (patch)
tree431d2e8c8fc7a17396e806f778293629226fc892 /drivers/media/video/em28xx/em28xx-reg.h
parent16c7bcadff2222b297d13951dc30e133f56d0154 (diff)
V4L/DVB (9653): em28xx: improve AC97 handling
AC97 devices provide several input and outputs. However, before this patch, em28xx device weren't properly allowing the usage of ac97 possible combinations. Also, several input volumes were left untouched, instead of making sure that the volumes were set on mute state. This patch improves support for ac97 devices by allowing to use any inputs, and making sure that unused inputs are set on mute state. Yet, some work is still needed to select the AC97 output. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/em28xx/em28xx-reg.h')
-rw-r--r--drivers/media/video/em28xx/em28xx-reg.h14
1 files changed, 13 insertions, 1 deletions
diff --git a/drivers/media/video/em28xx/em28xx-reg.h b/drivers/media/video/em28xx/em28xx-reg.h
index 12c9132b099e..9727f3828dba 100644
--- a/drivers/media/video/em28xx/em28xx-reg.h
+++ b/drivers/media/video/em28xx/em28xx-reg.h
@@ -130,10 +130,13 @@ enum em28xx_chip_id {
130 130
131/* Standard AC97 registers */ 131/* Standard AC97 registers */
132#define AC97_RESET 0x00 132#define AC97_RESET 0x00
133
134 /* Output volumes */
133#define AC97_MASTER_VOL 0x02 135#define AC97_MASTER_VOL 0x02
134#define AC97_LINE_LEVEL_VOL 0x04 136#define AC97_LINE_LEVEL_VOL 0x04 /* Some devices use for headphones */
135#define AC97_MASTER_MONO_VOL 0x06 137#define AC97_MASTER_MONO_VOL 0x06
136 138
139 /* Input volumes */
137#define AC97_PC_BEEP_VOL 0x0a 140#define AC97_PC_BEEP_VOL 0x0a
138#define AC97_PHONE_VOL 0x0c 141#define AC97_PHONE_VOL 0x0c
139#define AC97_MIC_VOL 0x0e 142#define AC97_MIC_VOL 0x0e
@@ -142,8 +145,12 @@ enum em28xx_chip_id {
142#define AC97_VIDEO_VOL 0x14 145#define AC97_VIDEO_VOL 0x14
143#define AC97_AUX_VOL 0x16 146#define AC97_AUX_VOL 0x16
144#define AC97_PCM_OUT_VOL 0x18 147#define AC97_PCM_OUT_VOL 0x18
148
149 /* capture registers */
145#define AC97_RECORD_SELECT 0x1a 150#define AC97_RECORD_SELECT 0x1a
146#define AC97_RECORD_GAIN 0x1c 151#define AC97_RECORD_GAIN 0x1c
152
153 /* control registers */
147#define AC97_GENERAL_PURPOSE 0x20 154#define AC97_GENERAL_PURPOSE 0x20
148#define AC97_3D_CTRL 0x22 155#define AC97_3D_CTRL 0x22
149#define AC97_AUD_INT_AND_PAG 0x24 156#define AC97_AUD_INT_AND_PAG 0x24
@@ -158,10 +165,15 @@ enum em28xx_chip_id {
158#define AC97_PCM_OUT_SURR_SRATE 0x2e 165#define AC97_PCM_OUT_SURR_SRATE 0x2e
159#define AC97_PCM_OUT_LFE_SRATE 0x30 166#define AC97_PCM_OUT_LFE_SRATE 0x30
160#define AC97_PCM_IN_SRATE 0x32 167#define AC97_PCM_IN_SRATE 0x32
168
169 /* For devices with more than 2 channels, extra output volumes */
161#define AC97_LFE_MASTER_VOL 0x36 170#define AC97_LFE_MASTER_VOL 0x36
162#define AC97_SURR_MASTER_VOL 0x38 171#define AC97_SURR_MASTER_VOL 0x38
172
173 /* Digital SPDIF output control */
163#define AC97_SPDIF_OUT_CTRL 0x3a 174#define AC97_SPDIF_OUT_CTRL 0x3a
164 175
176 /* Vendor ID identifier */
165#define AC97_VENDOR_ID1 0x7c 177#define AC97_VENDOR_ID1 0x7c
166#define AC97_VENDOR_ID2 0x7e 178#define AC97_VENDOR_ID2 0x7e
167 179