diff options
Diffstat (limited to 'drivers/media/dvb/ttusb-budget')
-rw-r--r-- | drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c b/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c index cf264512d36f..e540dacf5ce2 100644 --- a/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c +++ b/drivers/media/dvb/ttusb-budget/dvb-ttusb-budget.c | |||
@@ -1039,6 +1039,8 @@ static int alps_tdmb7_tuner_set_params(struct dvb_frontend* fe, struct dvb_front | |||
1039 | data[2] = ((div >> 10) & 0x60) | 0x85; | 1039 | data[2] = ((div >> 10) & 0x60) | 0x85; |
1040 | data[3] = params->frequency < 592000000 ? 0x40 : 0x80; | 1040 | data[3] = params->frequency < 592000000 ? 0x40 : 0x80; |
1041 | 1041 | ||
1042 | if (fe->ops->i2c_gate_ctrl) | ||
1043 | fe->ops->i2c_gate_ctrl(fe, 1); | ||
1042 | if (i2c_transfer(&ttusb->i2c_adap, &msg, 1) != 1) return -EIO; | 1044 | if (i2c_transfer(&ttusb->i2c_adap, &msg, 1) != 1) return -EIO; |
1043 | return 0; | 1045 | return 0; |
1044 | } | 1046 | } |
@@ -1059,6 +1061,8 @@ static int philips_tdm1316l_tuner_init(struct dvb_frontend* fe) | |||
1059 | struct i2c_msg tuner_msg = { .addr=0x60, .flags=0, .buf=td1316_init, .len=sizeof(td1316_init) }; | 1061 | struct i2c_msg tuner_msg = { .addr=0x60, .flags=0, .buf=td1316_init, .len=sizeof(td1316_init) }; |
1060 | 1062 | ||
1061 | // setup PLL configuration | 1063 | // setup PLL configuration |
1064 | if (fe->ops->i2c_gate_ctrl) | ||
1065 | fe->ops->i2c_gate_ctrl(fe, 1); | ||
1062 | if (i2c_transfer(&ttusb->i2c_adap, &tuner_msg, 1) != 1) return -EIO; | 1066 | if (i2c_transfer(&ttusb->i2c_adap, &tuner_msg, 1) != 1) return -EIO; |
1063 | msleep(1); | 1067 | msleep(1); |
1064 | 1068 | ||
@@ -1066,6 +1070,8 @@ static int philips_tdm1316l_tuner_init(struct dvb_frontend* fe) | |||
1066 | tuner_msg.addr = 0x65; | 1070 | tuner_msg.addr = 0x65; |
1067 | tuner_msg.buf = disable_mc44BC374c; | 1071 | tuner_msg.buf = disable_mc44BC374c; |
1068 | tuner_msg.len = sizeof(disable_mc44BC374c); | 1072 | tuner_msg.len = sizeof(disable_mc44BC374c); |
1073 | if (fe->ops->i2c_gate_ctrl) | ||
1074 | fe->ops->i2c_gate_ctrl(fe, 1); | ||
1069 | if (i2c_transfer(&ttusb->i2c_adap, &tuner_msg, 1) != 1) { | 1075 | if (i2c_transfer(&ttusb->i2c_adap, &tuner_msg, 1) != 1) { |
1070 | i2c_transfer(&ttusb->i2c_adap, &tuner_msg, 1); | 1076 | i2c_transfer(&ttusb->i2c_adap, &tuner_msg, 1); |
1071 | } | 1077 | } |
@@ -1133,6 +1139,8 @@ static int philips_tdm1316l_tuner_set_params(struct dvb_frontend* fe, struct dvb | |||
1133 | tuner_buf[2] = 0xca; | 1139 | tuner_buf[2] = 0xca; |
1134 | tuner_buf[3] = (cp << 5) | (filter << 3) | band; | 1140 | tuner_buf[3] = (cp << 5) | (filter << 3) | band; |
1135 | 1141 | ||
1142 | if (fe->ops->i2c_gate_ctrl) | ||
1143 | fe->ops->i2c_gate_ctrl(fe, 1); | ||
1136 | if (i2c_transfer(&ttusb->i2c_adap, &tuner_msg, 1) != 1) | 1144 | if (i2c_transfer(&ttusb->i2c_adap, &tuner_msg, 1) != 1) |
1137 | return -EIO; | 1145 | return -EIO; |
1138 | 1146 | ||
@@ -1296,6 +1304,8 @@ static int philips_tsa5059_tuner_set_params(struct dvb_frontend *fe, struct dvb_ | |||
1296 | if (ttusb->revision == TTUSB_REV_2_2) | 1304 | if (ttusb->revision == TTUSB_REV_2_2) |
1297 | buf[3] |= 0x20; | 1305 | buf[3] |= 0x20; |
1298 | 1306 | ||
1307 | if (fe->ops->i2c_gate_ctrl) | ||
1308 | fe->ops->i2c_gate_ctrl(fe, 1); | ||
1299 | if (i2c_transfer(&ttusb->i2c_adap, &msg, 1) != 1) | 1309 | if (i2c_transfer(&ttusb->i2c_adap, &msg, 1) != 1) |
1300 | return -EIO; | 1310 | return -EIO; |
1301 | 1311 | ||
@@ -1328,6 +1338,8 @@ static int ttusb_novas_grundig_29504_491_tuner_set_params(struct dvb_frontend *f | |||
1328 | buf[2] = 0x8e; | 1338 | buf[2] = 0x8e; |
1329 | buf[3] = 0x00; | 1339 | buf[3] = 0x00; |
1330 | 1340 | ||
1341 | if (fe->ops->i2c_gate_ctrl) | ||
1342 | fe->ops->i2c_gate_ctrl(fe, 1); | ||
1331 | if (i2c_transfer(&ttusb->i2c_adap, &msg, 1) != 1) | 1343 | if (i2c_transfer(&ttusb->i2c_adap, &msg, 1) != 1) |
1332 | return -EIO; | 1344 | return -EIO; |
1333 | 1345 | ||
@@ -1353,6 +1365,8 @@ static int alps_tdbe2_tuner_set_params(struct dvb_frontend* fe, struct dvb_front | |||
1353 | data[2] = 0x85 | ((div >> 10) & 0x60); | 1365 | data[2] = 0x85 | ((div >> 10) & 0x60); |
1354 | data[3] = (params->frequency < 174000000 ? 0x88 : params->frequency < 470000000 ? 0x84 : 0x81); | 1366 | data[3] = (params->frequency < 174000000 ? 0x88 : params->frequency < 470000000 ? 0x84 : 0x81); |
1355 | 1367 | ||
1368 | if (fe->ops->i2c_gate_ctrl) | ||
1369 | fe->ops->i2c_gate_ctrl(fe, 1); | ||
1356 | if (i2c_transfer (&ttusb->i2c_adap, &msg, 1) != 1) | 1370 | if (i2c_transfer (&ttusb->i2c_adap, &msg, 1) != 1) |
1357 | return -EIO; | 1371 | return -EIO; |
1358 | 1372 | ||