[media] ngene: separate demodulator and tuner attach
authorPatrice Chotard <patrice.chotard@sfr.fr>
Sat, 15 Dec 2012 22:11:43 +0000 (19:11 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Thu, 27 Dec 2012 20:21:20 +0000 (18:21 -0200)
Previously, demodulator and tuner attach was done in the
demod_attach callback. Migrate the tuner part in the
tuner_attach callback in ngene_info to do thing in right place.

Signed-off-by: Patrice Chotard <patricechotard@free.fr>
Reviewed-by: Antti Palosaari <crope@iki.fi>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/pci/ngene/ngene-cards.c

index b38bce529566cdaa02b87b2855674ba5a03dd90e..2a4895b0706b831455095670502c775869a98e52 100644 (file)
@@ -327,6 +327,14 @@ static int demod_attach_drxd(struct ngene_channel *chan)
                pr_err("No DRXD found!\n");
                return -ENODEV;
        }
+       return 0;
+}
+
+static int tuner_attach_dtt7520x(struct ngene_channel *chan)
+{
+       struct drxd_config *feconf;
+
+       feconf = chan->dev->card_info->fe_config[chan->number];
 
        if (!dvb_attach(dvb_pll_attach, chan->fe, feconf->pll_address,
                        &chan->i2c_adapter,