mirror of
https://github.com/openwrt/openwrt.git
synced 2025-02-09 04:12:15 +00:00
mac80211: print an error if wifi teardown fails
drv_mac80211_teardown fails silently if the device to be torn down is not defined. This commit prints an error message. branches affected: trunk, 21.02 Signed-off-by: Bob Cantor <coxede6557@w3boats.com> Signed-off-by: maurerr <mariusd84@gmail.com>
This commit is contained in:
parent
8530d727f3
commit
fc14cfeb4d
@ -1190,6 +1190,10 @@ drv_mac80211_teardown() {
|
||||
json_select data
|
||||
json_get_vars phy
|
||||
json_select ..
|
||||
[ -n "$phy" ] || {
|
||||
echo "Bug: PHY is undefined for device '$1'"
|
||||
return 1
|
||||
}
|
||||
|
||||
mac80211_interface_cleanup "$phy"
|
||||
uci -q -P /var/state revert wireless._${phy}
|
||||
|
Loading…
x
Reference in New Issue
Block a user