Lines Matching refs:digtable

309 	struct dig_t *digtable = &rtlpriv->dm_digtable;  in rtl92c_dm_ctrl_initgain_by_rssi()  local
314 digtable->large_fa_hit++; in rtl92c_dm_ctrl_initgain_by_rssi()
315 if (digtable->forbidden_igi < digtable->cur_igvalue) { in rtl92c_dm_ctrl_initgain_by_rssi()
316 digtable->forbidden_igi = digtable->cur_igvalue; in rtl92c_dm_ctrl_initgain_by_rssi()
317 digtable->large_fa_hit = 1; in rtl92c_dm_ctrl_initgain_by_rssi()
320 if (digtable->large_fa_hit >= 3) { in rtl92c_dm_ctrl_initgain_by_rssi()
321 if ((digtable->forbidden_igi + 1) > in rtl92c_dm_ctrl_initgain_by_rssi()
322 digtable->rx_gain_max) in rtl92c_dm_ctrl_initgain_by_rssi()
323 digtable->rx_gain_min = digtable->rx_gain_max; in rtl92c_dm_ctrl_initgain_by_rssi()
325 digtable->rx_gain_min = (digtable->forbidden_igi + 1); in rtl92c_dm_ctrl_initgain_by_rssi()
326 digtable->recover_cnt = 3600; /* 3600=2hr */ in rtl92c_dm_ctrl_initgain_by_rssi()
330 if (digtable->recover_cnt != 0) { in rtl92c_dm_ctrl_initgain_by_rssi()
331 digtable->recover_cnt--; in rtl92c_dm_ctrl_initgain_by_rssi()
333 if (digtable->large_fa_hit == 0) { in rtl92c_dm_ctrl_initgain_by_rssi()
334 if ((digtable->forbidden_igi-1) < DM_DIG_MIN) { in rtl92c_dm_ctrl_initgain_by_rssi()
335 digtable->forbidden_igi = DM_DIG_MIN; in rtl92c_dm_ctrl_initgain_by_rssi()
336 digtable->rx_gain_min = DM_DIG_MIN; in rtl92c_dm_ctrl_initgain_by_rssi()
338 digtable->forbidden_igi--; in rtl92c_dm_ctrl_initgain_by_rssi()
339 digtable->rx_gain_min = digtable->forbidden_igi + 1; in rtl92c_dm_ctrl_initgain_by_rssi()
341 } else if (digtable->large_fa_hit == 3) { in rtl92c_dm_ctrl_initgain_by_rssi()
342 digtable->large_fa_hit = 0; in rtl92c_dm_ctrl_initgain_by_rssi()
351 digtable->fa_lowthresh) { in rtl92c_dm_ctrl_initgain_by_rssi()
352 if ((digtable->back_val - 2) < in rtl92c_dm_ctrl_initgain_by_rssi()
353 digtable->back_range_min) in rtl92c_dm_ctrl_initgain_by_rssi()
354 digtable->back_val = digtable->back_range_min; in rtl92c_dm_ctrl_initgain_by_rssi()
356 digtable->back_val -= 2; in rtl92c_dm_ctrl_initgain_by_rssi()
358 digtable->fa_lowthresh) { in rtl92c_dm_ctrl_initgain_by_rssi()
359 if ((digtable->back_val + 2) > in rtl92c_dm_ctrl_initgain_by_rssi()
360 digtable->back_range_max) in rtl92c_dm_ctrl_initgain_by_rssi()
361 digtable->back_val = digtable->back_range_max; in rtl92c_dm_ctrl_initgain_by_rssi()
363 digtable->back_val += 2; in rtl92c_dm_ctrl_initgain_by_rssi()
366 digtable->back_val = DM_DIG_BACKOFF_DEFAULT; in rtl92c_dm_ctrl_initgain_by_rssi()
371 digtable->cur_igvalue = digtable->pre_igvalue + 2; in rtl92c_dm_ctrl_initgain_by_rssi()
373 digtable->cur_igvalue = digtable->pre_igvalue + 1; in rtl92c_dm_ctrl_initgain_by_rssi()
375 digtable->cur_igvalue = digtable->pre_igvalue - 1; in rtl92c_dm_ctrl_initgain_by_rssi()
379 if (digtable->cur_igvalue > digtable->rx_gain_max) in rtl92c_dm_ctrl_initgain_by_rssi()
380 digtable->cur_igvalue = digtable->rx_gain_max; in rtl92c_dm_ctrl_initgain_by_rssi()
382 if (digtable->cur_igvalue < digtable->rx_gain_min) in rtl92c_dm_ctrl_initgain_by_rssi()
383 digtable->cur_igvalue = digtable->rx_gain_min; in rtl92c_dm_ctrl_initgain_by_rssi()