aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/cx23885/cx23885-dvb.c
diff options
context:
space:
mode:
authorIgor M. Liplianin <liplianin@me.by>2009-11-24 18:16:04 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-12-05 15:42:08 -0500
commit09ea33e5c696958e8b1ae6d5ab184476b16592f1 (patch)
tree2543aefab407abd23e1070e626c6f7a1333f83b5 /drivers/media/video/cx23885/cx23885-dvb.c
parent6afd2aa856eba0706176cecea1f989b1081c96dc (diff)
V4L/DVB (13493): TeVii S470 and TBS 6920 fixes
The new hardware design applied for this cards. Silicon Labs C8051F300 microcontroller is used for LNB power control. It connected to cx23885 GPIO pins: GPIO0 - P0.3 data GPIO1 - P0.2 reset GPIO2 - P0.1 clk GPIO3 - P0.0 busy Tevii S470 based on Montage Technology M88TS2020 digital satellite tuner and M88DS3000 advanced DVB-S/S2 demodulator. Signed-off-by: Igor M. Liplianin <liplianin@me.by> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/cx23885/cx23885-dvb.c')
-rw-r--r--drivers/media/video/cx23885/cx23885-dvb.c38
1 files changed, 13 insertions, 25 deletions
diff --git a/drivers/media/video/cx23885/cx23885-dvb.c b/drivers/media/video/cx23885/cx23885-dvb.c
index bf24e86293c6..2607de134fa6 100644
--- a/drivers/media/video/cx23885/cx23885-dvb.c
+++ b/drivers/media/video/cx23885/cx23885-dvb.c
@@ -56,6 +56,8 @@
56#include "netup-init.h" 56#include "netup-init.h"
57#include "lgdt3305.h" 57#include "lgdt3305.h"
58#include "atbm8830.h" 58#include "atbm8830.h"
59#include "ds3000.h"
60#include "cx23885-f300.h"
59 61
60static unsigned int debug; 62static unsigned int debug;
61 63
@@ -427,26 +429,12 @@ static struct stv6110_config netup_stv6110_tunerconfig_b = {
427 .gain = 8, /* +16 dB - maximum gain */ 429 .gain = 8, /* +16 dB - maximum gain */
428}; 430};
429 431
430static int tbs_set_voltage(struct dvb_frontend *fe, fe_sec_voltage_t voltage)
431{
432 struct cx23885_tsport *port = fe->dvb->priv;
433 struct cx23885_dev *dev = port->dev;
434
435 if (voltage == SEC_VOLTAGE_18)
436 cx_write(MC417_RWD, 0x00001e00);/* GPIO-13 high */
437 else if (voltage == SEC_VOLTAGE_13)
438 cx_write(MC417_RWD, 0x00001a00);/* GPIO-13 low */
439 else
440 cx_write(MC417_RWD, 0x00001800);/* GPIO-12 low */
441 return 0;
442}
443
444static struct cx24116_config tbs_cx24116_config = { 432static struct cx24116_config tbs_cx24116_config = {
445 .demod_address = 0x05, 433 .demod_address = 0x55,
446}; 434};
447 435
448static struct cx24116_config tevii_cx24116_config = { 436static struct ds3000_config tevii_ds3000_config = {
449 .demod_address = 0x55, 437 .demod_address = 0x68,
450}; 438};
451 439
452static struct cx24116_config dvbworld_cx24116_config = { 440static struct cx24116_config dvbworld_cx24116_config = {
@@ -832,23 +820,23 @@ static int dvb_register(struct cx23885_tsport *port)
832 } 820 }
833 break; 821 break;
834 case CX23885_BOARD_TBS_6920: 822 case CX23885_BOARD_TBS_6920:
835 i2c_bus = &dev->i2c_bus[0]; 823 i2c_bus = &dev->i2c_bus[1];
836 824
837 fe0->dvb.frontend = dvb_attach(cx24116_attach, 825 fe0->dvb.frontend = dvb_attach(cx24116_attach,
838 &tbs_cx24116_config, 826 &tbs_cx24116_config,
839 &i2c_bus->i2c_adap); 827 &i2c_bus->i2c_adap);
840 if (fe0->dvb.frontend != NULL) 828 if (fe0->dvb.frontend != NULL)
841 fe0->dvb.frontend->ops.set_voltage = tbs_set_voltage; 829 fe0->dvb.frontend->ops.set_voltage = f300_set_voltage;
842 830
843 break; 831 break;
844 case CX23885_BOARD_TEVII_S470: 832 case CX23885_BOARD_TEVII_S470:
845 i2c_bus = &dev->i2c_bus[1]; 833 i2c_bus = &dev->i2c_bus[1];
846 834
847 fe0->dvb.frontend = dvb_attach(cx24116_attach, 835 fe0->dvb.frontend = dvb_attach(ds3000_attach,
848 &tevii_cx24116_config, 836 &tevii_ds3000_config,
849 &i2c_bus->i2c_adap); 837 &i2c_bus->i2c_adap);
850 if (fe0->dvb.frontend != NULL) 838 if (fe0->dvb.frontend != NULL)
851 fe0->dvb.frontend->ops.set_voltage = tbs_set_voltage; 839 fe0->dvb.frontend->ops.set_voltage = f300_set_voltage;
852 840
853 break; 841 break;
854 case CX23885_BOARD_DVBWORLD_2005: 842 case CX23885_BOARD_DVBWORLD_2005: