Lines Matching refs:ter_state

87 	struct stv0367ter_state *ter_state;  member
970 struct stv0367ter_state *ter_state = state->ter_state; in stv0367ter_init() local
974 ter_state->pBER = 0; in stv0367ter_init()
989 ter_state->first_lock = 0; in stv0367ter_init()
990 ter_state->unlock_counter = 2; in stv0367ter_init()
999 struct stv0367ter_state *ter_state = state->ter_state; in stv0367ter_algo() local
1011 ter_state->frequency = p->frequency; in stv0367ter_algo()
1012 ter_state->force = FE_TER_FORCENONE in stv0367ter_algo()
1014 ter_state->if_iq_mode = state->config->if_iq_mode; in stv0367ter_algo()
1044 if (ter_state->if_iq_mode == FE_TER_IQ_TUNER) in stv0367ter_algo()
1046 ter_state->sense); in stv0367ter_algo()
1049 ter_state->sense); in stv0367ter_algo()
1054 if (ter_state->if_iq_mode == FE_TER_IQ_TUNER) in stv0367ter_algo()
1064 if ((ter_state->if_iq_mode != FE_TER_NORMAL_IF_TUNER) && in stv0367ter_algo()
1065 (ter_state->pBW != ter_state->bw)) { in stv0367ter_algo()
1079 if (!stv0367_iir_filt_init(state, ter_state->bw, in stv0367ter_algo()
1083 ter_state->pBW = ter_state->bw; in stv0367ter_algo()
1088 if (ter_state->hierarchy == FE_TER_HIER_LOW_PRIO) in stv0367ter_algo()
1095 ((((ter_state->bw * 64 * (1 << 15) * 100) in stv0367ter_algo()
1106 temp = (int)(((1 << 17) * ter_state->bw * 1000) / (7 * (InternalFreq))); in stv0367ter_algo()
1119 ter_state->echo_pos = 0; in stv0367ter_algo()
1120 ter_state->ucblocks = 0; /* liplianin */ in stv0367ter_algo()
1121 ter_state->pBER = 0; /* liplianin */ in stv0367ter_algo()
1122 stv0367_writebits(state, F367TER_LONG_ECHO, ter_state->echo_pos); in stv0367ter_algo()
1127 ter_state->state = FE_TER_LOCKOK; in stv0367ter_algo()
1129 ter_state->mode = stv0367_readbits(state, F367TER_SYR_MODE); in stv0367ter_algo()
1130 ter_state->guard = stv0367_readbits(state, F367TER_SYR_GUARD); in stv0367ter_algo()
1132 ter_state->first_lock = 1; /* we know sense now :) */ in stv0367ter_algo()
1134 ter_state->agc_val = in stv0367ter_algo()
1151 if (ter_state->mode == FE_TER_MODE_2K) in stv0367ter_algo()
1153 else if (ter_state->mode == FE_TER_MODE_4K) in stv0367ter_algo()
1155 else if (ter_state->mode == FE_TER_MODE_8K) in stv0367ter_algo()
1165 if (ter_state->bw == 6) in stv0367ter_algo()
1167 else if (ter_state->bw == 7) in stv0367ter_algo()
1170 ter_state->frequency += offset; in stv0367ter_algo()
1226 struct stv0367ter_state *ter_state = state->ter_state; in stv0367ter_set_frontend() local
1247 ter_state->mode = FE_TER_MODE_2K; in stv0367ter_set_frontend()
1253 ter_state->mode = FE_TER_MODE_8K; in stv0367ter_set_frontend()
1263 ter_state->guard = p->guard_interval; in stv0367ter_set_frontend()
1266 ter_state->guard = GUARD_INTERVAL_1_32; in stv0367ter_set_frontend()
1272 ter_state->bw = FE_TER_CHAN_BW_6M; in stv0367ter_set_frontend()
1275 ter_state->bw = FE_TER_CHAN_BW_7M; in stv0367ter_set_frontend()
1279 ter_state->bw = FE_TER_CHAN_BW_8M; in stv0367ter_set_frontend()
1282 ter_state->hierarchy = FE_TER_HIER_NONE; in stv0367ter_set_frontend()
1291 if (ter_state->first_lock) in stv0367ter_set_frontend()
1296 ter_state->state = FE_TER_NOLOCK; in stv0367ter_set_frontend()
1299 while (((index) < num_trials) && (ter_state->state != FE_TER_LOCKOK)) { in stv0367ter_set_frontend()
1300 if (!ter_state->first_lock) { in stv0367ter_set_frontend()
1302 ter_state->sense = SenseTrials[index]; in stv0367ter_set_frontend()
1307 if ((ter_state->state == FE_TER_LOCKOK) && in stv0367ter_set_frontend()
1324 struct stv0367ter_state *ter_state = state->ter_state; in stv0367ter_read_ucblocks() local
1335 ter_state->ucblocks = errs; in stv0367ter_read_ucblocks()
1338 (*ucblocks) = ter_state->ucblocks; in stv0367ter_read_ucblocks()
1347 struct stv0367ter_state *ter_state = state->ter_state; in stv0367ter_get_frontend() local
1387 if (ter_state->hierarchy == FE_TER_HIER_LOW_PRIO) in stv0367ter_get_frontend()
1469 struct stv0367ter_state *ter_state = state->ter_state;
1474 ter_state->unlock_counter += 1;
1476 ter_state->unlock_counter = 0;
1478 if (ter_state->unlock_counter > 2) {
1515 struct stv0367ter_state *ter_state = state->ter_state; in stv0367ter_read_ber() local
1530 tber = ter_state->pBER; in stv0367ter_read_ber()
1588 ter_state->pBER = tber; in stv0367ter_read_ber()
1597 struct stv0367ter_state *ter_state = state->ter_state;
1657 ter_state->pPER = Per;
1677 kfree(state->ter_state); in stv0367_release()
1716 struct stv0367ter_state *ter_state = NULL; in stv0367ter_attach() local
1722 ter_state = kzalloc(sizeof(struct stv0367ter_state), GFP_KERNEL); in stv0367ter_attach()
1723 if (ter_state == NULL) in stv0367ter_attach()
1729 state->ter_state = ter_state; in stv0367ter_attach()
1749 kfree(ter_state); in stv0367ter_attach()
3171 struct stv0367ter_state *ter_state = state->ter_state; in stv0367ddb_init() local
3243 ter_state->pBER = 0; in stv0367ddb_init()
3244 ter_state->first_lock = 0; in stv0367ddb_init()
3245 ter_state->unlock_counter = 2; in stv0367ddb_init()
3291 struct stv0367ter_state *ter_state = NULL; in stv0367ddb_attach() local
3298 ter_state = kzalloc(sizeof(struct stv0367ter_state), GFP_KERNEL); in stv0367ddb_attach()
3299 if (ter_state == NULL) in stv0367ddb_attach()
3308 state->ter_state = ter_state; in stv0367ddb_attach()
3339 kfree(ter_state); in stv0367ddb_attach()