config: make remote_node_timeout configurable
authorDavid Bauer <mail@david-bauer.net>
Sat, 1 Jan 2022 17:00:45 +0000 (18:00 +0100)
committerDavid Bauer <mail@david-bauer.net>
Sun, 9 Jan 2022 01:09:26 +0000 (02:09 +0100)
The logic for customizing the remote_node_timeout config option was
missing. The default value of 10 could not be altered by a user.

Add the required logic and a short explanation of the config-option to
the default configuration.

Signed-off-by: David Bauer <mail@david-bauer.net>
openwrt/usteer/files/etc/config/usteer
openwrt/usteer/files/etc/init.d/usteer
ubus.c

index 2fe1c983d066d1a570a07ce8c39d430aca7e5215..f0b8867407271f0d200ec23725b8f82228b98f44 100644 (file)
@@ -44,6 +44,9 @@ config usteer
        # Interval (ms) between sending state updates to other APs
        #option remote_update_interval 1000
 
+       # Number of remote update intervals after which a remote-node is deleted
+       #option remote_node_timeout 10
+
        # Allow rejecting assoc requests for steering purposes (0/1)
        #option assoc_steering 0
 
index 1f9ab0621673c6e7ff1dce6b0f1e6d7bd8676c73..d3579e75840a9bac3f0402a626c05e5e222f5ef6 100755 (executable)
@@ -77,7 +77,7 @@ uci_usteer() {
                sta_block_timeout local_sta_timeout local_sta_update \
                max_neighbor_reports max_retry_band seen_policy_timeout \
                load_balancing_threshold band_steering_threshold \
-               remote_update_interval \
+               remote_update_interval remote_node_timeout\
                min_connect_snr min_snr signal_diff_threshold \
                initial_connect_delay roam_process_timeout\
                roam_kick_delay roam_scan_tries \
diff --git a/ubus.c b/ubus.c
index 83a7558702e4c76caeb7e3506ea73a9150913774..9b985f4c47e90ad35d18b3d5dce8622438754c99 100644 (file)
--- a/ubus.c
+++ b/ubus.c
@@ -152,6 +152,7 @@ struct cfg_item {
        _cfg(U32, load_balancing_threshold), \
        _cfg(U32, band_steering_threshold), \
        _cfg(U32, remote_update_interval), \
+       _cfg(U32, remote_node_timeout), \
        _cfg(BOOL, assoc_steering), \
        _cfg(I32, min_connect_snr), \
        _cfg(I32, min_snr), \