[media] tm6000: Disable video interface in radio mode
authorThierry Reding <thierry.reding@avionic-design.de>
Thu, 4 Aug 2011 07:14:08 +0000 (04:14 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Wed, 31 Aug 2011 20:17:16 +0000 (17:17 -0300)
Video data is useless in radio mode, so the corresponding interface can
be safely disabled. This should reduce the amount of isochronous traffic
noticeably.

Signed-off-by: Thierry Reding <thierry.reding@avionic-design.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/staging/tm6000/tm6000-core.c

index 2cd7bc4b293b4fa1a62d67cdb9f349f4d1840b53..f85e5f2cf75d58e6c9bb9ee52aed7338ff67a2b6 100644 (file)
@@ -267,9 +267,14 @@ int tm6000_init_analog_mode(struct tm6000_core *dev)
        struct v4l2_frequency f;
 
        if (dev->dev_type == TM6010) {
+               u8 active = TM6010_REQ07_RCC_ACTIVE_IF_AUDIO_ENABLE;
+
+               if (!dev->radio)
+                       active |= TM6010_REQ07_RCC_ACTIVE_IF_VIDEO_ENABLE;
+
                /* Enable video and audio */
                tm6000_set_reg_mask(dev, TM6010_REQ07_RCC_ACTIVE_IF,
-                                                       0x60, 0x60);
+                                                       active, 0x60);
                /* Disable TS input */
                tm6000_set_reg_mask(dev, TM6010_REQ07_RC0_ACTIVE_VIDEO_SOURCE,
                                                        0x00, 0x40);