band-steering: add band-steering component

This adds a new band-steering component to usteer.

With band-steering enabled, usteer will attempt to move clients with a
consistently good SNR / signal from 2.4 GHz to the 5 GHz band.

In contrast to existing policies usteer tracks, band-steering is
non-invasive and will not lead to forceful connection termination.

Signed-off-by: David Bauer <mail@david-bauer.net>
This commit is contained in:
David Bauer
2022-03-15 22:56:14 +01:00
parent 439acc5d2b
commit f4e120c9a3
10 changed files with 156 additions and 2 deletions

View File

@@ -188,6 +188,9 @@ struct usteer_config {
uint32_t roam_kick_delay;
uint32_t band_steering_interval;
int32_t band_steering_min_snr;
uint32_t initial_connect_delay;
bool load_kick_enabled;
@@ -253,6 +256,10 @@ struct sta_info {
uint64_t timestamp;
} bss_transition_response;
struct {
bool below_snr;
} band_steering;
uint64_t kick_time;
int kick_count;
@@ -318,10 +325,15 @@ int usteer_local_node_get_beacon_interval(struct usteer_local_node *ln);
bool usteer_policy_node_below_max_assoc(struct usteer_node *node);
void usteer_band_steering_perform_steer(struct usteer_local_node *ln);
void usteer_band_steering_sta_update(struct sta_info *si);
bool usteer_band_steering_is_target(struct usteer_local_node *ln, struct usteer_node *node);
void usteer_ubus_init(struct ubus_context *ctx);
void usteer_ubus_kick_client(struct sta_info *si);
int usteer_ubus_trigger_client_scan(struct sta_info *si);
int usteer_ubus_notify_client_disassoc(struct sta_info *si);
int usteer_ubus_band_steering_request(struct sta_info *si);
int usteer_ubus_bss_transition_request(struct sta_info *si,
uint8_t dialog_token,
bool disassoc_imminent,