Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 7 Dec 2009 09:33:13 -0500
From:      David Horn <dhorn2000@gmail.com>
To:        =?UTF-8?B?QW5oIEsuIEh14buzbmg=?= <xkyanh@gmail.com>
Cc:        FreeBSD Questions <questions@freebsd.org>
Subject:   Re: ndis driver: invalid argument (freebsd 8.0)
Message-ID:  <25ff90d60912070633v62acccc1g98efdcf0e81b41fc@mail.gmail.com>
In-Reply-To: <20091207122831.15496356@icy.localdomain>
References:  <20091207091740.03a5180d@icy.localdomain> <4ad871310912061905j3ef2d882x103c084be2c0629a@mail.gmail.com> <20091207122831.15496356@icy.localdomain>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
On Mon, Dec 7, 2009 at 12:28 AM, Anh K. Hu=E1=BB=B3nh <xkyanh@gmail.com> wr=
ote:
>
> Hi,
>
> On Sun, 6 Dec 2009 22:05:33 -0500
> Glen Barber <glen.j.barber@gmail.com> wrote:
>
> > Hi
> >
> > On Sun, Dec 6, 20309 at 9:17 PM, Anh K. Hu=E1=BB=B3nh <xkyanh@gmail.com=
>
> > wrote:
> > > Hi all,
> > >
> > > I compiled `bcmwl5` module by `ndisgen` then loaded that module
> > > successfully, but I get the `invalid argument` error:
> > >
> > > $ ifconfig ndis0 ssid TOM-and-JERRY
> > > ifconfig: SIOCS80211: Invalid argument
> > >
> > > What's wrong to my ndis driver? I read /usr/src/UPDATING and
> > > wireless section in the Handbook but found nothing special. So I
> > > post here for your helps.
> > >
> >
> > 1.) Are your kernel and userland in sync?
> >
> > 2.) What is the output of 'uname -a'? =C2=A0If 8.X, read the 20080420
> > entry in src/UPDATING.
> >
>
> I am using 8.0-RELEASE (upgraded from 7.2-RELEASE). I've read the 2008042=
0 entry and configured my card successfully. (I read that section before as=
king in list but I confused.)
>

If you have your /usr/src/ and kernel in sync (when you generated your
ndis module), then try something like:

ifconfig wlan0 create wlandev ndis0
ifconfig wlan0 ssid TOM-and-JERRY

via rc.conf:

wlans_ndis0=3D"wlan0"
ifconfig_wlan0=3D"ssid TOM-and-JERRY"

>From wlan(4) man page:

Drivers provide 802.11 functionality through wlan interfaces that are
     created at runtime using interface cloning.  This is done with the
     ifconfig(8) create command or using the wlans_IFX variable in rc.conf(=
5).
     Some drivers support the creation of multiple wlan interfaces that sha=
re
     the same underlying device; this is the way by which ``multi-bss sup-
     port'' is provided but it can also be used to create WDS links and oth=
er
     interesting applications.

If you use WPA wireless security and DHCP on your wireless network,
you should also look at wpa_supplicant(8) and wpa_supplicant.conf(5)
and use something like:

wlans_ndis0=3D"wlan0"
ifconfig_wlan0=3D"WPA DHCP"

and setup your /etc/wpa_supplicant.conf file as required with
something like (entries vary based upon exact setup of your wireless
network.  See wpa_supplicant.conf man page):

     ctrl_interface=3D/var/run/wpa_supplicant
     ctrl_interface_group=3Dwheel
     network=3D{
	     ssid=3D"TOM-and-JERRY"
	     key_mgmt=3DWPA-PSK
	     psk=3D"very secret passphrase"
     }


and of course make sure that the generated ndis module is loaded (via
kldload or via /boot/loader.conf) before attempting to clone the
interface with "ifconfig wlan0 create wlandev ndis0"  See kldstat(8)
man page and utility if you are unsure if your generated ndis kernel
module is loaded.

Good Luck.

--Dave Horn



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?25ff90d60912070633v62acccc1g98efdcf0e81b41fc>