@@ -96,16 +96,16 @@ void usteer_band_steering_perform_steer(struct usteer_local_node *ln)
}
if (si->bss_transition) {
- if (!si->kick_time && si->sta->aggressive) {
- si->kick_time = current_time + config.roam_kick_delay;
- validity_period = 10000 / usteer_local_node_get_beacon_interval(ln); /* ~ 10 seconds */
- disassoc_timer = (si->kick_time - current_time) / usteer_local_node_get_beacon_interval(ln);
-
- if (si->sta->aggressive)
- usteer_ubus_band_steering_request(si, 0, true, disassoc_timer, true, validity_period);
- else
- usteer_ubus_band_steering_request(si, 0, false, 0, true, validity_period);
- }
+ validity_period = 10000 / usteer_local_node_get_beacon_interval(ln); /* ~ 10 seconds */
+ if (si->sta->aggressive) {
+ if (!si->kick_time) {
+ si->kick_time = current_time + config.roam_kick_delay;
+ si->roam_transition_request_validity_end = current_time + 10000;
+ disassoc_timer = (si->kick_time - current_time) / usteer_local_node_get_beacon_interval(ln);
+ usteer_ubus_band_steering_request(si, 0, true, disassoc_timer, true, validity_period);
+ }
+ } else
+ usteer_ubus_band_steering_request(si, 0, false, 0, true, validity_period);
}
si->band_steering.below_snr = false;
@@ -375,7 +375,7 @@ usteer_roam_trigger_sm(struct usteer_local_node *ln, struct sta_info *si)
if (!si->kick_time && si->sta->aggressive)
si->kick_time = current_time + config.roam_kick_delay;
-
+ si->roam_transition_request_validity_end = current_time + 10000;
validity_period = 10000 / usteer_local_node_get_beacon_interval(ln); /* ~ 10 seconds */
if (si->sta->aggressive) {
disassoc_timer = (si->kick_time - current_time) / usteer_local_node_get_beacon_interval(ln);
@@ -401,6 +401,10 @@ bool usteer_policy_can_perform_roam(struct sta_info *si)
if (si->kick_time && si->kick_time <= current_time)
return false;
+ /* Skip if in validity period */
+ if (current_time < si->roam_transition_request_validity_end)
+ return false;
+
/* Skip on rejected transition */
if (si->bss_transition_response.status_code && current_time - si->bss_transition_response.timestamp < config.steer_reject_timeout)
return false;
@@ -258,6 +258,7 @@ struct sta_info {
enum roam_trigger_state roam_state;
uint8_t roam_tries;
uint64_t roam_event;
+ uint64_t roam_transition_request_validity_end;
uint64_t roam_kick;
uint64_t roam_scan_start;
uint64_t roam_scan_timeout_start;
- Disaccociation Timer will run a countdown before disaccociate the station - Supporting multiple transisiton requests if validity period of neighbors is over Signed-off-by: Nils Hendrik Rottgardt <n.rottgardt@gmail.com> --- band_steering.c | 20 ++++++++++---------- policy.c | 6 +++++- usteer.h | 1 + 3 files changed, 16 insertions(+), 11 deletions(-)