History log of /drivers/net/wireless/ath/ath9k/htc_drv_beacon.c
Revision Date Author Comments
5f667642f4b290b04d88d5ca926fba81fed6180d 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: move DEFAULT_SWBA_RESPONSE check to ath9k_htc_beacon_init

... to remove some more dups.

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
4b2d841f5bc3143f5a019b6a441c19bf2986bdf4 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: use ath9k_cmn_beacon_config_ap

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
12f53c308ecbe2b76798a5091f8452eeed0a732b 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: use ath9k_cmn_beacon_config_adhoc

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
f7197924d5187201e1a6e1617ad7a8c81f333330 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: use ath9k_htc_beacon_init in ath9k_htc_beacon_config_adhoc

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
4a4495a5fdf3f5d2e98446c94146dcaefb06a69b 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: use ath9k_htc_beacon_init in ath9k_htc_beacon_config_ap

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
7f5c4c8320f853e17ec1c6dbb78d3753ba76a6cd 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: add ath9k_htc_beacon_init (but not use it)

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
f84224402bddea8e2762869f4eaebc3b46be2aa0 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: use ath9k_cmn_beacon_config_sta

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
92c3f7ef2c59de5c6b58504d330a59f8e8d78e88 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: use common->op_flags

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
88a4f56ef09d6f38beee79e9abff7cb7f867dc52 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: use ath_beacon_conf.enable_beacon

to reduce difference between ath9k and ath9k_htc

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
a099874ed9db31e8ac0d8173394e54081d518635 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: move beaconq to struct htc_beacon

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
3c4816d9a324f06c481dcc36c8dc1168f5d785c5 01-Mar-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: use common ath_beacon_config

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
527492eefcee253e33bbe79bcfef6bedf9935492 26-Feb-2014 Oleksij Rempel <linux@rempel-privat.de> ath9k_htc: remove unused variable sleepduration

sleepduration is always = intval.

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
4ed15762dce67192d4662860470a8be1f6d5fd53 14-Dec-2013 Felix Fietkau <nbd@openwrt.org> ath9k_hw: clean up station beacon timer API

Remove unused fields, pass timer info in usec instead of TU.
Preparation for fixing nexttbtt calculation

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
594e65b633e0b76db1d8e7359e4efb2d60fba20d 08-May-2013 Javier Cardona <javier@cozybit.com> ath9k_htc: Add support for mesh interfaces

More specifically, enable AP-style beaconing on mesh
ifaces and change the hw capabilities to reflect mesh
support.

Coexistence with a virtual STA interface was tested as
working fine.

Signed-off-by: Javier Cardona <javier@cozybit.com>
[rebase, add iface combinations]
Signed-off-by: Thomas Pedersen <thomas@cozybit.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
c60c99298c50b698b0bbbe0e0146c965c322b8c1 08-Apr-2013 Felix Fietkau <nbd@openwrt.org> ath9k_common: remove ath9k_cmn_padpos

It is equivalent to ieee80211_hdrlen

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
bea843c73854becf998047a83af22a90de3fd19b 21-Nov-2012 Sujith Manoharan <c_manoha@qca.qualcomm.com> ath9k/ath9k_htc: Remove WME macros

Use the macros provided by mac80211 and remove redundant
declarations inside the drivers.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
8b2c98243e8d00f9c6b6059976d6de51491ee0c7 06-Nov-2012 Johannes Berg <johannes.berg@intel.com> mac80211: clarify interface iteration and make it configurable

During hardware restart, all interfaces are iterated even
though they haven't been re-added to the driver, document
this behaviour. The same also happens during resume, which
is even more confusing since all of the interfaces were
previously removed from the driver. Make this optional so
drivers relying on the current behaviour can still use it,
but to let drivers that don't want this behaviour disable
it.

