summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Scheller <d.scheller@gmx.net>2018-04-09 18:47:51 +0200
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>2018-05-04 16:51:33 +0200
commit879973e5d6cad93c6e1c1268940aeb1a85377fd0 (patch)
treef55c7878f591de2c78c149234cf75c37caa278cd
parentmedia: ddbridge: add hardware defs and PCI IDs for MCI cards (diff)
downloadlinux-879973e5d6cad93c6e1c1268940aeb1a85377fd0.tar.xz
linux-879973e5d6cad93c6e1c1268940aeb1a85377fd0.zip
media: ddbridge: recognize and attach the MaxSX8 cards
Add needed logic into dvb_input_attach(), ddb_port_probe() and ddb_ports_init() to initialize and support these new cards. Picked up from the upstream dddvb-0.9.33 release. Signed-off-by: Daniel Scheller <d.scheller@gmx.net> Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
-rw-r--r--drivers/media/pci/ddbridge/ddbridge-core.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/media/pci/ddbridge/ddbridge-core.c b/drivers/media/pci/ddbridge/ddbridge-core.c
index 8b9244993747..377269c64449 100644
--- a/drivers/media/pci/ddbridge/ddbridge-core.c
+++ b/drivers/media/pci/ddbridge/ddbridge-core.c
@@ -1559,6 +1559,10 @@ static int dvb_input_attach(struct ddb_input *input)
if (demod_attach_dummy(input) < 0)
goto err_detach;
break;
+ case DDB_TUNER_MCI:
+ if (ddb_fe_attach_mci(input) < 0)
+ goto err_detach;
+ break;
default:
return 0;
}
@@ -1854,6 +1858,16 @@ static void ddb_port_probe(struct ddb_port *port)
return;
}
+ if (dev->link[l].info->type == DDB_OCTOPUS_MCI) {
+ if (port->nr >= dev->link[l].info->mci)
+ return;
+ port->name = "DUAL MCI";
+ port->type_name = "MCI";
+ port->class = DDB_PORT_TUNER;
+ port->type = DDB_TUNER_MCI;
+ return;
+ }
+
if (port->nr > 1 && dev->link[l].info->type == DDB_OCTOPUS_CI) {
port->name = "CI internal";
port->type_name = "INTERNAL";
@@ -2396,6 +2410,7 @@ void ddb_ports_init(struct ddb *dev)
break;
case DDB_OCTOPUS_MAX:
case DDB_OCTOPUS_MAX_CT:
+ case DDB_OCTOPUS_MCI:
ddb_input_init(port, 2 * i, 0, 2 * p);
ddb_input_init(port, 2 * i + 1, 1, 2 * p + 1);
break;