aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorAleksandr V. Piskunov <aleksandr.v.piskunov@gmail.com>2009-09-25 17:16:21 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-12-05 15:41:01 -0500
commit3c3099d5edd719aebfccf63b628b6f11afa59bfe (patch)
tree35c145624b83704e0164e5b5aa6c9c0074c17636 /drivers/media
parent2d8d7762d75d36a08a4a5c3d3f1c301f76cb8f56 (diff)
V4L/DVB (13232): cx25840 6.5MHz carrier detection fixes
cx25840: Disable 6.5MHz carrier autodetection for PAL, always assume its DK. Only try to autodetect 6.5MHz carrier for SECAM if user accepts both system DK and L. Signed-off-by: Aleksandr V. Piskunov <alexandr.v.piskunov@gmail.com> Reviewed-by: Andy Walls <awalls@radix.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/video/cx25840/cx25840-core.c25
1 files changed, 21 insertions, 4 deletions
diff --git a/drivers/media/video/cx25840/cx25840-core.c b/drivers/media/video/cx25840/cx25840-core.c
index 9702a9334b4a..385ecd58f1c0 100644
--- a/drivers/media/video/cx25840/cx25840-core.c
+++ b/drivers/media/video/cx25840/cx25840-core.c
@@ -685,13 +685,30 @@ static void input_change(struct i2c_client *client)
685 } 685 }
686 cx25840_write(client, 0x80b, 0x00); 686 cx25840_write(client, 0x80b, 0x00);
687 } else if (std & V4L2_STD_PAL) { 687 } else if (std & V4L2_STD_PAL) {
688 /* Follow tuner change procedure for PAL */ 688 /* Autodetect audio standard and audio system */
689 cx25840_write(client, 0x808, 0xff); 689 cx25840_write(client, 0x808, 0xff);
690 cx25840_write(client, 0x80b, 0x10); 690 /* Since system PAL-L is pretty much non-existant and
691 not used by any public broadcast network, force
692 6.5 MHz carrier to be interpreted as System DK,
693 this avoids DK audio detection instability */
694 cx25840_write(client, 0x80b, 0x00);
691 } else if (std & V4L2_STD_SECAM) { 695 } else if (std & V4L2_STD_SECAM) {
692 /* Select autodetect for SECAM */ 696 /* Autodetect audio standard and audio system */
693 cx25840_write(client, 0x808, 0xff); 697 cx25840_write(client, 0x808, 0xff);
694 cx25840_write(client, 0x80b, 0x10); 698 /* If only one of SECAM-DK / SECAM-L is required, then force
699 6.5MHz carrier, else autodetect it */
700 if ((std & V4L2_STD_SECAM_DK) &&
701 !(std & (V4L2_STD_SECAM_L | V4L2_STD_SECAM_LC))) {
702 /* 6.5 MHz carrier to be interpreted as System DK */
703 cx25840_write(client, 0x80b, 0x00);
704 } else if (!(std & V4L2_STD_SECAM_DK) &&
705 (std & (V4L2_STD_SECAM_L | V4L2_STD_SECAM_LC))) {
706 /* 6.5 MHz carrier to be interpreted as System L */
707 cx25840_write(client, 0x80b, 0x08);
708 } else {
709 /* 6.5 MHz carrier to be autodetected */
710 cx25840_write(client, 0x80b, 0x10);
711 }
695 } 712 }
696 713
697 cx25840_and_or(client, 0x810, ~0x01, 0); 714 cx25840_and_or(client, 0x810, ~0x01, 0);