Added initialization for routing APs.

This commit is contained in:
mark 2000-06-16 00:06:34 +00:00
parent 6f35799dcc
commit 6bc08b0db5
2 changed files with 35 additions and 9 deletions

View File

@ -203,12 +203,19 @@ case "$ACTION" in
wlan_restore_schemefile
fi
# ==========AP BRIDGE====================================
# For AP, initialize the bridge. Do NOT put the wlan MAC in promisc
# mode. NOTE: Physically ejecting either card while the bridge
# ==========AP Interface====================================
# For AP, interface initialization depends on whether we're
# routing or bridging. If routing, bring up the interface
# using the standard pcmcia-cs network script (like a STA).
# Note that routing APs will require that STAs have their
# gateway address set to the AP's address.
# If bridging, do NOT put the wlan MAC in promisc
# mode. The code here will set up the bridge device and
# set it up. NOTE: Physically ejecting either card while the bridge
# is active commonly leaves a system unstable (or locked). Use
# 'cardctl eject' on the wlan device prior to removal.
if is_true $IS_AP ; then
if is_true $IS_AP ; then if is_true $IS_BRIDGE; then
if is_true $IS_OLDBRIDGE; then
ifconfig $APWIREDDEVICE promisc
ifconfig $DEVICE up
@ -223,7 +230,25 @@ case "$ACTION" in
ifconfig $DEVICE up 0.0.0.0
ifconfig $APBRIDGEDEVICE up $AP_IPADDR
fi
fi
else
# Just set up the AP interface like any other net
# device.
# ==========PCMCIA NETDEVICE=============================
# Append the SSID to the pcmcia scheme name
wlan_set_ssid_schemefile "$WLAN_SCHEMESSID"
# Call the normal network initialization
./network $1 $2
if [ ! $? ] ; then
echo "/etc/pcmcia/network initialization failed."
wlan_restore_schemefile
exit 1
fi
# Restore scheme file to it's prior contents
wlan_restore_schemefile
fi;fi
;;
'stop'|'suspend')

View File

@ -58,9 +58,9 @@ case "$ADDRESS" in
#=======DOWNLOAD======================================
# Do we need to download code/data to the card?
WLAN_DOWNLOAD=n
WLAN_DOWNLOAD=y
WLAN_DOWNLOADER=/sbin/prism2dl
WLAN_DLIMAGE=/etc/wlan/apfw.hex
WLAN_DLIMAGE=/etc/pcmcia/t10002c5.hex
#=======USER MIB SETTINGS=============================
# You can add the assignments for various MIB items
@ -97,11 +97,12 @@ case "$ADDRESS" in
# If IS_AP is 'y', then the following settings will be
# used in the creation of a BSS with this station acting
# as the AP. If IS_AP is 'n', these settings are ignored.
IS_AP=n # y|n
IS_AP=y # y|n
IS_BRIDGE=n # Are we a bridging AP?
IS_OLDBRIDGE=n # Which kernel bridge code are we using?
APWIREDDEVICE=eth0 # Must be an ethernet device
APBRIDGEDEVICE=apbr0 # Bridge interface name
AP_IPADDR=192.168.200.150 # Bridge IP address
AP_IPADDR=192.168.200.150 # Bridge IP address (and only bridge)
APSSID="WLAN_PRISM2" # SSID the AP will use, max 32 chars
APBCNINT=100 # Beacon interval (in Kus)
APDTIMINT=3 # DTIM interval (in beacons)