aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/wi
Commit message (Collapse)AuthorAgeFilesLines
...
* Cleanup beacon/listen interval handling:Sam Leffler2005-08-081-1/+1
| | | | | | | | | | | | | | | | | | | | o separate configured beacon interval from listen interval; this avoids potential use of one value for the other (e.g. setting powersavesleep to 0 clobbers the beacon interval used in hostap or ibss mode) o bounds check the beacon interval received in probe response and beacon frames and drop frames with bogus settings; not clear if we should instead clamp the value as any alteration would result in mismatched sta+ap configuration and probably be more confusing (don't want to log to the console but perhaps ok with rate limiting) o while here up max beacon interval to reflect WiFi standard Noticed by: Martin <nakal@nurfuerspam.de> MFC after: 1 week Notes: svn path=/head/; revision=148843
* When the MAC address is reported all zeros, then error is necessarilyWarner Losh2005-08-051-1/+3
| | | | | | | | | | | 0. This means that we 'succeed' the attach, even after we've freed the internal data bits. This leads to a panic when you eject the card with this problem. Set error = ENXIO in the mac read zeros case. Notes: svn path=/head/; revision=148714
* Modify device drivers supporting multicast addresses to lock if_addr_mtxRobert Watson2005-08-031-0/+2
| | | | | | | | | | | over iteration of their multicast address lists when synchronizing the hardware address filter with the network stack-maintained list. Problem reported by: Ed Maste (emaste at phaedrus dot sandvine dot ca> MFC after: 1 week Notes: svn path=/head/; revision=148654
* diff reduction against p4: define IEEE80211_FIXED_RATE_NONE and useSam Leffler2005-07-221-2/+2
| | | | | | | it instead of -1 Notes: svn path=/head/; revision=148290
* Add a boatload of new device ids, gleaned from the pcmcia-cs-3.2.8Warner Losh2005-07-101-0/+1
| | | | | | | | | | distribution. Add the appropriate devices to the man pages. Obtained from: pcmcia-cs Approved by: re (scottl) Notes: svn path=/head/; revision=147872
* Eliminate unused argument in PCMCIA_CARD macro.Warner Losh2005-06-241-49/+51
| | | | | | | | | | | Provide a backwards compatible way to have the extra macro by defining PCCARD_API_LEVEL 5 before including pccarddevs for driver writers that want/need to have the same driver on 5 and 6 with pccard attachments. Approved by: re (dwhite) Notes: svn path=/head/; revision=147580
* Stop embedding struct ifnet at the top of driver softcs. Instead theBrooks Davis2005-06-102-18/+25
| | | | | | | | | | | | | | | | | | | | | | | struct ifnet or the layer 2 common structure it was embedded in have been replaced with a struct ifnet pointer to be filled by a call to the new function, if_alloc(). The layer 2 common structure is also allocated via if_alloc() based on the interface type. It is hung off the new struct ifnet member, if_l2com. This change removes the size of these structures from the kernel ABI and will allow us to better manage them as interfaces come and go. Other changes of note: - Struct arpcom is no longer referenced in normal interface code. Instead the Ethernet address is accessed via the IFP2ENADDR() macro. To enforce this ac_enaddr has been renamed to _ac_enaddr. - The second argument to ether_ifattach is now always the mac address from driver private storage rather than sometimes being ac_enaddr. Reviewed by: sobomax, sam Notes: svn path=/head/; revision=147256
* Honouring current authmode setting. With this patch, my wi card can nowTai-hwa Liang2005-06-021-1/+3
| | | | | | | | | | associate to an AP which uses shared WEP key authentication. Tested with: "ifconfig wi0 authmode shared" Reviewed by: imp, sam Notes: svn path=/head/; revision=146884
* Invert conditional and use continue to reduce nesting.Matthew N. Dodd2005-04-131-5/+5
| | | | Notes: svn path=/head/; revision=144986
* Unbreak style(9) breakage from last commit. We try to avoid definingWarner Losh2005-03-271-4/+2
| | | | | | | | | variables in internal blocks. Also, go ahead and fail if we can't load the firmware. It should have failed like this, but never did (firmware loads generally don't fail). Notes: svn path=/head/; revision=144185
* Unbreak LINT.Pawel Jakub Dawidek2005-03-271-0/+3
| | | | Notes: svn path=/head/; revision=144182
* purge dead codeSam Leffler2005-03-261-3/+0
| | | | | | | Noticed by: Coverity Prevent analysis tool Notes: svn path=/head/; revision=144168
* correct logic so we recognize timeout on allocSam Leffler2005-03-261-4/+4
| | | | | | | Noticed by: Coverity Prevent analysis tool Notes: svn path=/head/; revision=144167
* reclaim mbuf chain when ieee80211_crypto_encap failsSam Leffler2005-03-081-0/+1
| | | | | | | Noticed by: David Young Notes: svn path=/head/; revision=143299
* Use BUS_PROBE_DEFAULT in preference to 0. Also for vx, returnWarner Losh2005-03-011-1/+1
| | | | | | | | BUS_PROBE_LOW_PRIORITY in stead of ifdef for devices that xl and vx both support so that xl will snarf them on up. Notes: svn path=/head/; revision=142880
* The two PLANEX cards listed in pccarddevs, identified only by theirWarner Losh2005-02-011-1/+1
| | | | | | | | | | | | | | | | | | | | | CIS, weren't actually used anywhere (other than the generic PC Card code when certain variables are defined). They aren't used in NetBSD either. Make things simpler by removing them. Change PLANEX_2 to PLANEX and tweak wi and owi to use that instead. The PLANEX id seems to actually be pci ID assigned to planex, not its pcmcia id. Ooops. I don't know if this is a reporting error from where this entry came from, or if it is a mistake on PLANEX's part. I suspect the latter, as ACTIONTEC and NEWMEDIA made the same mistake (although new media may be because it uses an advansys chip inside). Make a note of this in the file. The 0xc entires may be JEITA assigned, so note that as well. # This leaves just 3 entries that are totally unknown: airvast, archos # and edimax although the arivast number is the same assigned to # avertec in usb... Notes: svn path=/head/; revision=141122
* Use Intersil chip names for the symbols, since many makers use theWarner Losh2005-01-201-3/+3
| | | | | | | intersil IDs but their own name in the CIS. Notes: svn path=/head/; revision=140520
* Add support for SENAO SL-2511CDWarner Losh2005-01-201-1/+2
| | | | | | | Info submitted by: Paulo Fragoso Notes: svn path=/head/; revision=140516
* Call wi_free after we turn off the interrupts. If we call it before,Warner Losh2005-01-191-2/+2
| | | | | | | | | then we reference parts of the softc. # My appologies, but this was sent to me by someone whose name I've lost. Notes: svn path=/head/; revision=140463
* Start each of the license/copyright comments with /*-, minor shuffle of linesWarner Losh2005-01-067-7/+7
| | | | Notes: svn path=/head/; revision=139749
* Eliminate some of the egregious bypass of the 802.11 stateSam Leffler2005-01-011-18/+20
| | | | | | | | | machine; instead use the intended entry points. There's still too much incestuous knowledge about the internals of the 802.11 layer but this at least fixes adhoc mode. Notes: svn path=/head/; revision=139542
* Diff reduce wi_write_wep() relative to revision 1.168Matthew N. Dodd2004-12-171-41/+38
| | | | Notes: svn path=/head/; revision=138988
* Fix wep operation for station mode:Sam Leffler2004-12-171-4/+28
| | | | | | | | | | | | | o don't encapsulate on tx; the chip expect a raw frame w/o the crypto header o clear the WEP bit in the 802.11 header on rx so the 802.11 layer doesn't try to strip the crypto header o clobber the "drop unencoded frames" state bit when privacy is enabled so rx'd frames we pass up to the 802.11 layer are not discarded as unencrypted This stuff will need to be redone if anyone decides to add WPA support. Notes: svn path=/head/; revision=138952
* set ic_ibss_chan when entering RUN state to match ic_bss so the channelSam Leffler2004-12-171-0/+1
| | | | | | | reported when associated to an AP is correct Notes: svn path=/head/; revision=138951
* remove power save logic from the tx path; the driver isn't ready to supportSam Leffler2004-12-171-6/+0
| | | | | | | it so don't mislead folks Notes: svn path=/head/; revision=138949
* o Update for net80211 changesSam Leffler2004-12-083-205/+238
| | | | | | | o Import some minor fixes from netbsd Notes: svn path=/head/; revision=138571
* Second part of ALTQ driver modifications, covering:Max Laier2004-08-011-10/+6
| | | | | | | | | | | | | an(4), ath(4), hme(4), ndis(4), vr(4) and wi(4) Please help testing: http://people.freebsd.org/~mlaier/ALTQ_driver/ Tested by: Vaidas Damosevicius (an, ath, wi) Roman Divacky (vr) Submitted by: yongari (hme) Notes: svn path=/head/; revision=132986
* Link ALTQ to the build and break with ABI for struct ifnet. Please recompileMax Laier2004-06-131-0/+2
| | | | | | | | | | | | | | | your (network) modules as well as any userland that might make sense of sizeof(struct ifnet). This does not change the queueing yet. These changes will follow in a seperate commit. Same with the driver changes, which need case by case evaluation. __FreeBSD_version bump will follow. Tested-by: (i386)LINT Notes: svn path=/head/; revision=130416
* Only match cards that claim to be network cards. I've had twoWarner Losh2004-06-091-0/+10
| | | | | | | | | | | | different cards that matched vendor/id, but weren't wi cards. This is because the vendor foolishly didn't have unique product ids. Symbol has a serial card that would otherwise match the wi driver, for example... Taken from a patch for xe posted by: Carlos Velasco Notes: svn path=/head/; revision=130257
* Fix disordering of pccarddevs.h noticed by bde. Also remove a fewWarner Losh2004-05-271-21/+1
| | | | | | | | | redundant includes and fix some of the include disordering. Submitted by: bde Notes: svn path=/head/; revision=129764
* Move to generating pccarddevs.h on the fly, both for the kernel andWarner Losh2004-05-261-1/+1
| | | | | | | | | | the modules. Also generate usbdevs.h automatically now, but a non-kernel file is stopping that at the moment. Notes: svn path=/head/; revision=129740
* It turns out that the module dependency on pccard is in error. SinceWarner Losh2004-05-081-1/+0
| | | | | | | | | | | | | | | there's not dependencies on pccard symboles, such a dependency is not necessary. This means that drivers that have multiple attachments can not drag bogus devices into the kernel at load time. We can't (yet) do this with pci and isa. Drivers written for them actually do seem to have symbols that depend on these busses' implementation code. ndis not touched until other things can be tested. Notes: svn path=/head/; revision=129046
* radiotap updates:Sam Leffler2004-04-012-6/+13
| | | | | | | | | o force little-endian byte order for header o pad header to 32-bit boundary to guard against applications that assume packet data alignment Notes: svn path=/head/; revision=127698
* correct xmit-side radiotap collection by tap'ing the frame beforeSam Leffler2004-04-011-4/+4
| | | | | | | prepending the h/w header Notes: svn path=/head/; revision=127697
* Add support for a new variant of the prism3 that has appaered in theWarner Losh2004-03-251-0/+1
| | | | | | | | | | wild. This one is marketed by D-Link model DWL-650, but appears to be a ISL3710P-10 under the hood. Reported by: Brian O'Shea Notes: svn path=/head/; revision=127424
* Don't announce MAC addresses twice.Matthew N. Dodd2004-03-201-1/+0
| | | | | | | (ieee80211_ifattach() calls ether_ifattach().) Notes: svn path=/head/; revision=127237
* Eliminate bogus usage of WI_RSSI_TO_DBM(). Not only does it boguslyBrian Feldman2004-03-171-4/+2
| | | | | | | | | clip/destroy the dB value contained in the wi(4)'s receive frames, it doesn't match with the flag set in the radiotap header (unperturbed dB versus dBm). Notes: svn path=/head/; revision=127148
* Convert callers to the new bus_alloc_resource_any(9) API.Nate Lawson2004-03-172-8/+8
| | | | | | | | Submitted by: Mark Santcroos <marks@ripe.net> Reviewed by: imp, dfr, bde Notes: svn path=/head/; revision=127135
* update radiotap support to reflect recent changes:Sam Leffler2003-12-282-13/+14
| | | | | | | | | o add xmit rate o drop rx time o add rx flags Notes: svn path=/head/; revision=123927
* o eliminate widespread on-stack mbuf use for bpf by introducingSam Leffler2003-12-281-34/+12
| | | | | | | | | | | | | | | | a new bpf_mtap2 routine that does the right thing for an mbuf and a variable-length chunk of data that should be prepended. o while we're sweeping the drivers, use u_int32_t uniformly when when prepending the address family (several places were assuming sizeof(int) was 4) o return M_ASSERTVALID to BPF_MTAP* now that all stack-allocated mbufs have been eliminated; this may better be moved to the bpf routines Reviewed by: arch@ and several others Notes: svn path=/head/; revision=123922
* Fix slight disordering of supported cards.Warner Losh2003-12-271-3/+3
| | | | Notes: svn path=/head/; revision=123908
* Older versions of the intersil firmware is a lot slower than newerWarner Losh2003-12-092-1/+8
| | | | | | | | | | | | versions of the firmware. It responds more slowly to commands, and we bogusly failed them. We assume that all versions of the intersil firmware before 1.0 are 10 times slower and will give it 10x the time to finish. # for 5.2 we should always just assume 5s. Notes: svn path=/head/; revision=123339
* Fix Lucent cards.Warner Losh2003-12-021-10/+25
| | | | | | | | | | | | | | | | | | | | | | | | o Back out workaround for not resetting lucent cards more than once. With these fixes, it appaers they are no longer necessary. o Set wi_gone when the card goes awol: typically when we get 0xffff back from the card. Also, don't interact with a card that's gone, so we fail in seconds rather than minutes. Also reduce amount of time we wait to .5s in wi_cmd. o clear wi_gone on ifconfig down to give some cards a chance after they wedge (this appears to unwedge one of my prism cards with old firmware). ifconfig up will fail quickly enough if the card really is out to lunch. o Add delay in wi_init of 100ms. o wi_stop(ifp, 0->1) changes so that we clear sc_enabled so that we exit out of the interrupt routine by just acking the interrupt Submitted by: iedowse Approved by: re@ (scottl) # after the freeze I'll fix some of the minor style issues that reviewers # of this patch have told me about. Notes: svn path=/head/; revision=123098
* Truly fix the lockup mentioned in 1.153. The PRISM hardware is notBrian Feldman2003-11-041-0/+9
| | | | | | | | capable of functioning in HostAP mode with a zero-length SSID, so use " " if one is not set. Notes: svn path=/head/; revision=122087
* Despite making the card not lock up, thae workaround from 1.153 didn'tBrian Feldman2003-11-041-3/+0
| | | | | | | | actually make hostap mode work again. Back it out while I try to find a solution. Notes: svn path=/head/; revision=122083
* Fix wi(4)'s WI_RID_SCAN_RES ioctl (wicontrol -L). The wrong lengthBrian Feldman2003-11-041-9/+13
| | | | | | | | is computed, so the user thinks that for non-PRISM cards there are more APs represented than exist. Notes: svn path=/head/; revision=122015
* On my ZoomAir-branded Intersil PRISM2 cards, if you try to set theBrian Feldman2003-11-041-0/+3
| | | | | | | | | | | | | | | | | operating mode to HostAP, the card will lock up indefinitely (but the wi(4) driver can recover if you eject the card). The problem is that the card needs to be "reset" in a way before you even change the media to hostap. In practice this isn't as noticeable because you probably do some operation beforehand which prevents the lock-up before you enable hostap mode. e.g.: "ifconfig wi0 up media autoselect mediaopt hostap" will lock up (if you just inserted the card). "ifconfig wi0 up ssid foo media autoselect mediaopt hostap" won't lock up. Notes: svn path=/head/; revision=122014
* Replace the if_name and if_unit members of struct ifnet with new membersBrooks Davis2003-10-311-2/+1
| | | | | | | | | | | | | | | | if_xname, if_dname, and if_dunit. if_xname is the name of the interface and if_dname/unit are the driver name and instance. This change paves the way for interface renaming and enhanced pseudo device creation and configuration symantics. Approved By: re (in principle) Reviewed By: njl, imp Tested On: i386, amd64, sparc64 Obtained From: NetBSD (if_xname) Notes: svn path=/head/; revision=121816
* mark interrupt handlers MPSAFESam Leffler2003-10-291-1/+1
| | | | Notes: svn path=/head/; revision=121697
* Sony PEGA-WL110 Wireless LANWarner Losh2003-09-221-0/+1
| | | | | | | Obtained from: NetBSD (onoe-san) Notes: svn path=/head/; revision=120332