Commit Graph

70 Commits

Author SHA1 Message Date
christos a66f866e5e Coverity CID 726: Remove bogus test. ni was checked for not NULL lines above,
and the if condition tries to free ni!
2006-04-14 20:33:57 +00:00
christos 95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
dyoung 9063402978 Resolve conflicts in importation of 18-May-2005 ath(4) / net80211(9)
from FreeBSD.  Introduce compatibility shims (sys/dev/ic/ath_netbsd.[ch],
sys/net80211/ieee80211_netbsd.[ch]).  Update drivers (an, atu, atw,
awi, ipw, iwi, rtw, wi) for the new net80211(9) API.
2005-06-22 06:14:51 +00:00
perry f31bd063e9 nuke trailing whitespace 2005-02-27 00:26:58 +00:00
thorpej e9818f5b5e When adding/deleting multicast addresses, only whack the address
filter if the interface is marked RUNNING.

Fixes kern/27678.
2004-10-30 18:08:34 +00:00
dyoung 8abb07d1ac Make the node table into an LRU cache: least-recently used nodes
are at the end of the node queue.  Change the reference-counting
discipline: ni->ni_refcnt indicates how many times net80211 has
granted ni to the driver.  Every node in the table with ni_refcnt=0
is eligible to be garbage-collected.  The mere presence of a node
in the table does not any longer indicate its auth/assoc state;
nodes have a ni_state variable, now.  A sysctl,
net.link.ieee80211.maxnodecache, controls the maximum LRU cache
size.

While I am here, patch ieee80211_find_node_for_beacon to do a "best
match" by bssid/ssid/channel, not a "perfect match."  This keeps
net80211 from caching duplicate nodes in the table.
2004-08-10 00:57:20 +00:00
mycroft f526e7326b Cleanup of ieee80211_node from madwifi:
* Don't use ifp pointers; use ieee80211com.
* Implement the locking macros that are used under FreeBSD and Linux.
2004-07-23 10:15:13 +00:00
mycroft 50d44f4f07 IEEE80211_F_WEPON -> IEEE80211_F_PRIVACY 2004-07-23 08:31:39 +00:00
onoe a42258dab0 Do not return EINPROGRESS but 0 in awi_newstate, since the EINPROGRESS
handling was changed in net80211 framework.
This fix wiconfig -D awi0 to work again for DS phys.
XXX FH phys takes 20 seconds to complete scan, so wiconfig timed out.
2004-01-16 14:13:15 +00:00
onoe d21d916e1d Correct beacon (src/bssid) for hostap and adhoc mode. 2004-01-15 13:29:05 +00:00
onoe 5ff2748cd5 Fix: panic when rate is specified but chan is left unspecified.
Add FreeBSD glues to share drivers.
2004-01-15 09:39:15 +00:00
keihan b8702f530b netbsd.org -> NetBSD.org
This was the last commit of this kind to src/sys, which is now totally
"NetBSD.org clean".  Thanks for the patiance, and sorry for all the commits.
2003-12-04 13:57:30 +00:00
wiz c5670263e0 Fix some typos. From Tom Cosgrove via jmc@openbsd. 2003-11-02 11:07:44 +00:00
dyoung 76db6bfa8c Use ieee80211_find_rxnode to attribute Rx packets to the write
ieee80211_node. This reduces code duplication.  It will help us
support passive scanning and rate adaptation.
2003-11-02 01:55:40 +00:00
simonb b6abb6ab1d Remove some assigned-to but otherwise unused variables. 2003-10-30 01:58:17 +00:00
simonb 662c7128cd Re-order a little so that there's no unreachable code in this block. 2003-10-15 07:18:17 +00:00
dyoung e31cc884ed Adapt awi(4) to the new 802.11 layer. 2003-10-13 08:10:48 +00:00
dyoung 6e3daf0a07 Still more consolidation of 802.11 media-handling, moving moving
common code from awi and wi into the 802.11 framework. Inspired by
Sam Leffler's patches to FreeBSD.
2003-07-06 20:01:17 +00:00
dyoung 595c6d88b2 Add support for Prism monitor mode. From Kevin Lahey
<kml@patheticgeek.net>.

This patch does NOT add monitor mode support for the Lucent radios.

awi(4) was only modified for compatibility with the new mediaopt.
It does NOT support monitor mode.

Tested by Kevin, Daniel Carosone, and I.
2003-02-25 01:57:35 +00:00
thorpej af919042ec Merge the nathanw_sa branch. 2003-01-18 10:14:20 +00:00
onoe 8c17118b22 Allow SIOCSIFADDR with AF_LINK and WI_RID_MAC_NODE (wiconfig -m)
to set MAC address.
2002-10-01 03:27:02 +00:00
onoe 9fadcea372 old lucent adhoc-demo mode (adhoc,flag0 or wiconfig -p 3) wasn't handled
correctly.  To avoid massive extra code in each driver, now if_iee80211subr.c
also handles non-standard old lucent adhoc-demo mode.
This also fixes PR 14227.
2002-09-30 15:48:41 +00:00
onoe 45667e55b9 re-enable IBSS creation. 2002-09-30 06:38:10 +00:00
onoe 30d884d47c Add support for SIOC[SG]80211BSSID, SIOC[SG]80211CHANNEL.
Change the name of structure ieee80211_bss to ieee80211_node, which is
used for management of stations in hostap mode, and peers in ibss mode.
Split off ic_opmode, ic_phytype from ic_flags.
Preparation to merge 'wi' driver into 80211subr.c.
2002-09-27 05:36:04 +00:00
onoe 26ebf5f371 Several fixes hostap for awi driver:
- aging ang clear inactivity stations
- DTIM field in beacon/probe response.
- ignore IFF_PROMISC for hostap mode, since 802.11 has 3 address fields,
  so that promisc mode is not required for AP function.