Also convert all API users, keeping the old semantics
except in hwsim, where the new normal ones are desired.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
36323f817af0376c78612cfdab714b0feb05fea5 23-Jul-2012 Thomas Huehn <thomas@net.t-labs.tu-berlin.de> mac80211: move TX station pointer and restructure TX

Remove the control.sta pointer from ieee80211_tx_info to free up
sufficient space in the TX skb control buffer for the upcoming
Transmit Power Control (TPC).
Instead, the pointer is now on the stack in a new control struct
that is passed as a function parameter to the drivers' tx method.

Signed-off-by: Thomas Huehn <thomas@net.t-labs.tu-berlin.de>
Signed-off-by: Alina Friedrichsen <x-alina@gmx.net>
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
[reworded commit message]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
d8a2c51cdcaee0131c88f49d64b84f1c7361d72c 25-Jun-2012 Sujith Manoharan <c_manoha@qca.qualcomm.com> ath9k_htc: Use atomic operations for op_flags

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
d2182b69dcb6a68b1ef6070b2efd094e13dea3f1 15-Dec-2011 Joe Perches <joe@perches.com> ath: Convert ath_dbg(bar, ATH_DBG_<FOO>, to ath_dbg(bar, FOO

Add ATH_DBG_ to macros to shorten the uses and
reduce the line count.

Coalesce ath_dbg formats.
Add missing spaces to coalesced formats.
Add missing newline terminations to ath_dbg formats.
Align ath_dbg arguments where appropriate.
Standardize ath_dbg formats without periods.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
f29f5c0882bdd58c42b8176ee0b578f92589fda2 20-May-2011 Rajkumar Manoharan <rmanoharan@atheros.com> ath9k: Remove ATH9K_BEACON_PERIOD mask

Earlier beacon_interval is used to hold interval value and
some flags (ATH9K_BEACON_ENA &ATH9K_BEACON_PERIOD). So to
extract interval ATH9K_BEACON_PERIOD is used. Those flags
were completely removed. So masking beacon_interval is
not required.

Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
5b68138e5659cbfd5df2879d17f9ba0b66477fec 17-May-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k: Drag the driver to the year 2011

The Times They Are a-Changin'.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
0ff2b5c05d4dd84222a8e163335c5b550e2ca195 20-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k: Fix warnings from -Wunused-but-set-variable

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
cea3235cf578b5e952f5a0cec9bc6c2e862eb697 16-Apr-2011 Rajkumar Manoharan <rmanoharan@atheros.com> ath9k_htc: Fix free slot value for cab queue

ath9k_htc_tx_get_slot can return zero as valid index.

Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com>
Acked-by: Sujith Manoharan <Sujith.Manoharan@Atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2c5d57f004673a9c8658e20b1fa3f992b5a10f70 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Add TX slots

Maintain a bitmap of slots for transmission and update
the cookie field for every packet with the slot value.
This value would be used for matching packets when TX
completion processing is added.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
d67ee5339363608adce786ec8fd62a0fb2b66116 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Introduce new HTC API

A new routine that takes an endpoint explicitly is
introduced. The normal htc_send() now retrieves the endpoint
from the packet's private data. This would be useful
in TX completion when the endpoint ID would be required.
While at it, use a helper function to map the queue to endpoint.

Data/mgmt/beacon packets use htc_send(), while WMI comamnds
pass the endpoint to HTC.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
8e86a54715c4102a8ed697939de9ebd9715dc59c 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Fix TX queue management

Handle queue start/stop properly by maintaining
a counter to check if the pending frame count has
exceeded the threshold. Otherwise, packets would be
dropped needlessly. While at it, use a simple flag
to track queue status and use helper functions too.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
40dc9e4b86963b77918f1b8fa02b98c1e420a7e1 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Use SKB's private area for TX parameters

For all packets sent through the USB_WLAN_TX_PIPE endpoint,
the private area of the SKB's tx_info can be used to store
driver-specific information. For packets sent through USB_REG_OUT_PIPE,
this will not make a difference since they are routed through a
separate routine that doesn't access the private region.

This would help in situations where TX information is required
in the URB callback.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
f4c88991f51e097b6541f998fd23d477999e5886 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Queue WMI events

Use a queue to handle WMI events and schedule a tasklet
to process the events. This fixes the race between the
WMI event ISR and the SWBA tasklet when the arrival of
WMI events in quick succession could overwrite the SWBA
data before the tasklet from a previous iteration could
have been scheduled. Also, drain the WMI queue properly.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
b0a6ba983e3663bf256ca2e79d17bb846878cd9e 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Fix beacon miss under heavy load

Transmission of beacons becomes erratic when TX load
is high, since the latency involved in the generation
of a SWBA interrupt on the target to the actual sending
of a beacon is quite high for USB devices.

Fix this by adjusting the beacon response time.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
7d547eb4bb664c5a6b7c8790c2ecb0aec5d15385 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Handle buffered frames in AP mode

Use the CAB endpoint to send buffered multicast or
broadcast frames after each SWBA event.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2493a547ee81e6daca812d5dd7cf9357aebc379b 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Configure the beacon queue

Set operating parameters (cwmin, cwmax) for the beacon queue
in AP mode.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
9b674a0207c9b75ddcdcdb07e46843fac8267507 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Add TSF adjust capability

In multi-interface mode, beacons/probe responses that are
sent out must have their timestamp field updated. Calculate
the TSF adjustment value for each beaconing interface and set it
in the frame properly.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
832f6a18fc2aead14954c081ece03b7a5b425f81 13-Apr-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Add beacon slots

Beacon transmission is now handled through a slot mechanism.
This allows multiple beaconing interfaces to be be present.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
dd347f2fb2ddb20a80e9a8285252bf208ab91398 22-Mar-2011 Felix Fietkau <nbd@openwrt.org> ath9k: fix beacon timer handling issues

AP mode beacon timers in ath9k are configured in milliseconds, which breaks
when increasing ATH_BCBUF to 8 instead of 4 (due to rounding errors).
Since the hardware timers are actually configured in microseconds, it's
better to let the driver use that unit directly.

To be able to do that, the beacon interval parameter abuse for passing
certain flags needs to be removed. This is easy to do, because those flags
are completely unnecessary anyway. ATH9K_BEACON_ENA is ignored,
ATH9K_BEACON_RESET_TSF can be replaced with calling ath9k_hw_reset_tsf
from the driver directly.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
e7a2a4f5e61ccfae03185384e06b852dbb1e3630 27-Feb-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Handle BSSID/AID for multiple interfaces

The AID and BSSID should be set in the HW only for the
first station interface or adhoc interface. Also, cancel
the ANI timer in stop() for multi-STA scenario. And finally
configure the HW beacon timers only for the first station
interface.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
200be651f77f8407086873520436bf55a4468e26 21-Feb-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Fix TBTT calculation for IBSS mode

The target beacon transmission time has to be synced with the HW
TSF when configuring beacon timers in Adhoc mode. Failing to do this
would cause erroneous beacon transmission, for example, on completion
of a scan run to check for IBSS merges.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
a5fae37d118bb633708b2787e53871e38bf3b15e 21-Feb-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Configure beacon timers in AP mode

Handle multi-interface situations by checking if
AP interfaces are already present.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
9a3d025be11a1da625f8a71636b55a3bd3718574 21-Feb-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Make sequence number calculation per-VIF

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
7c277349ecbd66e19fad3d949fa6ef6c131a3b62 21-Feb-2011 Sujith Manoharan <Sujith.Manoharan@atheros.com> ath9k_htc: Remove OP_ASSOCIATED variable

mac80211 stores the association state in ieee80211_bss_conf.
Use this and remove the local state, which is incorrect anyway
since it is stored globally and not on a per-VIF basis.

Restarting ANI and reconfiguration of HW beacon timers when a
scan run ends requires more work. This is handled by iterating
over the active interfaces.

Finally, remove the useless check for associated status in RX
processing.

Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
226afe68fdbd1aa3680158aca0a3631cbd019626 03-Dec-2010 Joe Perches <joe@perches.com> ath: Convert ath_print to ath_dbg

Remove ath/debug.h and the includes of these files.
Coalesce long formats.
Correct a few misspellings and missing "\n"s from these logging messages.
Remove unnecessary trailing space before a newline.
Remove ARRAY_SIZE casts, use printf type %zu

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
3800276a40751539a920ef8e0537ef2e19126799 03-Dec-2010 Joe Perches <joe@perches.com> ath: Convert ath_print(.., ATH_DBG_FATAL to ath_err

So these errors are always emitted at KERN_ERR level.
Remove ARRAY_SIZE casts, use printf type %zu

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
9cf13668a5f8165a81349defc5f82c57a4a8279b 20-Sep-2010 Rajkumar Manoharan <rmanoharan@atheros.com> ath9k_htc: Fix beacon distribution in IBSS mode

This patch ensures fair beacon distribution in IBSS mode
by configuring proper CWmin based on slot time.

Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
e8c35a77e3408171852bde4914b650cf5b83e0d1 12-Jun-2010 Felix Fietkau <nbd@openwrt.org> ath9k_htc: use common WMM AC definitions instead of ath9k ones

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
764580f577a46adce6ad6717a9b34aa8e3a09159 01-Jun-2010 Sujith <Sujith.Manoharan@atheros.com> ath9k_htc: Fix fair beacon distribution

This patch fixes beacon distribution in IBSS mode
by configuring the hardware beacon queue properly.

Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
9c6dda4e2dfea970a7105e3805f0195bc3079f2f 06-May-2010 Sujith <Sujith.Manoharan@atheros.com> ath9k_htc: Fix beaconing in IBSS mode

The current way of managing beaconing in ad-hoc
mode has a subtle race - the beacon obtained from mac80211
is freed in the SWBA handler rather than the TX
completion routine. But transmission of beacons goes
through the normal SKB queue maintained in hif_usb,
leading to a situation where __skb_dequeue() in the TX
completion handler goes kaput.

Fix this by simply getting a beacon from mac80211 for
every SWBA and free it in its completion routine.

Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
7f1f5a0060e377ff6a15903487b39223e12b8568 16-Apr-2010 Sujith <Sujith.Manoharan@atheros.com> ath9k_htc: Fix sparse endian warnings

This patch fixes a bunch of endian issues that
were exposed by sparse. It's a miracle that the driver
worked at all till now.

The Lord be praised.

Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
fcb9392ff7ccb010818f3609420fd5416f6ca22e 16-Apr-2010 Sujith <Sujith.Manoharan@atheros.com> ath9k_htc: Cleanup beacon configuration

This patch cleans up beacon configuration,
removing a redundant interface type check
and updating beacon interval in the correct place.

Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
1c3652a5732879263aeebe606ca7af9e66fe0b2f 05-Apr-2010 Vivek Natarajan <vnatarajan@atheros.com> ath9k_htc: Configure the beacon timers once the scan is completed.

Signed-off-by: Vivek Natarajan <vnatarajan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
fb9987d0f748c983bb795a86f47522313f701a08 17-Mar-2010 Sujith <Sujith.Manoharan@atheros.com> ath9k_htc: Support for AR9271 chipset.

Features:

* Station mode
* IBSS mode
* Monitor mode
* Legacy support
* HT support
* TX/RX 11n Aggregation
* HW encryption
* LED
* Suspend/Resume

For more information: http://wireless.kernel.org/en/users/Drivers/ath9k_htc

Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: Vasanthakumar Thiagarajan <vasanth@atheros.com>
Signed-off-by: Senthil Balasubramanian <senthilkumar@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>