+-------------------- Madwifi Interface ----------------------
+
+if hwtype == "atheros" then
+ mode:value("ahdemo", translate("a_w_ahdemo"))
+ mode:value("monitor", translate("a_w_monitor"))
+
+ bssid:depends({mode="adhoc"})
+ bssid:depends({mode="ahdemo"})
+
+ wds = s:option(Flag, "wds", translate("a_w_wds"))
+ wds:depends({mode="ap"})
+ wds:depends({mode="sta"})
+ wds.rmempty = true
+ wdssep = s:option(Flag, "wdssep", translate("wifi_wdssep"))
+ wdssep:depends({mode="ap", wds="1"})
+ wdssep.optional = true
+
+ s:option(Flag, "doth", "802.11h").optional = true
+ hidden = s:option(Flag, "hidden", translate("wifi_hidden"))
+ hidden:depends({mode="ap"})
+ hidden:depends({mode="adhoc"})
+ hidden:depends({mode="wds"})
+ hidden.optional = true
+ isolate = s:option(Flag, "isolate", translate("wifi_isolate"),
+ translate("wifi_isolate_desc"))
+ isolate:depends({mode="ap"})
+ isolate.optional = true
+ s:option(Flag, "bgscan", translate("wifi_bgscan")).optional = true
+
+ mp = s:option(ListValue, "macpolicy", translate("wifi_macpolicy"))
+ mp.optional = true
+ mp:value("")
+ mp:value("deny", translate("wifi_whitelist"))
+ mp:value("allow", translate("wifi_blacklist"))
+ ml = s:option(DynamicList, "maclist", translate("wifi_maclist"))
+ ml:depends({macpolicy="allow"})
+ ml:depends({macpolicy="deny"})
+
+ s:option(Value, "rate", translate("wifi_rate")).optional = true
+ s:option(Value, "mcast_rate", translate("wifi_mcast_rate")).optional = true
+ s:option(Value, "frag", translate("wifi_frag")).optional = true
+ s:option(Value, "rts", translate("wifi_rts")).optional = true
+ s:option(Value, "minrate", translate("wifi_minrate")).optional = true
+ s:option(Value, "maxrate", translate("wifi_maxrate")).optional = true
+ s:option(Flag, "compression", translate("wifi_compression")).optional = true
+
+ s:option(Flag, "bursting", translate("wifi_bursting")).optional = true
+ s:option(Flag, "turbo", translate("wifi_turbo")).optional = true
+ s:option(Flag, "ff", translate("wifi_ff")).optional = true
+
+ s:option(Flag, "wmm", translate("wifi_wmm")).optional = true
+ s:option(Flag, "xr", translate("wifi_xr")).optional = true
+ s:option(Flag, "ar", translate("wifi_ar")).optional = true
+
+ local swm = s:option(Flag, "sw_merge", translate("wifi_nosbeacon"))
+ swm:depends({mode="adhoc"})
+ swm.optional = true
+
+ local nos = s:option(Flag, "nosbeacon", translate("wifi_nosbeacon"))
+ nos:depends({mode="sta"})
+ nos.optional = true
+
+ local probereq = s:option(Flag, "probereq", translate("wifi_noprobereq"))
+ probereq.optional = true
+ probereq.enabled = "0"
+ probereq.disabled = "1"
+end