diff options
author | Daniel Scheller <d.scheller@gmx.net> | 2018-04-22 19:06:51 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+samsung@kernel.org> | 2018-05-05 16:42:40 +0300 |
commit | 62208c5703b166681aa590b122263a026d4f9471 (patch) | |
tree | 7c5350061e1b7137febda0a46bb8ae1de2343021 /drivers | |
parent | 078ce0be8945b9e2530f2e0ce84c8dcbb154edb6 (diff) | |
download | linux-62208c5703b166681aa590b122263a026d4f9471.tar.xz |
media: ngene: cleanup superfluous I2C adapter evaluation
Commit ee93340e98bc ("media: ngene: deduplicate I2C adapter evaluation")
added a helper to evaluate the I2C adapter to be used for demod/tuner
attachment based on the given ngene_channel, and that helper is used in
many attach functions to initialise the i2c_adapter variable. However,
for some reason in tuner_attach_stv6110() and demod_attach_stv0900(), the
adapter evaluation wasn't removed as in all other functions. Fix (or
finalize, even) the helper use by cleaning up the superfluous I2C adapter
evaluation leftover in these two functions.
Signed-off-by: Daniel Scheller <d.scheller@gmx.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/media/pci/ngene/ngene-cards.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/drivers/media/pci/ngene/ngene-cards.c b/drivers/media/pci/ngene/ngene-cards.c index 594990c0d2b8..7738565193d6 100644 --- a/drivers/media/pci/ngene/ngene-cards.c +++ b/drivers/media/pci/ngene/ngene-cards.c @@ -137,11 +137,6 @@ static int tuner_attach_stv6110(struct ngene_channel *chan) chan->dev->card_info->tuner_config[chan->number]; const struct stv6110x_devctl *ctl; - if (chan->number < 2) - i2c = &chan->dev->channel[0].i2c_adapter; - else - i2c = &chan->dev->channel[1].i2c_adapter; - ctl = dvb_attach(stv6110x_attach, chan->fe, tunerconf, i2c); if (ctl == NULL) { dev_err(pdev, "No STV6110X found!\n"); @@ -304,14 +299,6 @@ static int demod_attach_stv0900(struct ngene_channel *chan) struct stv090x_config *feconf = (struct stv090x_config *) chan->dev->card_info->fe_config[chan->number]; - /* tuner 1+2: i2c adapter #0, tuner 3+4: i2c adapter #1 */ - /* Note: Both adapters share the same i2c bus, but the demod */ - /* driver requires that each demod has its own i2c adapter */ - if (chan->number < 2) - i2c = &chan->dev->channel[0].i2c_adapter; - else - i2c = &chan->dev->channel[1].i2c_adapter; - chan->fe = dvb_attach(stv090x_attach, feconf, i2c, (chan->number & 1) == 0 ? STV090x_DEMODULATOR_0 : STV090x_DEMODULATOR_1); |