aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2009-07-19 08:10:06 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-09-12 11:17:41 -0400
commited10daaeb3512165505eda8bb311edabea5cb485 (patch)
treec1d64e33538cddcdbf4061b5dbb137438f7f7870 /drivers
parent2365b2d307ee0323062c674ea0495584085e8c24 (diff)
V4L/DVB (12273): em28xx-video: rename ac97 audio controls to better document it
As em28xx chip has nothing to do with volume/mute controls, rename those controls to properly indicate that they control the companion AC97 chip that it is inside the boards with this chip. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/video/em28xx/em28xx-video.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/drivers/media/video/em28xx/em28xx-video.c b/drivers/media/video/em28xx/em28xx-video.c
index ab079d9256c4..e612e43b0ef1 100644
--- a/drivers/media/video/em28xx/em28xx-video.c
+++ b/drivers/media/video/em28xx/em28xx-video.c
@@ -124,7 +124,7 @@ static struct em28xx_fmt format[] = {
124 124
125/* supported controls */ 125/* supported controls */
126/* Common to all boards */ 126/* Common to all boards */
127static struct v4l2_queryctrl em28xx_qctrl[] = { 127static struct v4l2_queryctrl ac97_qctrl[] = {
128 { 128 {
129 .id = V4L2_CID_AUDIO_VOLUME, 129 .id = V4L2_CID_AUDIO_VOLUME,
130 .type = V4L2_CTRL_TYPE_INTEGER, 130 .type = V4L2_CTRL_TYPE_INTEGER,
@@ -1050,9 +1050,9 @@ static int vidioc_queryctrl(struct file *file, void *priv,
1050 qc->id = id; 1050 qc->id = id;
1051 1051
1052 if (!dev->board.has_msp34xx) { 1052 if (!dev->board.has_msp34xx) {
1053 for (i = 0; i < ARRAY_SIZE(em28xx_qctrl); i++) { 1053 for (i = 0; i < ARRAY_SIZE(ac97_qctrl); i++) {
1054 if (qc->id && qc->id == em28xx_qctrl[i].id) { 1054 if (qc->id && qc->id == ac97_qctrl[i].id) {
1055 memcpy(qc, &(em28xx_qctrl[i]), sizeof(*qc)); 1055 memcpy(qc, &(ac97_qctrl[i]), sizeof(*qc));
1056 return 0; 1056 return 0;
1057 } 1057 }
1058 } 1058 }
@@ -1114,10 +1114,10 @@ static int vidioc_s_ctrl(struct file *file, void *priv,
1114 v4l2_device_call_all(&dev->v4l2_dev, 0, core, s_ctrl, ctrl); 1114 v4l2_device_call_all(&dev->v4l2_dev, 0, core, s_ctrl, ctrl);
1115 else { 1115 else {
1116 rc = 1; 1116 rc = 1;
1117 for (i = 0; i < ARRAY_SIZE(em28xx_qctrl); i++) { 1117 for (i = 0; i < ARRAY_SIZE(ac97_qctrl); i++) {
1118 if (ctrl->id == em28xx_qctrl[i].id) { 1118 if (ctrl->id == ac97_qctrl[i].id) {
1119 if (ctrl->value < em28xx_qctrl[i].minimum || 1119 if (ctrl->value < ac97_qctrl[i].minimum ||
1120 ctrl->value > em28xx_qctrl[i].maximum) { 1120 ctrl->value > ac97_qctrl[i].maximum) {
1121 rc = -ERANGE; 1121 rc = -ERANGE;
1122 break; 1122 break;
1123 } 1123 }
@@ -1654,9 +1654,9 @@ static int radio_queryctrl(struct file *file, void *priv,
1654 qc->id >= V4L2_CID_LASTP1) 1654 qc->id >= V4L2_CID_LASTP1)
1655 return -EINVAL; 1655 return -EINVAL;
1656 1656
1657 for (i = 0; i < ARRAY_SIZE(em28xx_qctrl); i++) { 1657 for (i = 0; i < ARRAY_SIZE(ac97_qctrl); i++) {
1658 if (qc->id && qc->id == em28xx_qctrl[i].id) { 1658 if (qc->id && qc->id == ac97_qctrl[i].id) {
1659 memcpy(qc, &(em28xx_qctrl[i]), sizeof(*qc)); 1659 memcpy(qc, &(ac97_qctrl[i]), sizeof(*qc));
1660 return 0; 1660 return 0;
1661 } 1661 }
1662 } 1662 }