summaryrefslogtreecommitdiffhomepage
path: root/modules/admin-full/luasrc/model
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2011-05-19 23:51:50 +0000
committerJo-Philipp Wich <jow@openwrt.org>2011-05-19 23:51:50 +0000
commit5b464e500b80ae26d1a741bb3880c62877c95975 (patch)
tree3fca5aba32fc63d102ffee2d5e3683f67b743113 /modules/admin-full/luasrc/model
parentf8ef4ff722377e41a6a8f57caed287c25846bf8d (diff)
modules/admin-full: fix wrong logic in r7078
Diffstat (limited to 'modules/admin-full/luasrc/model')
-rw-r--r--modules/admin-full/luasrc/model/cbi/admin_network/vlan.lua7
1 files changed, 2 insertions, 5 deletions
diff --git a/modules/admin-full/luasrc/model/cbi/admin_network/vlan.lua b/modules/admin-full/luasrc/model/cbi/admin_network/vlan.lua
index e58ac9e991..911245740b 100644
--- a/modules/admin-full/luasrc/model/cbi/admin_network/vlan.lua
+++ b/modules/admin-full/luasrc/model/cbi/admin_network/vlan.lua
@@ -21,7 +21,7 @@ m.uci:foreach("network", "switch",
local has_vlan4k = nil
local has_ptpvid = nil
local has_jumbo3 = nil
- local min_vid = 1
+ local min_vid = 0
local max_vid = 16
local num_vlans = 16
local num_ports = 5
@@ -54,6 +54,7 @@ m.uci:foreach("network", "switch",
num_ports = tonumber(num_ports) or 5
num_vlans = tonumber(num_vlans) or 16
cpu_port = tonumber(cpu_port) or 5
+ min_vid = 1
elseif line:match(": pvid") or line:match(": tag") or line:match(": vid") then
if is_vlan_attr then has_vlan4k = line:match(": (%w+)") end
@@ -68,10 +69,6 @@ m.uci:foreach("network", "switch",
end
swc:close()
-
- -- We have no swconfig, assume /proc/switch
- else
- min_vid = 0
end