2002-09-03 14:54:00 +00:00
onoe efcfc3e1c8 Add experimental support of Host-AP mode for awi driver.
It works also with WEP enabled.
But aging the associated clients is not implemented yet, so that the number
of clients may increase unlimitedly..
2002-09-02 13:37:35 +00:00
onoe fd9daca7ea Attach another DLTs for bpf: DLT_IEEE802_11 to capture raw 802.11 frame. 2002-08-28 09:38:08 +00:00
onoe 248c861292 Fix IBSS for awi driver. 2002-08-05 06:55:05 +00:00
onoe fdcde8230d Set desired ESSID for probe request. 2002-07-25 07:15:50 +00:00
lukem a4bae8b066 add/cleanup RCSID 2001-11-13 13:14:31 +00:00
onoe b698d56d3c Move IBSS creation stuff from awi to ieee80211. 2001-09-20 13:54:43 +00:00
onoe aebd449baa Fix for FH infrastructure mode.
XXX: FH chanset should be calculated by FH hop pattern, but BayStack 650 AP
     always specify chanset to fixed value 1.  The previous code try to this
     hack into awi driver, but it is insufficient because the chanset value
     in awi driver may change while scan and it may be different from the
     value in receiving beacon/probe-response.  So we save encoded FH chanset
     into channel in 802.11 common bss information for now.
2001-09-19 04:09:54 +00:00
onoe 8496cf2bd8 Fix register offset of SYNC_SET for FH phy. 2001-09-18 23:19:08 +00:00
onoe 6a617566bc Move IEEE 802.11 MAC management functions from awi driver to
if_ieee80211subr.c, which can be shared between any IEEE 802.11
drivers.
However, most of current working IEEE 802.11b wireless LAN cards
have rich firmware and we cannot have a control to management frames
for such cards.

IBSS creation is now supported for the awi driver.
2001-09-18 09:09:57 +00:00
wiz e11d04474c issueing -> issuing 2001-07-26 22:55:12 +00:00
onoe e7e0a9984c Do not re-enable the driver after resume if the interface is marked down.
Change the first argument of awi_init/awi_stop from struct awi_softc to
struct ifnet to match the definition if_init/if_stop, though we don't
use ether_ioctl() yet.
2001-06-28 10:40:04 +00:00
onoe 65f0069f5b restore awi_power() to reenable awi after resume.
... forgot why it is disabled...
2001-06-26 08:41:19 +00:00
onoe 4fe2f5eda7 AWI_DEBUG only:
awi_dump_pkt dumps packet before encryption in transmit.
2001-06-25 12:09:51 +00:00
onoe b383383c20 Fix capability information in association request to reflect ESS/IBSS mode.
This fix is required to interoperate with Cisco's access point.
2001-06-25 12:06:14 +00:00
onoe 1761d48452 cleanup unnecessary include files. 2001-06-25 04:29:19 +00:00
thorpej 4dbafc4a71 Remove an IF_PREPEND() that slipped through. 2000-12-18 23:57:13 +00:00
thorpej 6b16911a43 ALTQ'ify. 2000-12-14 06:27:23 +00:00
takemura 3c9d9276dc Add new powerhook argument values, PWR_SOFTSUSPEND, PWR_SOFTSTANDBY and
PWR_SOFTRESUME. Apm calls powerhook with the values in normal interrupt
priority level while others are protected with splhigh().
2000-11-26 11:08:57 +00:00
thorpej b84f740be0 Move bpfattach()/bpfdetach() calls into ether_ifattach()/ether_ifdetach(). 2000-11-15 01:02:11 +00:00
onoe afa5b645c2 add support for SIOCS80211NWKEY and SIOCG80211NWKEY. 2000-07-21 04:48:55 +00:00
onoe 0ab524f389 moved the check priviledge for SIOCS80211NWID from each driver to ifioctl().
it also fixes the problem that non-priviledged user can change nwid
for wi and ray drivers.
2000-07-19 06:00:39 +00:00
onoe 6c4d97da13 Indicate WEP capability to association request when WEP is enabled.
Without this fix, some (IEEE802.11 conformant) APs will send data to this
station without using WEP.
2000-07-11 12:54:00 +00:00
onoe b99e56173c do not allow non-priviledged user to change nwid via ifconfig. 2000-07-10 14:36:17 +00:00
onoe c2ed037f55 move associated/synced/no-recent-beacons messages to IFF_DEBUG. 2000-07-10 12:32:53 +00:00
onoe 807a12c8cd change the argument of SIOCS80211NWID and SIOCG80211NWID ioctls from
u_int8_t array to struct ieee80211_nwid to prepend length field.
The length field is necessary because IEEE 802.11 spec doesn't prohibit
even '\0' for SSID.
Though the name and the value of SIOC... macro is unchanged, this change
breaks binary compatibility.  The only affected userland program on the
tree is ifconfig(8).
As Jason suggested on tech-net, it is better than live with problems
since there are no releases for this ioctls yet.
2000-07-05 02:35:53 +00:00