Lines Matching refs:fe

106 	return (adap->fe_adap[0].fe = dvb_attach(dib3000mc_attach, &adap->dev->i2c_adap,  in bristol_frontend_attach()
123 struct i2c_adapter *tun_i2c = dib3000mc_get_tuner_i2c_master(adap->fe_adap[0].fe, 1); in bristol_tuner_attach()
130 return dvb_attach(mt2060_attach, adap->fe_adap[0].fe, tun_i2c, in bristol_tuner_attach()
300 adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, in stk7700P2_frontend_attach()
304 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk7700P2_frontend_attach()
334 adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, in stk7700d_frontend_attach()
338 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk7700d_frontend_attach()
346 tun_i2c = state->dib7000p_ops.get_i2c_master(adap->fe_adap[0].fe, in stk7700d_tuner_attach()
348 return dvb_attach(mt2266_attach, adap->fe_adap[0].fe, tun_i2c, in stk7700d_tuner_attach()
429 state->dib7000p_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 0); in stk7700ph_xc3028_callback()
431 state->dib7000p_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 1); in stk7700ph_xc3028_callback()
486 adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 0x80, in stk7700ph_frontend_attach()
489 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk7700ph_frontend_attach()
497 tun_i2c = state->dib7000p_ops.get_i2c_master(adap->fe_adap[0].fe, in stk7700ph_tuner_attach()
503 adap->fe_adap[0].fe->callback = stk7700ph_xc3028_callback; in stk7700ph_tuner_attach()
505 return dvb_attach(xc2028_attach, adap->fe_adap[0].fe, &stk7700ph_xc3028_config) in stk7700ph_tuner_attach()
725 …adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 18, &stk7700p_dib7000p_config… in stk7700p_frontend_attach()
729 …adap->fe_adap[0].fe = dvb_attach(dib7000m_attach, &adap->dev->i2c_adap, 18, &stk7700p_dib7000m_con… in stk7700p_frontend_attach()
732 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk7700p_frontend_attach()
753 tun_i2c = state->dib7000p_ops.get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTERFACE_TUNER, 1); in stk7700p_tuner_attach()
755 tun_i2c = dib7000m_get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTERFACE_TUNER, 1); in stk7700p_tuner_attach()
757 return dvb_attach(mt2060_attach, adap->fe_adap[0].fe, tun_i2c, &stk7700p_mt2060_config, in stk7700p_tuner_attach()
795 static int dib7070_tuner_reset(struct dvb_frontend *fe, int onoff) in dib7070_tuner_reset() argument
797 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib7070_tuner_reset()
801 return state->dib7000p_ops.set_gpio(fe, 8, 0, !onoff); in dib7070_tuner_reset()
804 static int dib7070_tuner_sleep(struct dvb_frontend *fe, int onoff) in dib7070_tuner_sleep() argument
806 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib7070_tuner_sleep()
810 return state->dib7000p_ops.set_gpio(fe, 9, 0, onoff); in dib7070_tuner_sleep()
840 static int dib7070_set_param_override(struct dvb_frontend *fe) in dib7070_set_param_override() argument
842 struct dtv_frontend_properties *p = &fe->dtv_property_cache; in dib7070_set_param_override()
843 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib7070_set_param_override()
853 deb_info("WBD for DiB7000P: %d\n", offset + dib0070_wbd_offset(fe)); in dib7070_set_param_override()
854 state->dib7000p_ops.set_wbd_ref(fe, offset + dib0070_wbd_offset(fe)); in dib7070_set_param_override()
855 return state->set_param_save(fe); in dib7070_set_param_override()
858 static int dib7770_set_param_override(struct dvb_frontend *fe) in dib7770_set_param_override() argument
860 struct dtv_frontend_properties *p = &fe->dtv_property_cache; in dib7770_set_param_override()
861 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib7770_set_param_override()
868 state->dib7000p_ops.set_gpio(fe, 0, 0, 1); in dib7770_set_param_override()
873 state->dib7000p_ops.set_gpio(fe, 0, 0, 0); in dib7770_set_param_override()
877 deb_info("WBD for DiB7000P: %d\n", offset + dib0070_wbd_offset(fe)); in dib7770_set_param_override()
878 state->dib7000p_ops.set_wbd_ref(fe, offset + dib0070_wbd_offset(fe)); in dib7770_set_param_override()
879 return state->set_param_save(fe); in dib7770_set_param_override()
885 struct i2c_adapter *tun_i2c = st->dib7000p_ops.get_i2c_master(adap->fe_adap[0].fe, in dib7770p_tuner_attach()
888 if (dvb_attach(dib0070_attach, adap->fe_adap[0].fe, tun_i2c, in dib7770p_tuner_attach()
892 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in dib7770p_tuner_attach()
893 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib7770_set_param_override; in dib7770p_tuner_attach()
900 …struct i2c_adapter *tun_i2c = st->dib7000p_ops.get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INT… in dib7070p_tuner_attach()
903 if (dvb_attach(dib0070_attach, adap->fe_adap[0].fe, tun_i2c, &dib7070p_dib0070_config[0]) == NULL) in dib7070p_tuner_attach()
906 if (dvb_attach(dib0070_attach, adap->fe_adap[0].fe, tun_i2c, &dib7070p_dib0070_config[1]) == NULL) in dib7070p_tuner_attach()
910 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in dib7070p_tuner_attach()
911 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib7070_set_param_override; in dib7070p_tuner_attach()
922 return state->dib7000p_ops.pid_filter(adapter->fe_adap[0].fe, index, pid, onoff); in stk7700p_pid_filter()
923 return dib7000m_pid_filter(adapter->fe_adap[0].fe, index, pid, onoff); in stk7700p_pid_filter()
931 return state->dib7000p_ops.pid_filter_ctrl(adapter->fe_adap[0].fe, onoff); in stk7700p_pid_filter_ctrl()
932 return dib7000m_pid_filter_ctrl(adapter->fe_adap[0].fe, onoff); in stk7700p_pid_filter_ctrl()
938 return state->dib7000p_ops.pid_filter(adapter->fe_adap[0].fe, index, pid, onoff); in stk70x0p_pid_filter()
944 return state->dib7000p_ops.pid_filter_ctrl(adapter->fe_adap[0].fe, onoff); in stk70x0p_pid_filter_ctrl()
1017 adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 0x80, in stk7070p_frontend_attach()
1019 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk7070p_frontend_attach()
1075 adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 0x80, in stk7770p_frontend_attach()
1077 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk7770p_frontend_attach()
1229 static int dib80xx_tuner_reset(struct dvb_frontend *fe, int onoff) in dib80xx_tuner_reset() argument
1231 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib80xx_tuner_reset()
1234 return state->dib8000_ops.set_gpio(fe, 5, 0, !onoff); in dib80xx_tuner_reset()
1237 static int dib80xx_tuner_sleep(struct dvb_frontend *fe, int onoff) in dib80xx_tuner_sleep() argument
1239 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib80xx_tuner_sleep()
1242 return state->dib8000_ops.set_gpio(fe, 0, 0, onoff); in dib80xx_tuner_sleep()
1282 static int dib807x_set_param_override(struct dvb_frontend *fe) in dib807x_set_param_override() argument
1284 struct dtv_frontend_properties *p = &fe->dtv_property_cache; in dib807x_set_param_override()
1285 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib807x_set_param_override()
1288 u16 offset = dib0070_wbd_offset(fe); in dib807x_set_param_override()
1299 state->dib8000_ops.set_wbd_ref(fe, offset); in dib807x_set_param_override()
1301 return state->set_param_save(fe); in dib807x_set_param_override()
1307 struct i2c_adapter *tun_i2c = st->dib8000_ops.get_i2c_master(adap->fe_adap[0].fe, in dib807x_tuner_attach()
1311 if (dvb_attach(dib0070_attach, adap->fe_adap[0].fe, tun_i2c, in dib807x_tuner_attach()
1315 if (dvb_attach(dib0070_attach, adap->fe_adap[0].fe, tun_i2c, in dib807x_tuner_attach()
1320 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in dib807x_tuner_attach()
1321 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib807x_set_param_override; in dib807x_tuner_attach()
1330 return state->dib8000_ops.pid_filter(adapter->fe_adap[0].fe, index, pid, onoff); in stk80xx_pid_filter()
1338 return state->dib8000_ops.pid_filter_ctrl(adapter->fe_adap[0].fe, onoff); in stk80xx_pid_filter_ctrl()
1367 adap->fe_adap[0].fe = state->dib8000_ops.init(&adap->dev->i2c_adap, 0x80, in stk807x_frontend_attach()
1370 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk807x_frontend_attach()
1401 adap->fe_adap[0].fe = state->dib8000_ops.init(&adap->dev->i2c_adap, 0x80, in stk807xpvr_frontend_attach0()
1404 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk807xpvr_frontend_attach0()
1417 adap->fe_adap[0].fe = state->dib8000_ops.init(&adap->dev->i2c_adap, 0x82, in stk807xpvr_frontend_attach1()
1420 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk807xpvr_frontend_attach1()
1535 static int dib8090_get_adc_power(struct dvb_frontend *fe) in dib8090_get_adc_power() argument
1537 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib8090_get_adc_power()
1540 return state->dib8000_ops.get_adc_power(fe, 1); in dib8090_get_adc_power()
1543 static void dib8090_agc_control(struct dvb_frontend *fe, u8 restart) in dib8090_agc_control() argument
1546 dib0090_dcc_freq(fe, restart); in dib8090_agc_control()
1549 dib0090_set_dc_servo(fe, 1); in dib8090_agc_control()
1625 static u8 dib8090_compute_pll_parameters(struct dvb_frontend *fe) in dib8090_compute_pll_parameters() argument
1633 ratio = ((fe->dtv_property_cache.frequency / 1000) * (1 << 8) / 1000) / freq_adc; in dib8090_compute_pll_parameters()
1634 rest = ((fe->dtv_property_cache.frequency / 1000) * (1 << 8) / 1000) - ratio * freq_adc; in dib8090_compute_pll_parameters()
1649 static int dib8096_set_param_override(struct dvb_frontend *fe) in dib8096_set_param_override() argument
1651 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib8096_set_param_override()
1653 u8 pll_ratio, band = BAND_OF_FREQUENCY(fe->dtv_property_cache.frequency / 1000); in dib8096_set_param_override()
1661 …deb_info("Warning : Rf frequency (%iHz) is not in the supported range, using VHF switch ", fe->dt… in dib8096_set_param_override()
1663 state->dib8000_ops.set_gpio(fe, 3, 0, 1); in dib8096_set_param_override()
1666 state->dib8000_ops.set_gpio(fe, 3, 0, 0); in dib8096_set_param_override()
1670 ret = state->set_param_save(fe); in dib8096_set_param_override()
1674 if (fe->dtv_property_cache.bandwidth_hz != 6000000) { in dib8096_set_param_override()
1680 …state->dib8000_ops.update_pll(fe, &dib8090_pll_config_12mhz, fe->dtv_property_cache.bandwidth_hz /… in dib8096_set_param_override()
1683 pll_ratio = dib8090_compute_pll_parameters(fe); in dib8096_set_param_override()
1694 …state->dib8000_ops.update_pll(fe, &dib8090_pll_config_12mhz, fe->dtv_property_cache.bandwidth_hz /… in dib8096_set_param_override()
1696 state->dib8000_ops.ctrl_timf(fe, DEMOD_TIMF_SET, timf); in dib8096_set_param_override()
1700 target = (dib0090_get_wbd_target(fe) * 8 * 18 / 33 + 1) / 2; in dib8096_set_param_override()
1701 state->dib8000_ops.set_wbd_ref(fe, target); in dib8096_set_param_override()
1706 dib0090_set_tune_state(fe, CT_AGC_START); in dib8096_set_param_override()
1709 ret = dib0090_gain_control(fe); in dib8096_set_param_override()
1711 tune_state = dib0090_get_tune_state(fe); in dib8096_set_param_override()
1713 state->dib8000_ops.set_gpio(fe, 6, 0, 1); in dib8096_set_param_override()
1715 dib0090_get_current_gain(fe, NULL, NULL, &rf_gain_limit, &ltgain); in dib8096_set_param_override()
1717 state->dib8000_ops.set_gpio(fe, 6, 0, 0); in dib8096_set_param_override()
1722 dib0090_pwm_gain_reset(fe); in dib8096_set_param_override()
1723 state->dib8000_ops.pwm_agc_reset(fe); in dib8096_set_param_override()
1724 state->dib8000_ops.set_tune_state(fe, CT_DEMOD_START); in dib8096_set_param_override()
1728 dib0090_pwm_gain_reset(fe); in dib8096_set_param_override()
1737 …struct i2c_adapter *tun_i2c = st->dib8000_ops.get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTE… in dib809x_tuner_attach()
1739 if (dvb_attach(dib0090_register, adap->fe_adap[0].fe, tun_i2c, &dib809x_dib0090_config) == NULL) in dib809x_tuner_attach()
1742 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in dib809x_tuner_attach()
1743 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib8096_set_param_override; in dib809x_tuner_attach()
1771 …adap->fe_adap[0].fe = state->dib8000_ops.init(&adap->dev->i2c_adap, 0x80, &dib809x_dib8000_config[… in stk809x_frontend_attach()
1773 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk809x_frontend_attach()
1780 struct dvb_frontend *fe_slave = st->dib8000_ops.get_slave_frontend(adap->fe_adap[0].fe, 1); in nim8096md_tuner_attach()
1786 fe_slave->dvb = adap->fe_adap[0].fe->dvb; in nim8096md_tuner_attach()
1789 tun_i2c = st->dib8000_ops.get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTERFACE_TUNER, 1); in nim8096md_tuner_attach()
1790 if (dvb_attach(dib0090_register, adap->fe_adap[0].fe, tun_i2c, &dib809x_dib0090_config) == NULL) in nim8096md_tuner_attach()
1793 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in nim8096md_tuner_attach()
1794 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib8096_set_param_override; in nim8096md_tuner_attach()
1826 …adap->fe_adap[0].fe = state->dib8000_ops.init(&adap->dev->i2c_adap, 0x80, &dib809x_dib8000_config[… in nim8096md_frontend_attach()
1827 if (adap->fe_adap[0].fe == NULL) in nim8096md_frontend_attach()
1835 state->dib8000_ops.set_slave_frontend(adap->fe_adap[0].fe, fe_slave); in nim8096md_frontend_attach()
2023 static int dib8096p_get_best_sampling(struct dvb_frontend *fe, struct dibx090p_best_adc *adc) in dib8096p_get_best_sampling() argument
2038 deb_info("bandwidth = %d", fe->dtv_property_cache.bandwidth_hz); in dib8096p_get_best_sampling()
2064 …if ((fdem >= fdem_min) && (fmem <= fmem_max) && (fs >= fe->dtv_property_cache.bandwidth_hz / 1000)… in dib8096p_get_best_sampling()
2067 …for (harmonic_id = (fe->dtv_property_cache.frequency / (1000 * fs)); harmonic_id <= ((fe->dtv_pro… in dib8096p_get_best_sampling()
2068fe->dtv_property_cache.frequency / 1000 - (fe->dtv_property_cache.bandwidth_hz / 2000))) && ((fs … in dib8096p_get_best_sampling()
2080 …d; Fdem %6d; Fs %6d; Prediv %2d; Loopdiv %2d; Timf %8d;", fe->dtv_property_cache.frequency, fe->dt… in dib8096p_get_best_sampling()
2095 static int dib8096p_agc_startup(struct dvb_frontend *fe) in dib8096p_agc_startup() argument
2097 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib8096p_agc_startup()
2104 ret = state->set_param_save(fe); in dib8096p_agc_startup()
2109 dib0090_pwm_gain_reset(fe); in dib8096p_agc_startup()
2112 target = (dib0090_get_wbd_target(fe) * 8 + 1) / 2; in dib8096p_agc_startup()
2113 state->dib8000_ops.set_wbd_ref(fe, target); in dib8096p_agc_startup()
2115 if (dib8096p_get_best_sampling(fe, &adc) == 0) { in dib8096p_agc_startup()
2120 state->dib8000_ops.update_pll(fe, &pll, fe->dtv_property_cache.bandwidth_hz / 1000, 0); in dib8096p_agc_startup()
2121 state->dib8000_ops.ctrl_timf(fe, DEMOD_TIMF_SET, adc.timf); in dib8096p_agc_startup()
2157 adap->fe_adap[0].fe = state->dib8000_ops.init(&adap->dev->i2c_adap, in tfe8096p_frontend_attach()
2160 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in tfe8096p_frontend_attach()
2166 struct i2c_adapter *tun_i2c = st->dib8000_ops.get_i2c_tuner(adap->fe_adap[0].fe); in tfe8096p_tuner_attach()
2172 if (dvb_attach(dib0090_register, adap->fe_adap[0].fe, tun_i2c, in tfe8096p_tuner_attach()
2176 st->dib8000_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 1); in tfe8096p_tuner_attach()
2178 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in tfe8096p_tuner_attach()
2179 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib8096p_agc_startup; in tfe8096p_tuner_attach()
2186 return dib9000_fw_pid_filter(adapter->fe_adap[0].fe, index, pid, onoff); in dib90x0_pid_filter()
2191 return dib9000_fw_pid_filter_ctrl(adapter->fe_adap[0].fe, onoff); in dib90x0_pid_filter_ctrl()
2194 static int dib90x0_tuner_reset(struct dvb_frontend *fe, int onoff) in dib90x0_tuner_reset() argument
2196 return dib9000_set_gpio(fe, 5, 0, !onoff); in dib90x0_tuner_reset()
2199 static int dib90x0_tuner_sleep(struct dvb_frontend *fe, int onoff) in dib90x0_tuner_sleep() argument
2201 return dib9000_set_gpio(fe, 0, 0, onoff); in dib90x0_tuner_sleep()
2403 adap->fe_adap[0].fe = dvb_attach(dib9000_attach, &adap->dev->i2c_adap, 0x80, &stk9090m_config); in stk9090m_frontend_attach()
2405 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk9090m_frontend_attach()
2411 struct i2c_adapter *i2c = dib9000_get_tuner_interface(adap->fe_adap[0].fe); in dib9090_tuner_attach()
2420 if (dvb_attach(dib0090_fw_register, adap->fe_adap[0].fe, i2c, &dib9090_dib0090_config) == NULL) in dib9090_tuner_attach()
2422 i2c = dib9000_get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTERFACE_GPIO_1_2, 0); in dib9090_tuner_attach()
2426 if (dib9000_firmware_post_pll_init(adap->fe_adap[0].fe) < 0) in dib9090_tuner_attach()
2472 adap->fe_adap[0].fe = dvb_attach(dib9000_attach, &adap->dev->i2c_adap, 0x80, &nim9090md_config[0]); in nim9090md_frontend_attach()
2474 if (adap->fe_adap[0].fe == NULL) in nim9090md_frontend_attach()
2477 i2c = dib9000_get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTERFACE_GPIO_3_4, 0); in nim9090md_frontend_attach()
2481 dib9000_set_slave_frontend(adap->fe_adap[0].fe, fe_slave); in nim9090md_frontend_attach()
2498 i2c = dib9000_get_tuner_interface(adap->fe_adap[0].fe); in nim9090md_tuner_attach()
2499 …if (dvb_attach(dib0090_fw_register, adap->fe_adap[0].fe, i2c, &nim9090md_dib0090_config[0]) == NUL… in nim9090md_tuner_attach()
2501 i2c = dib9000_get_i2c_master(adap->fe_adap[0].fe, DIBX000_I2C_INTERFACE_GPIO_1_2, 0); in nim9090md_tuner_attach()
2506 if (dib9000_firmware_post_pll_init(adap->fe_adap[0].fe) < 0) in nim9090md_tuner_attach()
2509 fe_slave = dib9000_get_slave_frontend(adap->fe_adap[0].fe, 1); in nim9090md_tuner_attach()
2511 i2c = dib9000_get_component_bus_interface(adap->fe_adap[0].fe); in nim9090md_tuner_attach()
2517 fe_slave->dvb = adap->fe_adap[0].fe->dvb; in nim9090md_tuner_attach()
2518 dib9000_fw_set_component_bus_speed(adap->fe_adap[0].fe, 1500); in nim9090md_tuner_attach()
2528 static int dib7090p_get_best_sampling(struct dvb_frontend *fe , struct dibx090p_best_adc *adc) in dib7090p_get_best_sampling() argument
2544 deb_info("bandwidth = %d fdem_min =%d", fe->dtv_property_cache.bandwidth_hz, fdem_min); in dib7090p_get_best_sampling()
2569 …if ((fdem >= fdem_min) && (fdem <= fdem_max) && (fs >= fe->dtv_property_cache.bandwidth_hz/1000)) { in dib7090p_get_best_sampling()
2572 …for (harmonic_id = (fe->dtv_property_cache.frequency / (1000*fs)) ; harmonic_id <= ((fe->dtv_prop… in dib7090p_get_best_sampling()
2573fe->dtv_property_cache.frequency/1000) - (fe->dtv_property_cache.bandwidth_hz/2000))) && ((fs*har… in dib7090p_get_best_sampling()
2601 static int dib7090_agc_startup(struct dvb_frontend *fe) in dib7090_agc_startup() argument
2603 struct dvb_usb_adapter *adap = fe->dvb->priv; in dib7090_agc_startup()
2610 ret = state->set_param_save(fe); in dib7090_agc_startup()
2615 dib0090_pwm_gain_reset(fe); in dib7090_agc_startup()
2616 target = (dib0090_get_wbd_target(fe) * 8 + 1) / 2; in dib7090_agc_startup()
2617 state->dib7000p_ops.set_wbd_ref(fe, target); in dib7090_agc_startup()
2619 if (dib7090p_get_best_sampling(fe, &adc) == 0) { in dib7090_agc_startup()
2623 state->dib7000p_ops.update_pll(fe, &pll); in dib7090_agc_startup()
2624 state->dib7000p_ops.ctrl_timf(fe, DEMOD_TIMF_SET, adc.timf); in dib7090_agc_startup()
2629 static int dib7090_agc_restart(struct dvb_frontend *fe, u8 restart) in dib7090_agc_restart() argument
2633 dib0090_set_dc_servo(fe, 1); in dib7090_agc_restart()
2637 static int tfe7790p_update_lna(struct dvb_frontend *fe, u16 agc_global) in tfe7790p_update_lna() argument
2639 struct dvb_usb_adapter *adap = fe->dvb->priv; in tfe7790p_update_lna()
2645 state->dib7000p_ops.set_gpio(fe, 8, 0, 0); in tfe7790p_update_lna()
2646 state->dib7000p_ops.set_agc1_min(fe, 0); in tfe7790p_update_lna()
2648 state->dib7000p_ops.set_gpio(fe, 8, 0, 1); in tfe7790p_update_lna()
2649 state->dib7000p_ops.set_agc1_min(fe, 32768); in tfe7790p_update_lna()
2792 static int tfe7090p_pvr_update_lna(struct dvb_frontend *fe, u16 agc_global) in tfe7090p_pvr_update_lna() argument
2794 struct dvb_usb_adapter *adap = fe->dvb->priv; in tfe7090p_pvr_update_lna()
2799 state->dib7000p_ops.set_gpio(fe, 5, 0, 0); in tfe7090p_pvr_update_lna()
2800 state->dib7000p_ops.set_agc1_min(fe, 0); in tfe7090p_pvr_update_lna()
2802 state->dib7000p_ops.set_gpio(fe, 5, 0, 1); in tfe7090p_pvr_update_lna()
2803 state->dib7000p_ops.set_agc1_min(fe, 32768); in tfe7090p_pvr_update_lna()
3042 …adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 0x80, &nim7090_dib7000p_confi… in nim7090_frontend_attach()
3044 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in nim7090_frontend_attach()
3050 struct i2c_adapter *tun_i2c = st->dib7000p_ops.get_i2c_tuner(adap->fe_adap[0].fe); in nim7090_tuner_attach()
3056 if (dvb_attach(dib0090_register, adap->fe_adap[0].fe, tun_i2c, &nim7090_dib0090_config) == NULL) in nim7090_tuner_attach()
3059 st->dib7000p_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 1); in nim7090_tuner_attach()
3061 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in nim7090_tuner_attach()
3062 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib7090_agc_startup; in nim7090_tuner_attach()
3097 …adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 0x90, &tfe7090pvr_dib7000p_co… in tfe7090pvr_frontend0_attach()
3098 if (adap->fe_adap[0].fe == NULL) in tfe7090pvr_frontend0_attach()
3101 state->dib7000p_ops.slave_reset(adap->fe_adap[0].fe); in tfe7090pvr_frontend0_attach()
3111 if (adap->dev->adapter[0].fe_adap[0].fe == NULL) { in tfe7090pvr_frontend1_attach()
3119 …i2c = state->dib7000p_ops.get_i2c_master(adap->dev->adapter[0].fe_adap[0].fe, DIBX000_I2C_INTERFAC… in tfe7090pvr_frontend1_attach()
3126 adap->fe_adap[0].fe = state->dib7000p_ops.init(i2c, 0x92, &tfe7090pvr_dib7000p_config[1]); in tfe7090pvr_frontend1_attach()
3129 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in tfe7090pvr_frontend1_attach()
3135 struct i2c_adapter *tun_i2c = st->dib7000p_ops.get_i2c_tuner(adap->fe_adap[0].fe); in tfe7090pvr_tuner0_attach()
3141 …if (dvb_attach(dib0090_register, adap->fe_adap[0].fe, tun_i2c, &tfe7090pvr_dib0090_config[0]) == N… in tfe7090pvr_tuner0_attach()
3144 st->dib7000p_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 1); in tfe7090pvr_tuner0_attach()
3146 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in tfe7090pvr_tuner0_attach()
3147 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib7090_agc_startup; in tfe7090pvr_tuner0_attach()
3154 struct i2c_adapter *tun_i2c = st->dib7000p_ops.get_i2c_tuner(adap->fe_adap[0].fe); in tfe7090pvr_tuner1_attach()
3160 …if (dvb_attach(dib0090_register, adap->fe_adap[0].fe, tun_i2c, &tfe7090pvr_dib0090_config[1]) == N… in tfe7090pvr_tuner1_attach()
3163 st->dib7000p_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 1); in tfe7090pvr_tuner1_attach()
3165 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in tfe7090pvr_tuner1_attach()
3166 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib7090_agc_startup; in tfe7090pvr_tuner1_attach()
3200 adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, in tfe7790p_frontend_attach()
3203 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in tfe7790p_frontend_attach()
3210 st->dib7000p_ops.get_i2c_tuner(adap->fe_adap[0].fe); in tfe7790p_tuner_attach()
3217 if (dvb_attach(dib0090_register, adap->fe_adap[0].fe, tun_i2c, in tfe7790p_tuner_attach()
3221 st->dib7000p_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 1); in tfe7790p_tuner_attach()
3223 st->set_param_save = adap->fe_adap[0].fe->ops.tuner_ops.set_params; in tfe7790p_tuner_attach()
3224 adap->fe_adap[0].fe->ops.tuner_ops.set_params = dib7090_agc_startup; in tfe7790p_tuner_attach()
3296 …adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 0x80, &stk7070pd_dib7000p_con… in stk7070pd_frontend_attach0()
3297 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk7070pd_frontend_attach0()
3307 …adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 0x82, &stk7070pd_dib7000p_con… in stk7070pd_frontend_attach1()
3308 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in stk7070pd_frontend_attach1()
3311 static int novatd_read_status_override(struct dvb_frontend *fe, in novatd_read_status_override() argument
3314 struct dvb_usb_adapter *adap = fe->dvb->priv; in novatd_read_status_override()
3319 ret = state->read_status(fe, stat); in novatd_read_status_override()
3328 static int novatd_sleep_override(struct dvb_frontend* fe) in novatd_sleep_override() argument
3330 struct dvb_usb_adapter *adap = fe->dvb->priv; in novatd_sleep_override()
3337 return state->sleep(fe); in novatd_sleep_override()
3372 adap->fe_adap[0].fe = state->dib7000p_ops.init(&dev->i2c_adap, in novatd_frontend_attach()
3376 if (adap->fe_adap[0].fe == NULL) in novatd_frontend_attach()
3379 st->read_status = adap->fe_adap[0].fe->ops.read_status; in novatd_frontend_attach()
3380 adap->fe_adap[0].fe->ops.read_status = novatd_read_status_override; in novatd_frontend_attach()
3381 st->sleep = adap->fe_adap[0].fe->ops.sleep; in novatd_frontend_attach()
3382 adap->fe_adap[0].fe->ops.sleep = novatd_sleep_override; in novatd_frontend_attach()
3439 adap->fe_adap[0].fe = dvb_attach(s5h1411_attach, &pinnacle_801e_config, in s5h1411_frontend_attach()
3441 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in s5h1411_frontend_attach()
3471 adap->fe_adap[0].fe->callback = dib0700_xc5000_tuner_callback; in xc5000_tuner_attach()
3473 return dvb_attach(xc5000_attach, adap->fe_adap[0].fe, &adap->dev->i2c_adap, in xc5000_tuner_attach()
3486 state->dib7000p_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 0); in dib0700_xc4000_tuner_callback()
3488 state->dib7000p_ops.set_gpio(adap->fe_adap[0].fe, 8, 0, 1); in dib0700_xc4000_tuner_callback()
3607 adap->fe_adap[0].fe = state->dib7000p_ops.init(&adap->dev->i2c_adap, 0x12, in pctv340e_frontend_attach()
3611 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in pctv340e_frontend_attach()
3628 tun_i2c = state->dib7000p_ops.get_i2c_master(adap->fe_adap[0].fe, in xc4000_tuner_attach()
3636 adap->fe_adap[0].fe->callback = dib0700_xc4000_tuner_callback; in xc4000_tuner_attach()
3638 return dvb_attach(xc4000_attach, adap->fe_adap[0].fe, tun_i2c, in xc4000_tuner_attach()
3694 adap->fe_adap[0].fe = dvb_attach(lgdt3305_attach, in lgdt3305_frontend_attach()
3698 return adap->fe_adap[0].fe == NULL ? -ENODEV : 0; in lgdt3305_frontend_attach()
3703 return dvb_attach(mxl5007t_attach, adap->fe_adap[0].fe, in mxl5007t_tuner_attach()
3836 .fe = {{
3900 .fe = {{
3908 .fe = {{
3940 .fe = {{
3952 .fe = {{
4005 .fe = {{
4050 .fe = {{
4131 .fe = {{
4176 .fe = {{
4188 .fe = {{
4233 .fe = {{
4245 .fe = {{
4299 .fe = {{
4311 .fe = {{
4348 .fe = {{
4416 .fe = {{
4452 .fe = {{
4478 .fe = {{
4528 .fe = {{
4572 .fe = {{
4585 .fe = {{
4621 .fe = {{
4658 .fe = {{
4695 .fe = {{
4732 .fe = {{
4769 .fe = {{
4806 .fe = {{
4820 .fe = {{
4857 .fe = {{
4892 .fe = {{
4929 .fe = {{