0.1.16-final

cleanups in wlan_supports_scan
This commit is contained in:
solomon 2003-02-24 14:15:08 +00:00
parent 727e849cde
commit 40f3443b7e
3 changed files with 29 additions and 13 deletions

View File

@ -41,7 +41,9 @@
* Intersil Corporation as part of PRISM(R) chipset product development.
*
* --------------------------------------------------------------------
- Cleaned up some of the errors in the conversion code.
0.1.16
- Minor fixups in /etc/wlan/shared
- Cleaned up some of the error messages in the conversion code.
- changed the "Host de-WEP failed" error to a debug message, as the
/proc/net/wireless stats are updated to reflect undecryptable frames
-pre10

View File

@ -1,7 +1,7 @@
WLAN_VERSION=0
WLAN_PATCHLEVEL=1
WLAN_SUBLEVEL=16
WLAN_EXTRAVERSION=-pre10
WLAN_EXTRAVERSION=
LINUX_SRC=/usr/src/linux
PCMCIA_SRC=
PREFIX=

View File

@ -59,13 +59,28 @@ fi
is_true ()
{
[ "$1" = "y" -o "$1" = "Y" -o "$1" = "yes" -o "$1" = "YES" ]
# $1 == string containing a t/f indicator.
[ "$1" = "y" -o "$1" = "Y" -o "$1" = "yes" -o "$1" = "YES" ]
}
wlan_enable ()
{
#=======ENABLE IFSTATE=============================
# Bring the device into its operable state
# $1 == wlandev
#=======ENABLE IFSTATE=============================
# Bring the device into its operable state
# First, make sure the driver is loaded....
if ! ifconfig $1 2>&1 > /dev/null ; then
echo "Error: Device $1 does not seem to be present."
echo "Make sure you've inserted the appropriate"
echo "modules or that your modules.conf file contains"
echo "the appropriate aliase(s)."
return 1
fi
# Enable the interface
result=`$WLANCTL $1 lnxreq_ifstate ifstate=enable`
if [ $? = 0 ] ; then
eval $result
@ -82,6 +97,8 @@ wlan_enable ()
wlan_user_mibs ()
{
# $1 == wlandev
#=======USER MIB SETTINGS=============================
# Set the user specified MIB items.
for i in $USER_MIBS ; do
@ -140,6 +157,7 @@ wlan_source_config_for_ssid ()
wlan_disable ()
{
# $1 == wlandev
$WLANCTL $1 lnxreq_ifstate ifstate=disable
}
@ -215,16 +233,12 @@ wlan_supports_scan ()
{
# $1 == wlandev
grep 'scan' /proc/net/p80211/$1/wlandev > /dev/null
if [ $? = 0 ] ; then
return 0
fi
if is_true "$WLAN_SCAN" ; then
return 0
cat /proc/net/p80211/$1/wlandev | grep 'scan' > /dev/null
if [ $? = 0 ] ; then
return 0
fi
fi
return 1
}