Lines Matching +full:turbo +full:- +full:gpios

1 // SPDX-License-Identifier: GPL-2.0-or-later
19 struct rtl28xxu_dev *dev = d->priv; in rtl28xxu_ctrl_msg()
24 mutex_lock(&d->usb_mutex); in rtl28xxu_ctrl_msg()
26 if (req->size > sizeof(dev->buf)) { in rtl28xxu_ctrl_msg()
27 dev_err(&d->intf->dev, "too large message %u\n", req->size); in rtl28xxu_ctrl_msg()
28 ret = -EINVAL; in rtl28xxu_ctrl_msg()
32 if (req->index & CMD_WR_FLAG) { in rtl28xxu_ctrl_msg()
34 memcpy(dev->buf, req->data, req->size); in rtl28xxu_ctrl_msg()
36 pipe = usb_sndctrlpipe(d->udev, 0); in rtl28xxu_ctrl_msg()
42 * Zero-length transfers must use usb_sndctrlpipe() and in rtl28xxu_ctrl_msg()
43 * rtl28xxu_identify_state() uses a zero-length i2c read in rtl28xxu_ctrl_msg()
46 if (req->size) in rtl28xxu_ctrl_msg()
47 pipe = usb_rcvctrlpipe(d->udev, 0); in rtl28xxu_ctrl_msg()
49 pipe = usb_sndctrlpipe(d->udev, 0); in rtl28xxu_ctrl_msg()
52 ret = usb_control_msg(d->udev, pipe, 0, requesttype, req->value, in rtl28xxu_ctrl_msg()
53 req->index, dev->buf, req->size, 1000); in rtl28xxu_ctrl_msg()
54 dvb_usb_dbg_usb_control_msg(d->udev, 0, requesttype, req->value, in rtl28xxu_ctrl_msg()
55 req->index, dev->buf, req->size); in rtl28xxu_ctrl_msg()
61 memcpy(req->data, dev->buf, req->size); in rtl28xxu_ctrl_msg()
63 mutex_unlock(&d->usb_mutex); in rtl28xxu_ctrl_msg()
67 mutex_unlock(&d->usb_mutex); in rtl28xxu_ctrl_msg()
68 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl28xxu_ctrl_msg()
144 struct rtl28xxu_dev *dev = d->priv; in rtl28xxu_i2c_xfer()
169 if (mutex_lock_interruptible(&d->i2c_mutex) < 0) in rtl28xxu_i2c_xfer()
170 return -EAGAIN; in rtl28xxu_i2c_xfer()
176 ret = -EOPNOTSUPP; in rtl28xxu_i2c_xfer()
180 ret = -EOPNOTSUPP; in rtl28xxu_i2c_xfer()
183 /* method 1 - integrated demod */ in rtl28xxu_i2c_xfer()
186 msg[1].buf[0] = dev->page; in rtl28xxu_i2c_xfer()
190 req.index = CMD_DEMOD_RD | dev->page; in rtl28xxu_i2c_xfer()
197 ret = -EOPNOTSUPP; in rtl28xxu_i2c_xfer()
200 /* method 2 - old I2C */ in rtl28xxu_i2c_xfer()
207 /* method 3 - new I2C */ in rtl28xxu_i2c_xfer()
225 ret = -EOPNOTSUPP; in rtl28xxu_i2c_xfer()
229 ret = -EOPNOTSUPP; in rtl28xxu_i2c_xfer()
232 /* method 1 - integrated demod */ in rtl28xxu_i2c_xfer()
235 ret = -EOPNOTSUPP; in rtl28xxu_i2c_xfer()
239 dev->page = msg[0].buf[1]; in rtl28xxu_i2c_xfer()
244 req.index = CMD_DEMOD_WR | dev->page; in rtl28xxu_i2c_xfer()
245 req.size = msg[0].len-1; in rtl28xxu_i2c_xfer()
249 } else if ((msg[0].len < 23) && (!dev->new_i2c_write)) { in rtl28xxu_i2c_xfer()
251 ret = -EOPNOTSUPP; in rtl28xxu_i2c_xfer()
254 /* method 2 - old I2C */ in rtl28xxu_i2c_xfer()
257 req.size = msg[0].len-1; in rtl28xxu_i2c_xfer()
261 /* method 3 - new I2C */ in rtl28xxu_i2c_xfer()
275 ret = -EOPNOTSUPP; in rtl28xxu_i2c_xfer()
279 if (ret == -EPIPE) in rtl28xxu_i2c_xfer()
280 ret = -EAGAIN; in rtl28xxu_i2c_xfer()
283 mutex_unlock(&d->i2c_mutex); in rtl28xxu_i2c_xfer()
309 dev_dbg(&d->intf->dev, "\n"); in rtl2831u_read_config()
312 * RTL2831U GPIOs in rtl2831u_read_config()
337 dev->tuner_name = "NONE"; in rtl2831u_read_config()
347 dev->tuner = TUNER_RTL2830_QT1010; in rtl2831u_read_config()
348 dev->tuner_name = "QT1010"; in rtl2831u_read_config()
360 dev->tuner = TUNER_RTL2830_MT2060; in rtl2831u_read_config()
361 dev->tuner_name = "MT2060"; in rtl2831u_read_config()
366 dev->tuner = TUNER_RTL2830_MXL5005S; in rtl2831u_read_config()
367 dev->tuner_name = "MXL5005S"; in rtl2831u_read_config()
371 dev_dbg(&d->intf->dev, "tuner=%s\n", dev->tuner_name); in rtl2831u_read_config()
375 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2831u_read_config()
407 dev_dbg(&d->intf->dev, "\n"); in rtl2832u_read_config()
428 dev->tuner_name = "NONE"; in rtl2832u_read_config()
433 dev->tuner = TUNER_RTL2832_FC0012; in rtl2832u_read_config()
434 dev->tuner_name = "FC0012"; in rtl2832u_read_config()
441 dev->tuner = TUNER_RTL2832_FC0013; in rtl2832u_read_config()
442 dev->tuner_name = "FC0013"; in rtl2832u_read_config()
449 dev->tuner = TUNER_RTL2832_MT2266; in rtl2832u_read_config()
450 dev->tuner_name = "MT2266"; in rtl2832u_read_config()
457 dev->tuner = TUNER_RTL2832_FC2580; in rtl2832u_read_config()
458 dev->tuner_name = "FC2580"; in rtl2832u_read_config()
465 dev->tuner = TUNER_RTL2832_MT2063; in rtl2832u_read_config()
466 dev->tuner_name = "MT2063"; in rtl2832u_read_config()
473 dev->tuner = TUNER_RTL2832_MAX3543; in rtl2832u_read_config()
474 dev->tuner_name = "MAX3543"; in rtl2832u_read_config()
481 dev->tuner = TUNER_RTL2832_TUA9001; in rtl2832u_read_config()
482 dev->tuner_name = "TUA9001"; in rtl2832u_read_config()
489 dev->tuner = TUNER_RTL2832_MXL5007T; in rtl2832u_read_config()
490 dev->tuner_name = "MXL5007T"; in rtl2832u_read_config()
497 dev->tuner = TUNER_RTL2832_E4000; in rtl2832u_read_config()
498 dev->tuner_name = "E4000"; in rtl2832u_read_config()
505 dev->tuner = TUNER_RTL2832_TDA18272; in rtl2832u_read_config()
506 dev->tuner_name = "TDA18272"; in rtl2832u_read_config()
513 dev->tuner = TUNER_RTL2832_R820T; in rtl2832u_read_config()
514 dev->tuner_name = "R820T"; in rtl2832u_read_config()
521 dev->tuner = TUNER_RTL2832_R828D; in rtl2832u_read_config()
522 dev->tuner_name = "R828D"; in rtl2832u_read_config()
550 dev->tuner = TUNER_RTL2832_SI2157; in rtl2832u_read_config()
551 dev->tuner_name = "SI2157"; in rtl2832u_read_config()
556 dev_dbg(&d->intf->dev, "tuner=%s\n", dev->tuner_name); in rtl2832u_read_config()
559 if (dev->tuner == TUNER_RTL2832_R828D) { in rtl2832u_read_config()
590 dev_dbg(&d->intf->dev, "MN88472 found\n"); in rtl2832u_read_config()
591 dev->slave_demod = SLAVE_DEMOD_MN88472; in rtl2832u_read_config()
597 dev_dbg(&d->intf->dev, "MN88473 found\n"); in rtl2832u_read_config()
598 dev->slave_demod = SLAVE_DEMOD_MN88473; in rtl2832u_read_config()
604 dev_dbg(&d->intf->dev, "CXD2837ER found\n"); in rtl2832u_read_config()
605 dev->slave_demod = SLAVE_DEMOD_CXD2837ER; in rtl2832u_read_config()
609 if (dev->tuner == TUNER_RTL2832_SI2157) { in rtl2832u_read_config()
613 dev_dbg(&d->intf->dev, "Si2168 found\n"); in rtl2832u_read_config()
614 dev->slave_demod = SLAVE_DEMOD_SI2168; in rtl2832u_read_config()
627 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2832u_read_config()
635 if (dev->chip_id == CHIP_ID_RTL2831U) in rtl28xxu_read_config()
647 dev_dbg(&d->intf->dev, "\n"); in rtl28xxu_identify_state()
654 if (ret == -EPIPE) { in rtl28xxu_identify_state()
655 dev->chip_id = CHIP_ID_RTL2831U; in rtl28xxu_identify_state()
657 dev->chip_id = CHIP_ID_RTL2832U; in rtl28xxu_identify_state()
659 dev_err(&d->intf->dev, "chip type detection failed %d\n", ret); in rtl28xxu_identify_state()
662 dev_dbg(&d->intf->dev, "chip_id=%u\n", dev->chip_id); in rtl28xxu_identify_state()
665 d->i2c_adap.retries = 3; in rtl28xxu_identify_state()
666 d->i2c_adap.timeout = msecs_to_jiffies(10); in rtl28xxu_identify_state()
670 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl28xxu_identify_state()
703 struct rtl2830_platform_data *pdata = &dev->rtl2830_platform_data; in rtl2831u_frontend_attach()
708 dev_dbg(&d->intf->dev, "\n"); in rtl2831u_frontend_attach()
710 switch (dev->tuner) { in rtl2831u_frontend_attach()
721 dev_err(&d->intf->dev, "unknown tuner %s\n", dev->tuner_name); in rtl2831u_frontend_attach()
722 ret = -ENODEV; in rtl2831u_frontend_attach()
732 client = i2c_new_client_device(&d->i2c_adap, &board_info); in rtl2831u_frontend_attach()
734 ret = -ENODEV; in rtl2831u_frontend_attach()
738 if (!try_module_get(client->dev.driver->owner)) { in rtl2831u_frontend_attach()
740 ret = -ENODEV; in rtl2831u_frontend_attach()
744 adap->fe[0] = pdata->get_dvb_frontend(client); in rtl2831u_frontend_attach()
745 dev->demod_i2c_adapter = pdata->get_i2c_adapter(client); in rtl2831u_frontend_attach()
747 dev->i2c_client_demod = client; in rtl2831u_frontend_attach()
751 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2831u_frontend_attach()
796 dev_dbg(&d->intf->dev, "cmd=%d arg=%d\n", cmd, arg); in rtl2832u_fc0012_tuner_callback()
816 ret = -EINVAL; in rtl2832u_fc0012_tuner_callback()
821 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2832u_fc0012_tuner_callback()
831 dev_dbg(&d->intf->dev, "cmd=%d arg=%d\n", cmd, arg); in rtl2832u_tua9001_tuner_callback()
864 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2832u_tua9001_tuner_callback()
872 struct device *parent = adapter->dev.parent; in rtl2832u_frontend_callback()
883 if (parent != NULL && parent->type == &i2c_adapter_type) in rtl2832u_frontend_callback()
886 return -EINVAL; in rtl2832u_frontend_callback()
889 dev = d->priv; in rtl2832u_frontend_callback()
891 dev_dbg(&d->intf->dev, "component=%d cmd=%d arg=%d\n", in rtl2832u_frontend_callback()
896 switch (dev->tuner) { in rtl2832u_frontend_callback()
911 struct rtl2832_platform_data *pdata = &dev->rtl2832_platform_data; in rtl2832u_frontend_attach()
916 dev_dbg(&d->intf->dev, "\n"); in rtl2832u_frontend_attach()
918 switch (dev->tuner) { in rtl2832u_frontend_attach()
942 dev_err(&d->intf->dev, "unknown tuner %s\n", dev->tuner_name); in rtl2832u_frontend_attach()
943 ret = -ENODEV; in rtl2832u_frontend_attach()
953 client = i2c_new_client_device(&d->i2c_adap, &board_info); in rtl2832u_frontend_attach()
955 ret = -ENODEV; in rtl2832u_frontend_attach()
959 if (!try_module_get(client->dev.driver->owner)) { in rtl2832u_frontend_attach()
961 ret = -ENODEV; in rtl2832u_frontend_attach()
965 adap->fe[0] = pdata->get_dvb_frontend(client); in rtl2832u_frontend_attach()
966 dev->demod_i2c_adapter = pdata->get_i2c_adapter(client); in rtl2832u_frontend_attach()
968 dev->i2c_client_demod = client; in rtl2832u_frontend_attach()
971 adap->fe[0]->callback = rtl2832u_frontend_callback; in rtl2832u_frontend_attach()
973 if (dev->slave_demod) { in rtl2832u_frontend_attach()
977 if (dev->slave_demod == SLAVE_DEMOD_MN88472) { in rtl2832u_frontend_attach()
980 mn88472_config.fe = &adap->fe[1]; in rtl2832u_frontend_attach()
989 client = i2c_new_client_device(&d->i2c_adap, &info); in rtl2832u_frontend_attach()
993 if (!try_module_get(client->dev.driver->owner)) { in rtl2832u_frontend_attach()
998 dev->i2c_client_slave_demod = client; in rtl2832u_frontend_attach()
999 } else if (dev->slave_demod == SLAVE_DEMOD_MN88473) { in rtl2832u_frontend_attach()
1002 mn88473_config.fe = &adap->fe[1]; in rtl2832u_frontend_attach()
1008 client = i2c_new_client_device(&d->i2c_adap, &info); in rtl2832u_frontend_attach()
1012 if (!try_module_get(client->dev.driver->owner)) { in rtl2832u_frontend_attach()
1017 dev->i2c_client_slave_demod = client; in rtl2832u_frontend_attach()
1018 } else if (dev->slave_demod == SLAVE_DEMOD_CXD2837ER) { in rtl2832u_frontend_attach()
1026 adap->fe[1] = dvb_attach(cxd2841er_attach_t_c, in rtl2832u_frontend_attach()
1028 &d->i2c_adap); in rtl2832u_frontend_attach()
1029 if (!adap->fe[1]) in rtl2832u_frontend_attach()
1031 adap->fe[1]->id = 1; in rtl2832u_frontend_attach()
1032 dev->i2c_client_slave_demod = NULL; in rtl2832u_frontend_attach()
1038 si2168_config.fe = &adap->fe[1]; in rtl2832u_frontend_attach()
1046 client = i2c_new_client_device(&d->i2c_adap, &info); in rtl2832u_frontend_attach()
1050 if (!try_module_get(client->dev.driver->owner)) { in rtl2832u_frontend_attach()
1055 dev->i2c_client_slave_demod = client; in rtl2832u_frontend_attach()
1058 dev->new_i2c_write = true; in rtl2832u_frontend_attach()
1064 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2832u_frontend_attach()
1069 * We continue on reduced mode, without DVB-T2/C, using master in rtl2832u_frontend_attach()
1072 dev->slave_demod = SLAVE_DEMOD_NONE; in rtl2832u_frontend_attach()
1080 if (dev->chip_id == CHIP_ID_RTL2831U) in rtl28xxu_frontend_attach()
1092 dev_dbg(&d->intf->dev, "\n"); in rtl28xxu_frontend_detach()
1095 client = dev->i2c_client_slave_demod; in rtl28xxu_frontend_detach()
1097 module_put(client->dev.driver->owner); in rtl28xxu_frontend_detach()
1102 client = dev->i2c_client_demod; in rtl28xxu_frontend_detach()
1104 module_put(client->dev.driver->owner); in rtl28xxu_frontend_detach()
1144 dev_dbg(&d->intf->dev, "\n"); in rtl2831u_tuner_attach()
1146 switch (dev->tuner) { in rtl2831u_tuner_attach()
1148 fe = dvb_attach(qt1010_attach, adap->fe[0], in rtl2831u_tuner_attach()
1149 dev->demod_i2c_adapter, in rtl2831u_tuner_attach()
1153 fe = dvb_attach(mt2060_attach, adap->fe[0], in rtl2831u_tuner_attach()
1154 dev->demod_i2c_adapter, in rtl2831u_tuner_attach()
1158 fe = dvb_attach(mxl5005s_attach, adap->fe[0], in rtl2831u_tuner_attach()
1159 dev->demod_i2c_adapter, in rtl2831u_tuner_attach()
1164 dev_err(&d->intf->dev, "unknown tuner %d\n", dev->tuner); in rtl2831u_tuner_attach()
1168 ret = -ENODEV; in rtl2831u_tuner_attach()
1174 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2831u_tuner_attach()
1209 dev_dbg(&d->intf->dev, "\n"); in rtl2832u_tuner_attach()
1214 switch (dev->tuner) { in rtl2832u_tuner_attach()
1216 fe = dvb_attach(fc0012_attach, adap->fe[0], in rtl2832u_tuner_attach()
1217 dev->demod_i2c_adapter, &rtl2832u_fc0012_config); in rtl2832u_tuner_attach()
1221 adap->fe[0]->ops.read_signal_strength = in rtl2832u_tuner_attach()
1222 adap->fe[0]->ops.tuner_ops.get_rf_strength; in rtl2832u_tuner_attach()
1225 fe = dvb_attach(fc0013_attach, adap->fe[0], in rtl2832u_tuner_attach()
1226 dev->demod_i2c_adapter, 0xc6>>1, 0, FC_XTAL_28_8_MHZ); in rtl2832u_tuner_attach()
1229 adap->fe[0]->ops.read_signal_strength = in rtl2832u_tuner_attach()
1230 adap->fe[0]->ops.tuner_ops.get_rf_strength; in rtl2832u_tuner_attach()
1234 .fe = adap->fe[0], in rtl2832u_tuner_attach()
1243 client = i2c_new_client_device(dev->demod_i2c_adapter, in rtl2832u_tuner_attach()
1248 if (!try_module_get(client->dev.driver->owner)) { in rtl2832u_tuner_attach()
1253 dev->i2c_client_tuner = client; in rtl2832u_tuner_attach()
1259 .dvb_frontend = adap->fe[0], in rtl2832u_tuner_attach()
1267 client = i2c_new_client_device(dev->demod_i2c_adapter, in rtl2832u_tuner_attach()
1271 if (!try_module_get(client->dev.driver->owner)) { in rtl2832u_tuner_attach()
1275 dev->i2c_client_tuner = client; in rtl2832u_tuner_attach()
1281 .dvb_frontend = adap->fe[0], in rtl2832u_tuner_attach()
1298 client = i2c_new_client_device(dev->demod_i2c_adapter, in rtl2832u_tuner_attach()
1302 if (!try_module_get(client->dev.driver->owner)) { in rtl2832u_tuner_attach()
1306 dev->i2c_client_tuner = client; in rtl2832u_tuner_attach()
1310 fe = dvb_attach(r820t_attach, adap->fe[0], in rtl2832u_tuner_attach()
1311 dev->demod_i2c_adapter, in rtl2832u_tuner_attach()
1315 adap->fe[0]->ops.read_signal_strength = in rtl2832u_tuner_attach()
1316 adap->fe[0]->ops.tuner_ops.get_rf_strength; in rtl2832u_tuner_attach()
1319 fe = dvb_attach(r820t_attach, adap->fe[0], in rtl2832u_tuner_attach()
1320 dev->demod_i2c_adapter, in rtl2832u_tuner_attach()
1322 adap->fe[0]->ops.read_signal_strength = in rtl2832u_tuner_attach()
1323 adap->fe[0]->ops.tuner_ops.get_rf_strength; in rtl2832u_tuner_attach()
1325 if (adap->fe[1]) { in rtl2832u_tuner_attach()
1326 fe = dvb_attach(r820t_attach, adap->fe[1], in rtl2832u_tuner_attach()
1327 dev->demod_i2c_adapter, in rtl2832u_tuner_attach()
1329 adap->fe[1]->ops.read_signal_strength = in rtl2832u_tuner_attach()
1330 adap->fe[1]->ops.tuner_ops.get_rf_strength; in rtl2832u_tuner_attach()
1335 .fe = adap->fe[0], in rtl2832u_tuner_attach()
1344 client = i2c_new_client_device(&d->i2c_adap, &info); in rtl2832u_tuner_attach()
1348 if (!try_module_get(client->dev.driver->owner)) { in rtl2832u_tuner_attach()
1353 dev->i2c_client_tuner = client; in rtl2832u_tuner_attach()
1357 if (adap->fe[1]) { in rtl2832u_tuner_attach()
1358 adap->fe[1]->tuner_priv = in rtl2832u_tuner_attach()
1359 adap->fe[0]->tuner_priv; in rtl2832u_tuner_attach()
1360 memcpy(&adap->fe[1]->ops.tuner_ops, in rtl2832u_tuner_attach()
1361 &adap->fe[0]->ops.tuner_ops, in rtl2832u_tuner_attach()
1367 dev_err(&d->intf->dev, "unknown tuner %d\n", dev->tuner); in rtl2832u_tuner_attach()
1369 if (fe == NULL && dev->i2c_client_tuner == NULL) { in rtl2832u_tuner_attach()
1370 ret = -ENODEV; in rtl2832u_tuner_attach()
1375 switch (dev->tuner) { in rtl2832u_tuner_attach()
1382 pdata.clk = dev->rtl2832_platform_data.clk; in rtl2832u_tuner_attach()
1383 pdata.tuner = dev->tuner; in rtl2832u_tuner_attach()
1384 pdata.regmap = dev->rtl2832_platform_data.regmap; in rtl2832u_tuner_attach()
1385 pdata.dvb_frontend = adap->fe[0]; in rtl2832u_tuner_attach()
1390 pdev = platform_device_register_data(&d->intf->dev, in rtl2832u_tuner_attach()
1394 if (IS_ERR(pdev) || pdev->dev.driver == NULL) in rtl2832u_tuner_attach()
1396 dev->platform_device_sdr = pdev; in rtl2832u_tuner_attach()
1399 dev_dbg(&d->intf->dev, "no SDR for tuner=%d\n", dev->tuner); in rtl2832u_tuner_attach()
1404 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2832u_tuner_attach()
1412 if (dev->chip_id == CHIP_ID_RTL2831U) in rtl28xxu_tuner_attach()
1425 dev_dbg(&d->intf->dev, "\n"); in rtl28xxu_tuner_detach()
1428 pdev = dev->platform_device_sdr; in rtl28xxu_tuner_detach()
1433 client = dev->i2c_client_tuner; in rtl28xxu_tuner_detach()
1435 module_put(client->dev.driver->owner); in rtl28xxu_tuner_detach()
1447 dev_dbg(&d->intf->dev, "\n"); in rtl28xxu_init()
1472 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl28xxu_init()
1481 dev_dbg(&d->intf->dev, "onoff=%d\n", onoff); in rtl2831u_power_ctrl()
1488 /* tuner power, read GPIOs */ in rtl2831u_power_ctrl()
1493 dev_dbg(&d->intf->dev, "RD SYS0=%02x GPIO_OUT_VAL=%02x\n", sys0, gpio); in rtl2831u_power_ctrl()
1512 dev_dbg(&d->intf->dev, "WR SYS0=%02x GPIO_OUT_VAL=%02x\n", sys0, gpio); in rtl2831u_power_ctrl()
1519 /* tuner power, write GPIOs */ in rtl2831u_power_ctrl()
1530 usb_clear_halt(d->udev, usb_rcvbulkpipe(d->udev, 0x81)); in rtl2831u_power_ctrl()
1534 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2831u_power_ctrl()
1542 dev_dbg(&d->intf->dev, "onoff=%d\n", onoff); in rtl2832u_power_ctrl()
1570 ret = usb_clear_halt(d->udev, usb_rcvbulkpipe(d->udev, 0x81)); in rtl2832u_power_ctrl()
1592 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2832u_power_ctrl()
1600 if (dev->chip_id == CHIP_ID_RTL2831U) in rtl28xxu_power_ctrl()
1610 struct rtl2832_platform_data *pdata = &dev->rtl2832_platform_data; in rtl28xxu_frontend_ctrl()
1614 dev_dbg(&d->intf->dev, "fe=%d onoff=%d\n", fe->id, onoff); in rtl28xxu_frontend_ctrl()
1616 if (dev->chip_id == CHIP_ID_RTL2831U) in rtl28xxu_frontend_ctrl()
1619 if (fe->id == 0) { in rtl28xxu_frontend_ctrl()
1629 } else if (fe->id == 1) { in rtl28xxu_frontend_ctrl()
1631 ret = pdata->slave_ts_ctrl(dev->i2c_client_demod, onoff); in rtl28xxu_frontend_ctrl()
1638 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl28xxu_frontend_ctrl()
1646 struct rtl28xxu_dev *dev = d->priv; in rtl2831u_rc_query()
1667 if (!dev->rc_active) { in rtl2831u_rc_query()
1674 dev->rc_active = true; in rtl2831u_rc_query()
1702 rc_keydown(d->rc_dev, proto, rc_code, 0); in rtl2831u_rc_query()
1716 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2831u_rc_query()
1723 rc->map_name = RC_MAP_EMPTY; in rtl2831u_get_rc_config()
1724 rc->allowed_protos = RC_PROTO_BIT_NEC | RC_PROTO_BIT_NECX | in rtl2831u_get_rc_config()
1726 rc->query = rtl2831u_rc_query; in rtl2831u_get_rc_config()
1727 rc->interval = 400; in rtl2831u_get_rc_config()
1735 struct rtl28xxu_dev *dev = d->priv; in rtl2832u_rc_query()
1745 if (!dev->rc_active) { in rtl2832u_rc_query()
1772 dev->rc_active = true; in rtl2832u_rc_query()
1805 ir_raw_event_store_with_filter(d->rc_dev, &ev); in rtl2832u_rc_query()
1809 ir_raw_event_handle(d->rc_dev); in rtl2832u_rc_query()
1813 dev_dbg(&d->intf->dev, "failed=%d\n", ret); in rtl2832u_rc_query()
1825 if (!rc->map_name) in rtl2832u_get_rc_config()
1826 rc->map_name = RC_MAP_EMPTY; in rtl2832u_get_rc_config()
1827 rc->allowed_protos = RC_PROTO_BIT_ALL_IR_DECODER; in rtl2832u_get_rc_config()
1828 rc->driver_type = RC_DRIVER_IR_RAW; in rtl2832u_get_rc_config()
1829 rc->query = rtl2832u_rc_query; in rtl2832u_get_rc_config()
1830 rc->interval = 200; in rtl2832u_get_rc_config()
1832 rc->timeout = 0xbf * 51; in rtl2832u_get_rc_config()
1842 if (dev->chip_id == CHIP_ID_RTL2831U) in rtl28xxu_get_rc_config()
1855 if (dev->chip_id == CHIP_ID_RTL2831U) { in rtl28xxu_pid_filter_ctrl()
1856 struct rtl2830_platform_data *pdata = &dev->rtl2830_platform_data; in rtl28xxu_pid_filter_ctrl()
1858 return pdata->pid_filter_ctrl(adap->fe[0], onoff); in rtl28xxu_pid_filter_ctrl()
1860 struct rtl2832_platform_data *pdata = &dev->rtl2832_platform_data; in rtl28xxu_pid_filter_ctrl()
1862 return pdata->pid_filter_ctrl(adap->fe[0], onoff); in rtl28xxu_pid_filter_ctrl()
1871 if (dev->chip_id == CHIP_ID_RTL2831U) { in rtl28xxu_pid_filter()
1872 struct rtl2830_platform_data *pdata = &dev->rtl2830_platform_data; in rtl28xxu_pid_filter()
1874 return pdata->pid_filter(adap->fe[0], index, pid, onoff); in rtl28xxu_pid_filter()
1876 struct rtl2832_platform_data *pdata = &dev->rtl2832_platform_data; in rtl28xxu_pid_filter()
1878 return pdata->pid_filter(adap->fe[0], index, pid, onoff); in rtl28xxu_pid_filter()
1920 &rtl28xxu_props, "Freecom USB2.0 DVB-T", NULL) },
1922 &rtl28xxu_props, "Freecom USB2.0 DVB-T", NULL) },
1932 &rtl28xxu_props, "G-Tek Electronics Group Lifeview LV5TDLX DVB-T", NULL) },
1940 &rtl28xxu_props, "Trekstor DVB-T Stick Terres 2.0", NULL) },
1942 &rtl28xxu_props, "Dexatek DK DVB-T Dongle", NULL) },
1944 &rtl28xxu_props, "DigitalNow Quad DVB-T Receiver", NULL) },
1952 &rtl28xxu_props, "Dexatek DK mini DVB-T Dongle", NULL) },
1956 &rtl28xxu_props, "ASUS My Cinema-U3100Mini Plus V2", NULL) },
1966 &rtl28xxu_props, "MaxMedia HU394-T", NULL) },
1972 &rtl28xxu_props, "Genius TVGo DVB-T03", NULL) },
1974 &rtl28xxu_props, "Peak DVB-T USB", NULL) },
1982 &rtl28xxu_props, "TURBO-X Pure TV Tuner DTT-2000", NULL) },
1988 &rtl28xxu_props, "Astrometa DVB-T2",