Commit Graph

88 Commits

Author SHA1 Message Date
Sam Leffler
8ca623d734 honor new IEEE80211_KEY_GROUP key flag
Reviewed by:	Tai-hwa Liang
2005-04-12 17:56:43 +00:00
Sam Leffler
31640eb774 use frame type returned by ieee80211_input to drive softled code
instead of monitoring the input packet count
2005-04-04 02:34:15 +00:00
Sam Leffler
fe234894e5 reclaim mbufs in failure cases
Submitted by:	Tai-hwa Liang
2005-03-31 16:39:18 +00:00
Sam Leffler
a8d7e0f6ab close unlikely race
Submitted by:	Michael Wong
2005-03-30 20:30:48 +00:00
Sam Leffler
a7073e8b96 correct comment 2005-03-30 20:29:02 +00:00
Sam Leffler
22233301a3 rev rate control api to pass the both the first+last tx descriptors
to the rate control module for tx complete processing; this enables
rate control algorithms to extract the packet length for xmits that
require multiple descriptors
2005-03-30 20:17:18 +00:00
Sam Leffler
c4c3cb462d o extend cts to cover packet burst when operating in 11g w/ protection
o check current channel parameters, not shadow state, for acm policy
  on data frames
2005-03-30 20:13:08 +00:00
Tai-hwa Liang
33d7d80c82 Fixing kernel build on amd64 machines.
Reviewed by:	sam (mentor)
2005-03-30 02:33:33 +00:00
Sam Leffler
03ed599a2a extend the timestamp from the rx descriptor to calculate the tsf to
use when checking for an ibss merge
2005-03-29 22:16:49 +00:00
Sam Leffler
019b966921 forgot to merge this bit from p4 2005-03-29 21:06:28 +00:00
Sam Leffler
99d258fdc5 replace m_defrag with something more suitable 2005-03-29 20:54:31 +00:00
Sam Leffler
0c97ab9691 reclaim mbuf chain when ieee80211_crypto_encap fails
Noticed by:	David Young
2005-03-08 17:01:03 +00:00
Sam Leffler
d3be6f5b0c Fixup radiotap handling of FCS and QoS frames per discussion with David Young:
o mark rx frames including FCS in the payload with the
  IEEE80211_RADIOTAP_F_FCS flag
o remove hack to copy 802.11 headers with padding out of line; instead mark
  the frames with IEEE80211_RADIOTAP_F_DATAPAD and require applications to
  do the work
o split precalculated radiotap flags into tx+rx now that they can be different

Note the full usefulness of these changes depends on updates to applications
that process radiotap data.
2005-01-24 20:31:24 +00:00
Sam Leffler
f818612b1b beacon handling fixups for adhoc mode:
o don't reclaim any previous beacon state in ath_beacon_alloc; do it
  explicitly in ath_newstate
o reference count the node held in the beacon frame state block
o process ibss merge more intelligently; let the state machine do the
  right thing instead of explicitly setting the new bssi id
o explicitly stop tx dma before doing beacon setup to handle the ibss
  merge case
2005-01-24 20:05:03 +00:00
Sam Leffler
f9e6219b15 switch to use bus_dmamap_load_mbuf_sg 2005-01-24 19:51:59 +00:00
Sam Leffler
4bacf7c1f3 o correct beacon interval calculation; the internal setting is in TU's not ms
o replace the private macro to convert MS->TU with the common one
2005-01-24 19:45:59 +00:00
Sam Leffler
aab26fb481 add missing statistic 2005-01-18 19:33:06 +00:00
Sam Leffler
4c24deac20 disable interrupts when transitioning to INIT state so we don't rx frames 2005-01-18 19:31:31 +00:00
Sam Leffler
f6b8ec160d replace hand-rolled code to compact an mbuf chain with m_defrag; this is
suboptimal but needed for fast frames which won't fit in a single cluster
2005-01-18 19:28:49 +00:00
Sam Leffler
80d2765fe2 setup the beacon xmit queue to not interrupt; we don't use them and
they make the led's flash unnecessarily in adhoc mode
2005-01-18 19:10:17 +00:00
Sam Leffler
3e50ec2c95 better led blinking 2005-01-18 19:03:04 +00:00
Sam Leffler
0a1b94c44c add paren's so we can supply a|b as a debug mask 2005-01-18 18:11:04 +00:00
Sam Leffler
1f1d781074 bump copyright for 2005 2004-12-31 22:42:38 +00:00
Sam Leffler
a614e0762d correct some typos
Submitted by:	Tai-hwa Liang
2004-12-31 20:35:05 +00:00
Sam Leffler
16b4851a16 Radiotap fixups:
o catch one place where we were not using ath_chan_change to
  switch channels; this fixes a problem where the channel
  settings were not being correctly reported in captured packets
o return unique channel identification in the channel flags;
  ethereal gets confused if you return merged flags (e.g. ofdm,
  cck, and 2Ghz) (this is workaround and should be removed if
  we can ever cleanup radiotap consumers)
o correct short/long preamble flag state for rx and treat tx
  the same--use a new hwflags array that gives us the data
  based on the h/w rate index/cookie
