From: Ondrej Zary Date: Fri, 1 Feb 2013 23:01:15 +0000 (-0300) Subject: [media] saa7134: v4l2-compliance: don't report invalid audio modes for radio X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=82456708389d6d9eb81a4479d54efa0bf7dd8bf3;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git [media] saa7134: v4l2-compliance: don't report invalid audio modes for radio Make saa7134 driver more V4L2 compliant: filter audio modes that came from tuner - keep only MONO/STEREO in radio mode Signed-off-by: Ondrej Zary Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab --- diff --git a/drivers/media/pci/saa7134/saa7134-video.c b/drivers/media/pci/saa7134/saa7134-video.c index 88e84c31c7d7..0f2d3bd4896a 100644 --- a/drivers/media/pci/saa7134/saa7134-video.c +++ b/drivers/media/pci/saa7134/saa7134-video.c @@ -2349,6 +2349,7 @@ static int radio_g_tuner(struct file *file, void *priv, t->type = V4L2_TUNER_RADIO; saa_call_all(dev, tuner, g_tuner, t); + t->audmode &= V4L2_TUNER_MODE_MONO | V4L2_TUNER_MODE_STEREO; if (dev->input->amux == TV) { t->signal = 0xf800 - ((saa_readb(0x581) & 0x1f) << 11); t->rxsubchans = (saa_readb(0x529) & 0x08) ?