netifd: ensure that a bridge gets created before hostapd needs it, hostapd must not attempt to create the bridge by itself

SVN-Revision: 28745
master
Felix Fietkau 13 years ago
parent 18a4bbb98d
commit dab5ebaa76
  1. 4
      package/base-files-network/files/lib/network/config.sh
  2. 1
      package/base-files/files/sbin/wifi
  3. 4
      package/netifd/Makefile
  4. 7
      package/netifd/files/lib/network/config.sh

@ -145,6 +145,10 @@ sort_list() {
) | sort -u ) | sort -u
} }
prepare_interface_bridge() {
return 0
}
# Create the interface, if necessary. # Create the interface, if necessary.
# Return status 0 indicates that the setup_interface() call should continue # Return status 0 indicates that the setup_interface() call should continue
# Return status 1 means that everything is set up already. # Return status 1 means that everything is set up already.

@ -40,6 +40,7 @@ bridge_interface() {(
config_get iftype "$cfg" type config_get iftype "$cfg" type
[ "$iftype" = bridge ] && config_get "$cfg" ifname [ "$iftype" = bridge ] && config_get "$cfg" ifname
prepare_interface_bridge "$cfg"
)} )}
prepare_key_wep() { prepare_key_wep() {

@ -1,13 +1,13 @@
include $(TOPDIR)/rules.mk include $(TOPDIR)/rules.mk
PKG_NAME:=netifd PKG_NAME:=netifd
PKG_VERSION:=2011-11-03 PKG_VERSION:=2011-11-04
PKG_RELEASE=$(PKG_SOURCE_VERSION) PKG_RELEASE=$(PKG_SOURCE_VERSION)
PKG_SOURCE_PROTO:=git PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=git://nbd.name/luci2/netifd.git PKG_SOURCE_URL:=git://nbd.name/luci2/netifd.git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION) PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=5c0c0bb557b17c581d4f238c52b0b44ada34a608 PKG_SOURCE_VERSION:=b6d7a8bc9822667cb851bec465c3ad7cd6714e90
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
# PKG_MIRROR_MD5SUM:= # PKG_MIRROR_MD5SUM:=
# CMAKE_INSTALL:=1 # CMAKE_INSTALL:=1

@ -40,6 +40,13 @@ scan_interfaces() {
config_foreach fixup_interface interface config_foreach fixup_interface interface
} }
prepare_interface_bridge() {
local config="$1"
[ -n "$config" ] || return 0
ubus call network.interface."$config" prepare
}
setup_interface() { setup_interface() {
local iface="$1" local iface="$1"
local config="$2" local config="$2"

Loading…
Cancel
Save