1 #!/bin/sh /etc/rc.common
9 setup_switch() { return 0; }
19 procd_set_param command /sbin/netifd
20 procd_set_param respawn
21 procd_set_param watch network.interface
22 [ -e /proc/sys/kernel/core_pattern ] && {
23 procd_set_param limits core="unlimited"
24 echo '/tmp/%e.%p.%s.%t.core' > /proc/sys/kernel/core_pattern
31 ubus call network reload
32 /sbin/wifi reload_legacy
41 ubus -t 30 wait_for network.interface
42 /sbin/wifi reload_legacy
45 validate_atm_bridge_section()
47 uci_validate_section network "atm-bridge" "${1}" \
49 'vci:range(32, 65535):35' \
50 'vpi:range(0, 255):8' \
52 'encaps:or("llc", "vc"):llc' \
53 'payload:or("bridged", "routed"):bridged'
56 validate_route_section()
58 uci_validate_section network route "${1}" \
65 'table:or(range(0,65535),string)'
68 validate_route6_section()
70 uci_validate_section network route6 "${1}" \
76 'table:or(range(0,65535),string)'
79 validate_rule_section()
81 uci_validate_section network rule "${1}" \
89 'lookup:or(range(0,65535),string)' \
90 'goto:range(0,65535)' \
91 'action:or("prohibit", "unreachable", "blackhole", "throw")'
94 validate_rule6_section()
96 uci_validate_section network rule6 "${1}" \
104 'lookup:or(range(0,65535),string)' \
105 'goto:range(0,65535)' \
106 'action:or("prohibit", "unreachable", "blackhole", "throw")'
109 validate_switch_section()
111 uci_validate_section network switch "${1}" \
118 validate_switch_vlan()
120 uci_validate_section network switch_vlan "${1}" \
128 procd_add_reload_trigger network wireless
131 validate_atm_bridge_section
132 validate_route_section
133 validate_route6_section
134 validate_rule_section
135 validate_rule6_section
136 validate_switch_section