diff options
-rw-r--r-- | linux/drivers/media/dvb/frontends/ves1820.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/linux/drivers/media/dvb/frontends/ves1820.c b/linux/drivers/media/dvb/frontends/ves1820.c index bd31d1457..3471e0a08 100644 --- a/linux/drivers/media/dvb/frontends/ves1820.c +++ b/linux/drivers/media/dvb/frontends/ves1820.c @@ -462,8 +462,6 @@ static long probe_tuner (struct dvb_i2c_bus *i2c) printk ("DVB: VES1820(%d): setup for tuner sp5659c\n", i2c->adapter->num); } else { type = -1; - printk ("DVB: VES1820(%d): unknown PLL, " - "please report to <linuxdvb@linuxtv.org>!!\n", i2c->adapter->num); } return type; @@ -477,13 +475,11 @@ static u8 read_pwm (struct dvb_i2c_bus *i2c) struct i2c_msg msg [] = { { .addr = 0x50, .flags = 0, .buf = &b, .len = 1 }, { .addr = 0x50, .flags = I2C_M_RD, .buf = &pwm, .len = 1 } }; - i2c->xfer (i2c, msg, 2); + if ((i2c->xfer(i2c, msg, 2) != 2) || (pwm == 0xff)) + pwm = 0x48; printk("DVB: VES1820(%d): pwm=0x%02x\n", i2c->adapter->num, pwm); - if (pwm == 0xff) - pwm = 0x48; - return pwm; } @@ -516,8 +512,7 @@ static int ves1820_attach (struct dvb_i2c_bus *i2c, void **data) if ((demod_addr = probe_demod_addr(i2c)) < 0) return -ENODEV; - if ((tuner_type = probe_tuner(i2c)) < 0) - return -ENODEV; + tuner_type = probe_tuner(i2c); if ((i2c->adapter->num < MAX_UNITS) && pwm[i2c->adapter->num] != -1) { printk("DVB: VES1820(%d): pwm=0x%02x (user specified)\n", |