diff --git a/mmrc-submodule/src/core/mmrc.c b/mmrc-submodule/src/core/mmrc.c index 808974c..aab96a1 100644 --- a/mmrc-submodule/src/core/mmrc.c +++ b/mmrc-submodule/src/core/mmrc.c @@ -884,8 +884,17 @@ void mmrc_get_rates(struct mmrc_table *tb, ((tb->last_lookaround_cycle + LOOKAROUND_MAX_RC_CYCLES) <= tb->cycle_cnt)); - /* Also skip sampling if we don't yet have data for our best rate */ - if (tb->table[tb->best_tp.index].evidence == 0) + /* Also skip sampling if we don't yet have data for our best rate. + * Exception: when the periodic forced lookaround is due. On links + * carrying fewer than min_stats unicast frames per RC cycle, the + * best-rate row can never accumulate evidence, so an unconditional + * veto here permanently disables all sampling and the table freezes + * at whatever rate it last converged to (observed in the field as + * links latched at MCS0 with -40 dBm signal until re-association). + */ + if (tb->table[tb->best_tp.index].evidence == 0 && + (tb->last_lookaround_cycle + LOOKAROUND_MAX_RC_CYCLES) > + tb->cycle_cnt) is_lookaround = false; if (tb->lookaround_wrap != LOOKAROUND_RATE_STABLE) { @@ -1227,7 +1236,7 @@ void mmrc_update(struct mmrc_table *tb) */ if (tb->lookaround_wrap != LOOKAROUND_RATE_INIT && (tb->unconverged || - (tb->best_tp.bw == MMRC_BW_1MHZ && tb->best_tp.rate <= MMRC_MCS2))) { + tb->best_tp.rate <= MMRC_MCS2)) { tb->lookaround_cnt = 0; tb->lookaround_wrap = LOOKAROUND_RATE_INIT; tb->stability_cnt_threshold = STABILITY_CNT_THRESHOLD_INIT;