Skip to content
Snippets Groups Projects
Unverified Commit da22c5cf authored by Matthias Schiffer's avatar Matthias Schiffer
Browse files

gluon-core: gluon.util: change find_phy argument to config table and make public

parent 9d5c5511
No related branches found
No related tags found
No related merge requests found
...@@ -149,9 +149,7 @@ local function find_phy_by_macaddr(macaddr) ...@@ -149,9 +149,7 @@ local function find_phy_by_macaddr(macaddr)
end end
end end
local function find_phy(radio) function find_phy(config)
local config = uci:get_all('wireless', radio)
if not config or config.type ~= 'mac80211' then if not config or config.type ~= 'mac80211' then
return nil return nil
elseif config.path then elseif config.path then
...@@ -164,7 +162,7 @@ local function find_phy(radio) ...@@ -164,7 +162,7 @@ local function find_phy(radio)
end end
local function get_addresses(radio) local function get_addresses(radio)
local phy = find_phy(radio) local phy = find_phy(uci:get_all('wireless', radio))
if not phy then if not phy then
return function() end return function() end
end end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment