]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
[media] cx23885: v4l2 api compliance, set the audioset field correctly
authorSteven Toth <stoth@kernellabs.com>
Mon, 10 Oct 2011 14:09:56 +0000 (11:09 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Fri, 14 Oct 2011 20:21:34 +0000 (17:21 -0300)
Inform applications that multiple audio inputs are available on
non-tv inputs.

Signed-off-by: Steven Toth <stoth@kernellabs.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/cx23885/cx23885-video.c

index 396fa4e23acb9b51e3bd46337b2827077833bf5b..7291f64e92bcb189fc398a86dee88cd7eab02fc5 100644 (file)
@@ -1278,6 +1278,11 @@ static int cx23885_enum_input(struct cx23885_dev *dev, struct v4l2_input *i)
                i->type = V4L2_INPUT_TYPE_TUNER;
                i->std = CX23885_NORMS;
        }
+
+       /* Two selectable audio inputs for non-tv inputs */
+       if (INPUT(n)->type != CX23885_VMUX_TELEVISION)
+               i->audioset = 0x3;
+
        return 0;
 }