Re: Problem ndis and 11b since May 1

From: Sam Leffler <sam_at_freebsd.org>
Date: Thu, 08 May 2008 13:27:08 -0700
Ted Lindgreen wrote:
> [Quoting Coleman Kane, on May  8, 16:49, in "Re: Problem ndis and ..."]
> ...
>   
>> I've been talking to Andrew Thompson about a similar problem recently.
>> I'm not sure if it is related, but it did keep me from being able to
>> associate to anything.
>>     
>
> I don't think it is related. I think you problem relates to order of the
> various configurations.
>   

Actually I disagree; I suspect there is an issue in ndis as it is 
presently the only "user of net80211" left that fondles the internal 
data structures.  In the past (haven't looked recently) ndis has also 
tried to simulate internal work of net80211 to provide a match between 
the ndis driver and net80211--usually with problems like what's been 
described.

> Yes, I have been following Sam's work and it is not trivial to set
> things up. Especially when you want to connect to various
> access-points with different interface (f.i. a USB with large antenne
> on my ship and the internal one else) depending on where you are.
>
> I have tried the /etc/rc.conf advice, but that didn't work for me, so
> I reverted to the trick of /etc/start_if_ndis0 and /etc/start_if_zyd0
> scripts which in turn call a /etc/start_if_wireless script.
>   

FWIW I'm not happy w/ the rc.conf stuff.  I suggest you talk to Brooks 
about your difficulties (I have passed along suggestions).

> For your (and perhaps other interested people) information, my start file
> looks like (this is a shortened version, the real version loops through
> various other accesspoints):
> ---
>  #!/bin/sh
>  #set -x
>
>  #To be called by the start_if.<ifn> scripts with <ifn> as argument
>
>  INTFs=`ifconfig -l`
>  
>  # Do not attempt to start ndis0 when zyd0 is present
>  if ( echo $INTFs | grep --quiet 'zyd0' )
>  then
>      ifconfig ndis0 down
>      if [ "$1" = "ndis0" ]
>      then
>          echo $0 $*: "zyd0 found, exit 1 for ndis0"
>  	exit 1
>      fi
>      echo $0 $*: "zyd0 found, ifconfig ndis0 down"
>  fi
>  
>  if ( echo $INTFs | grep --quiet 'wlan0' )
>  then
>      : Has already been created
>  else # Create wlan interface
>      ifconfig wlan0 create wlandev $1
>      ifconfig wlan0 country NL
>  fi
>  
>  for SLEEP in 2 4 8
>  do
>      echo "Try: Omval Airport"
>      ifconfig wlan0 ssid "Omval Airport" nwkey 0x********** up
>      sleep $SLEEP
>      if ( ifconfig wlan0 | grep --quiet 'associated' )
>      then
>  	/etc/rc.d/dhclient start wlan0
>  	exit 0
>      fi
>  
>      echo "Try: WiFi buiten"
>      ifconfig wlan0 ssid "WiFi buiten" nwkey 0x********** up
>      sleep $SLEEP
>      if ( ifconfig wlan0 | grep --quiet 'associated' )
>      then
>  	/etc/rc.d/dhclient start wlan0
>  	exit 0
>      fi
>  
>  done
>  
>  # Else, do not try to bring up the wireless
>  
>  echo $0 $*: "no association, shutdown $1"
>  ifconfig $1 down
>  exit 1
> ---
>
> Perhaps someone likes this idea, perhaps someother hints us to
> something far more easier and/or clever than this.
>   

Handling multiple wireless devices is not well supported right now.  If 
you only ever have one device hooked up at a time then it should be easy 
to deal with.  If you have multiple then it can be handled with the 
recent routing additions to HEAD (and which can also help the 
wired/wireless issues).  But I make no claims that there are good 
auto-configuration services at the moment.

    Sam
Received on Thu May 08 2008 - 18:27:09 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:30 UTC