o add gross hack to handle radiotap capture of frames that
  come in with hardware padding; should be replaced by a
  flag in the radiotap header and more smarts in the apps
  that decode radiotap data
2004-12-31 20:32:40 +00:00
Sam Leffler
0ab4040a27 for parts that require split keycache entries report the
the index of the first entry on a mic error so we're
consistent with parts that don't have split keycache
2004-12-31 20:21:31 +00:00
Sam Leffler
a6c992f43c Correct beacon timer setup logic:
o lintval is in ms; must convert to TU's for passing to the hal
o roundup to calculate nexttbtt (should look at current tsf and pull the
  calculated nextbtt forward but this'll do for now)
o don't or- in HAL_BEACON_RESET_TSF when doing station timer setup; this
  is not needed and messes up the sleep timer calcs, though it's unclear
  if it mattered as the hal masks these values before use

Submitted by:	Thorsten von Eicken
2004-12-31 20:20:02 +00:00
Sam Leffler
0eb68df4c5 no need to sweep the tx q's for node references in ath_node_free; we know
there are none since we're only called when the ref count goes to zero
2004-12-31 20:13:58 +00:00
Sam Leffler
d77367bf5a cleanup some assertions 2004-12-31 20:11:23 +00:00
Peter Wemm
6891c875c2 Make this amd64-clean. sizeof is long on amd64, so things that do a printf
of a sizeof, need to use %z to get the correct type on all our platforms.
Also, convert integers<->pointers via uintptr_t.

(I think Sam's instructions were for me to commit this.  If I
 misunderstood, then I apologize in advance.)
2004-12-15 02:25:21 +00:00
Sam Leffler
c42a7b7e25 Update with last year of work. 2004-12-08 17:34:36 +00:00
Sam Leffler
e383b24041 Add missing bit of last if_start workaround: mark scan callout
MPSAFE only debug_mpsafenet is 1 so callbacks to send management
frames hold Giant; this is another bandaid on the path to removing Giant.
2004-08-08 17:10:54 +00:00
Sam Leffler
b5f4adb32e Pickup Giant in ath_rx_proc and when handling a beacon miss in order to
satisfy the assertion in if_start.
2004-08-07 00:45:05 +00:00
Max Laier
154b8df2ed Second part of ALTQ driver modifications, covering:
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)
2004-08-01 23:58:04 +00:00
Sam Leffler
710da3ec44 use correct malloc type to allocate struct ieee80211_node's
Noticed by:	phk
2004-04-05 04:42:42 +00:00
Sam Leffler
1e77407972 do proper subclassing of node free+copy; the previous hack falls apart when
the 802.11 layer does useful work

Obtained from:	madwifi
2004-04-03 00:06:23 +00:00
Sam Leffler
babe2453bd transmit beacon frames directly instead of defering them to a swi; there
was too much delay

Obtained from:	madwifi
2004-04-03 00:02:17 +00:00
Sam Leffler
cb344d958a update copyright notice for 2004 2004-04-02 23:57:10 +00:00
Sam Leffler
fdd758d4d1 check more quickly (and directly) if an interrupt is pending; this reduces
work done in ath_intr when the irq is shared

Obtained from:	madwifi
2004-04-02 23:49:15 +00:00
Sam Leffler
b28b465391 cleanup descriptor allocation if attach fails
Obtained from:	madwifi
2004-04-02 23:47:39 +00:00
Sam Leffler
01e7e035e0 remove use IEEE80211_C_RCVMGT 2004-04-02 23:37:00 +00:00
Sam Leffler
2f1ad18b34 radiotap updates:
o force little-endian byte order for header
o pad header to 32-bit boundary to guard against applications that assume
  packet data alignment
2004-04-01 00:38:45 +00:00
Matthew N. Dodd
f7f2bd753e Don't announce MAC addresses twice.
(ieee80211_ifattach() calls ether_ifattach().)
2004-03-20 19:57:47 +00:00
Peter Wemm
3031063498 Make this compile on amd64.
"I'll cope" by:  sam
2004-02-06 00:10:54 +00:00
Sam Leffler
23428eafa0 When draining the tx queue reclaim any node references held in packets.
This fixes a problem when operating as an AP where clients would get
stuck in the node table because the reference count never went to zero.
2004-01-07 19:16:49 +00:00
Sam Leffler
a9c0425768 When ath_hal_stoptxdma returns an error dma is still likely stopped
so don't just stop trying to send a beacon frame or we'll be more likely
to lose sync.  This only seems to happen on some older chips.
2004-01-07 19:11:11 +00:00
Sam Leffler
7bbf937701 use ath_reset instead of ath_init when recovering from a watchdog timeout:
resetting the hardware is sufficient, no need to reset the 802.11 fsm
2004-01-07 19:07:41 +00:00
Sam Leffler
f3be79561f make hw.ath.debug a tunable 2004-01-07 19:05:35 +00:00
Sam Leffler
8c0370b75d make hw.ath.outdoor and hw.ath.countrycode tunables 2004-01-07 19:04:42 +00:00
Sam Leffler
e325e53069 split debugging messages up into classes;
ah_debug is now treated as a bit vector
2004-01-07 18:57:38 +00:00