Draft: wifi: auto-activate devices as soon as the first scan finishes

Beniamino Galvani requested to merge bg/wifi-scan into master

Currently if we detect that a scan finished in _scan_notify_is_scanning(), we call immediately _scan_kickoff() (which might start a new scan) and then we check again whether the device can autoactivate or whether to remove the wifi-scan pending action.

This means that if the scan takes long enough, when _scan_notify_is_scanning() is called, it is already time to start another scan and the device activation will be delayed. It will be delayed until the scan duration becomes shorter than the exponentially-growing periodic scan interval.

Fix this by delaying the call to _scan_kickoff().

#574 (closed)

Merge request reports