Commit Graph

269892 Commits (83c76570961573e56a238d84ba18f2581ef1e6b5)

Author SHA1 Message Date
Johannes Berg d64d373ffe nl80211: fix compiler warning
John reported the following warning:

net/wireless/nl80211.c: In function ‘nl80211_tx_mgmt’:
net/wireless/nl80211.c:5286:8: warning: ‘hdr’ may be used uninitialized in this function

Evidently, his version of gcc isn't able to see that
when "msg" is initialized, "hdr" must also be. My
gcc, 4.6.1, can actually see that and doesn't warn.
Simply initialize the variable to NULL. That means
if the compiler was ever right we'll crash though so
isn't really optimal since it may hide warnings from
the compiler when somebody modifies this code in the
future.

Reported-by: John Linville <linville@tuxdriver.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:51 -05:00
Arik Nemtsov e0830f71e7 mac80211: make sure hw_key exists before checking its flags
Fixes a bug introduced in:

commit 077a915489
Author: Arik Nemtsov <arik@wizery.com>
Date:   Sun Oct 23 08:21:41 2011 +0200

Reported-by: Arend van Spriel <arend@broadcom.com>
Reported-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Arik Nemtsov <arik@wizery.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:51 -05:00
Daniel Kuehn fdacbcda7f ath9k: set ATH9K_PCI to y by default
Most ath9k devices are PCI/PCIe based, therefor making PCI/PCIe support
default y helps those porting a config from 2.6 kernel series
from getting "non-functional" wireless drivers with 3.x kernel series.

Signed-off-by: Daniel Kuehn <daniel@kuehn.se>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:51 -05:00
Johannes Berg 776d68f863 wireless: move ieee80211chan2mhz macro
The macro is only used in ipw2200 and we certainly
don't want to encourage its use, so move it out of
the radiotap header file and into the driver.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:50 -05:00
Eyal Shapira 8e1b23b9ed mac80211: add recalc PS in ieee80211_reconfig()
Driver should be instructed to enter PS AFTER
reconfiguring ASSOCIATED (in STA case) using ieee80211_bss_info_change_notify
same as it's being done in ieee80211_set_associated()

Signed-off-by: Eyal Shapira <eyal@wizery.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:50 -05:00
Ilan Elias db98c829b7 NFC: Check if NCI data flow control is used
Check if NCI data flow control is used in nci_tx_work.

Signed-off-by: Ilan Elias <ilane@ti.com>
Acked-by: Lauro Ramos Venancio <lauro.venancio@openbossa.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:50 -05:00
Ilan Elias ee4c64fb98 NFC: Removal of unused operations for NCI spec 1.0 d18
Remove unused NCI operations, e.g. create static rf connection.

Signed-off-by: Ilan Elias <ilane@ti.com>
Acked-by: Lauro Ramos Venancio <lauro.venancio@openbossa.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:50 -05:00
Ilan Elias e8c0dacd98 NFC: Update names and structs to NCI spec 1.0 d18
Addition, deletion and modification of NCI constants.
Changes in NCI commands, responses and notifications structures.

Signed-off-by: Ilan Elias <ilane@ti.com>
Acked-by: Lauro Ramos Venancio <lauro.venancio@openbossa.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:50 -05:00
Johannes Berg e999882a05 mac80211/cfg80211: report monitor channel in wireless extensions
Just add API to get the channel & report it. Trivial really.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:50 -05:00
Johannes Berg 07ef03ee8b mac80211: simplify scan state machine
Attempting to micro-optimise the scan by going
fully live again when scanning the operating
channel just made the code extremely complex
and has little gain in most use cases. Remove
all that code and simplify the state machine
again.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:49 -05:00
Eliad Peller 86a2ea4134 mac80211: set carrier_on for ibss vifs only while joined
mac80211 should set carrier_on for ibss vifs
only while they are joined (similar to sta vifs)

Signed-off-by: Eliad Peller <eliad@wizery.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:49 -05:00
Rajkumar Manoharan 94e2ad9ee4 ath9k_hw: Fix channel list of CalFreqPeir for AR938x
This patch sync up CalFreqPeir channel list and paprd rate mask
of AR938x templates to the latest received from Systems team.

Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:49 -05:00
Rajkumar Manoharan 202bff08bf ath9k_hw: Read and configure xpa timing field
Configure xpa timing field while loading boad defaults to
fix 11b CCK spur issue that was observed in EMI testing.

Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:49 -05:00
Rajkumar Manoharan df222edc09 ath9k_hw: Read and configure quick drop for AR9003
Read and configure quick drop feild from AR9003 eeprom
inorder to help with strong signal. This patch also removes
obsolate parameters ob, db_stage2, db_stage_3, db_stage4
from the eeprom templates.

Signed-off-by: Rajkumar Manoharan <rmanohar@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:48 -05:00
Amitkumar Karwar aa95a48d46 mwifiex: release bss structure returned by cfg80211_inform_bss()
Following compilation warning is fixed by releasing referenced BSS
structure returned by cfg80211_inform_bss().

"warning: ignoring return value of cfg80211_inform_bss,
declared with attribute warn_unused_result"

Cc: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:48 -05:00
Amitkumar Karwar f72fa45f7d mwifiex: remove unnecessary free_priv handler
Cfg80211 stack allocates private area for driver use in
struct cfg80211_bss. It will be freed by stack in bss_release().
Driver don't need to worry about it.

In mwifiex driver, we use the private area just to store band
information(u8). We don't allocate memory explicitly and store
it's pointer in bss->priv. Hence we don't have any cleanup work
to do in free_priv handler. Currently we try to free the allocated
private area in free_priv handler which is not correct.

This patch removes unnecessary free_priv handler.

Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:48 -05:00
Yogesh Ashok Powar 8ed1303321 mwifiex: fix 'Smatch' warnings
Following three warnings are fixed:

>init.c +256 mwifiex_init_adapter(71)
>warn: variable dereferenced before check 'adapter->sleep_cfm'
>(see line 191)

>sta_rx.c +193 mwifiex_process_sta_rx_packet(75)
>warn: variable dereferenced before check 'priv' (see line 182)

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:48 -05:00
Yogesh Ashok Powar 63af63330f mwifiex: fix coding style
Rename DataRate to data_rate and arrange 'for' loop
for better readability.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:48 -05:00
Yogesh Ashok Powar ab581472c0 mwifiex: change return types to void
Functions mwifiex_11n_dispatch_pkt_until_start_win and
mwifiex_11n_scan_and_dispatch used to always return value
zero for all inputs. Changing these functions to void.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:47 -05:00
Yogesh Ashok Powar eedf15d34d mwifiex: use existing helper function mwifiex_fill_cap_info
Use existing helper function mwifiex_fill_cap_info to fill
the HT CAP info for ibss beacons.

Also removing extra parenthesis block for better readability.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>

Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:47 -05:00
Yogesh Ashok Powar 33f38d425f mwifiex: fix ht_cap_info in ibss beacons
A local variable is used to calculate ht_cap_info.
Erroneously ht_cap.cap_info isn't updated in the ibss beacons
after the calculation. This patch fixes it.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Kiran Divekar <dkiran@marvell.com>
Signed-off-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:47 -05:00
Arik Nemtsov d64cf63e06 mac80211: init rate-control for TDLS sta when supp-rates are known
Initialize rate control algorithms only when supported rates are known
for a TDLS peer sta. Direct Tx between peers is not allowed before the
link is enabled. In turn, this only occurs after a change_station()
call that sets supported rates.

Signed-off-by: Arik Nemtsov <arik@wizery.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:47 -05:00
Dmitry Tarnyagin dd9dfb9f95 cfg80211: merge in beacon ies of hidden bss.
The problem with PSM when a hidden SSID was used was originally
reported by Juuso Oikarinen.

 - When generally scanning, the AP is getting a bss entry with
   a zero SSID.
 - When associating, a probe-req is sent to the AP with the SSID,
   and as a result a probe-response is received with the hidden
   SSID in place. As a consequence, a second bss entry is created
   for the AP, now with the real SSID.
 - After association, mac80211 executes ieee80211_recalc_ps(),
   but does not switch to powersave because the beacon-ies are missing.

As result, the STA does not ever enter PSM.

The patch merges in beacon ies of hidden bss from beacon to the probe
response, creating a consistent set of ies in place.

Patch is depended on "cfg80211: fix cmp_ies" made by Johannes.

Signed-off-by: Dmitry Tarnyagin <dmitry.tarnyagin@stericsson.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-11-11 12:32:47 -05:00
Vasanthakumar Thiagarajan 8cb6d9915f ath6kl: Fix error in writing create_qos debugfs
100 bytes are allocated to store the parameters which are needed
to create a priority stream. These 100 bytes are not sufficiant and
throws error when running the following command.

echo "6 2 3 1 1 9999999 9999999 9999999 7777777 0 6 45000 200 56789000
 56789000 5678900 0 0 9999999 20000 0" > create_qos

179 bytes are needed when the following vlaues are given so that
a maximum possible value in that data type can be given in decimal.

echo "255 255 255 255 255 4294967295 4294967295 4294967295 4294967295
 4294967295 255 65535 65535 4294967295 4294967295 4294967295 4294967295
 4294967295 4294967295 4294967295 4294967295" > create_qos

Following takes 187 bytes when given in hex

echo "0xff 0xff 0xff 0xff 0xff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff
 0xff 0xffff 0xffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff 0xffffffff
 0xffffffff 0xffffffff" > create_qos

Increase the size to 200 bytes so that it can hold upto the maximum
value possible for that data type.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 13:00:01 +02:00
Vasanthakumar Thiagarajan a29517ce40 ath6kl: Fix tx packet drop in AP mode with bridge
skb is dropped in ath6kl_data_tx() when the headroom in skb
is insufficient. We hit this condition for every skb in AP mode
which is used with bridge, so all tx packets are getting dropped
when tried to send traffic to wireless client from bridge. Fix
this by reallocating the headroom instead of dropping the skb
when it has lesser headroom than needed.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 13:00:01 +02:00
Raja Mani 902b46293b ath6kl: Remove few unused WMI stuff
* Removed unused WOW_MAX_FILTER_LISTS macro.

* Removed empty ath6kl_wmi_get_wow_list_event_rx() function.
  List of configured WOW patterns are maintained in CFG layer
  itself. No need to have this function in ath6kl to get
  configured WOW pattern list. It can added later if we need
  it for debugging.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 13:00:00 +02:00
Raja Mani eae9e0661b ath6kl: Expose ath6kl's WOW capabilities to cfg80211
Set the list of ath6kl's WOW trigger options in wiphy->wowlan.flags
variable during wiphy registration. So that, those options can be
configured via iw.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 13:00:00 +02:00
Raja Mani 0737237411 ath6kl: Remove WARN_ON msg in Suspend path
In the current code, WOW resume is executed first from RX path
and ar->state is moved to ATH6KL_STATE_ON. When platform calls
ath6kl_sdio_resume() in CFG resume context, that time ar->state
could have moved to ON state. Printing WARN_ON(1) is void in
this context. Hence removing this.

Once WOW resume is removed from RX path, This WARN_ON msg can be
reverted.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 13:00:00 +02:00
Raja Mani a918fb3cc6 ath6kl: Perform WOW resume in RX path in case of SDIO IRQ wake up
The target triggers sdio data line to wake up the host when
WOW pattern matches. This causes sdio irq handler is being
executed in the host side which internally hits ath6kl's RX path.

WOW resume should happen before start processing any data from
the target. So it's required to perform WOW resume in RX path.

This area needs bit rework to avoid WOW resume in RX path,
As of now it's fine to have this model, rework will be done later.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 13:00:00 +02:00
Raja Mani d7c44e0ba5 ath6kl: Invoke WOW suspend/resume calls during PM operation
Link ath6kl's wow suspend/resume functions with the actual suspend/resume path.

WOW mode is selected when the host sdio controller supports both
MMC_PM_KEEP_POWER and MMC_PM_WAKE_SDIO_IRQ capabilities.

kvalo: also adds a missing break in ath6kl_cfg80211_resume(), luckily
it didn't have any effect on functionality.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 13:00:00 +02:00
Raja Mani 524441e3a7 ath6kl: Move ath6kl_cfg80211_stop() call specific to deep sleep and cut pwr
ath6kl_cfg80211_stop() call is not applicable for WOW mode. Hence moving
this call to deep sleep and cut pwr specific cases.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:59 +02:00
Raja Mani dd6c0c63b4 ath6kl: Add new state for WOW mode
In addition to existing deep sleep and cut pwr mode, new state
is added in ath6kl_cfg_suspend_mode as well as in ath6kl_state for WOW.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:59 +02:00
Raja Mani 0f60e9f4c2 ath6kl: Include new parameter in suspend path for wowlan
cfg80211 layer provides user defined wow parameters like Filter options, Patterns,
Pattern's mask, etc via "struct cfg80211_wowlan *wow" to suspend function.

Right now, this wowlan parameter is not handled in __ath6kl_cfg80211_suspend func.
This parameter has to be passed to HIF layer, So that it can be passed back to
ath6kl's cfg interface layer when WOW mode is selected.

In case of deep sleep and cut power mode, it's not handled.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:59 +02:00
Raja Mani 6cb3c714e7 ath6kl: Add WOW suspend/resume implementation
This is the core WOW suspend/resume functions will be called
in PM suspend/resume path.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:59 +02:00
Raja Mani 45cf110b2b ath6kl: Add wmi functions to configure WOW mode and host sleep mode
It will be used in WOW suspend/resume functions to
active/deactivate WOW suspend mode.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:59 +02:00
Raja Mani 5c9b4fa19a ath6kl: Add wmi functions to add/delete WOW patterns
These commands will be used in WOW suspend/resume functions
to configure WOW parameters like patterns to be matched
and it's mask value, etc.

Signed-off-by: Raja Mani <rmani@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:59 +02:00
Jouni Malinen f3e61eceb2 ath6kl: Do not hide ath6kl_wmi_addkey_cmd() error values
Instead of converting any error to EIO, just return the real error
value to upper layers.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:59 +02:00
Jouni Malinen f4bb9a6fbc ath6kl: Fix key configuration to copy at most seq_len from seq
There is no guarantee on the caller using 8-octet buffer for
key->seq, so better follow the key->seq_len parameter on figuring
out how many octets to copy.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:59 +02:00
Jouni Malinen 1ddc3377e1 ath6kl: Remove unused WMI crypto defines
Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:58 +02:00
Kalle Valo 8277de15ef ath6kl: add suspend_cutpower module parameter
This is to force ath6kl to power off hardware during suspend even if
sdio support keep power. This is needed, for example, when sdio
controller is buggy or maximum powersaving is desired.

Usage:

insmod ath6kl.ko suspend_cutpower=1

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:58 +02:00
Kalle Valo cf97fa9fdf ath6kl: don't power down hardware when interface is down
Jouni reported that my patch "ath6kl: power down hardware when interface
is down" caused a regression on his x86 boxes and scan didn't work anymore.
I was able to reproduce the problem by disabling all debug messages.

So there has to be a race condition somewhere in the code and disable the
functionality until the race is fixed. Now hardware is powered from the
point where module is loaded until it's removed.

Reported-by: Jouni Malinen <jouni@qca.qualcomm.com>
Tested-by: Jouni Malinen <jouni@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:00 +02:00
Vasanthakumar Thiagarajan 11f6e40d9f ath6kl: Fix lockdep warning
The following is the lockdep warning which detects possible
deadlock condition with the way ar->lock and ar->list_lock
are being used.

  (&(&ar->lock)->rlock){+.-...}, at: [<ffffffffa0492d13>] ath6kl_indicate_tx_activity+0x83/0x110 [ath6kl]
 but this lock took another, SOFTIRQ-unsafe lock in the past:
  (&(&ar->list_lock)->rlock){+.+...}

 and interrupts could create inverse lock ordering between them.

 other info that might help us debug this:
  Possible interrupt unsafe locking scenario:

        CPU0                    CPU1
        ----                    ----
   lock(&(&ar->list_lock)->rlock);
                                local_irq_disable();
                                lock(&(&ar->lock)->rlock);
                                lock(&(&ar->list_lock)->rlock);
   <Interrupt>
     lock(&(&ar->lock)->rlock);

  *** DEADLOCK ***

softirqs have to be disabled when acquiring ar->list_lock to avoid
the above deadlock condition. When the above warning printed the
interface is still up and running without issue.

Reported-by: Kalle Valo <kvalo@qca.qualcomm.com>
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:00 +02:00
Kalle Valo b4b2a0b116 ath6kl: cut power during suspend
If sdio controller doesn't support keep power, cut power from hardware
during suspend and restart firmware during resume. If we are connected
during suspend, send a disconnected event to user space.

Earlier suspend failed with an error if sdio didn't support keep power.
Now suspend will happen succesfully even with that case.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:00 +02:00
Kalle Valo e28e810486 ath6kl: refactor sdio configuration to a separate function
These commands are also needed after cutpower suspend so create
a function for them. Also fix memory leaks in ath6kl_sdio_probe() error
path.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:00 +02:00
Kalle Valo 76a9fbe27e ath6kl: add state variable depicting hw/fw state
This way it's easier to track state changes and in the future add
more warnings about using hardware in wrong states. Currently there
are few random flags for trying to do the same, those will be cleaned
and removed in the future.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:00 +02:00
Kalle Valo 52d81a6883 ath6kl: implement ath6kl_cfg80211_suspend()
This is in preparation for cutpower suspend feature. HIF layer makes
the decision based on information provided by cfg80211 and what hardware
actually supports. Then it calls ath6kl_cfg80211_suspend() to enable
the chosen mode.

Functionality should be the same, this is just preparation for
more suspend modes (cutpower and wow).

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:00 +02:00
Kalle Valo 1f40525512 ath6kl: reset CONNECT_PEND and CONNECTED flags in ath6kl_cfg80211_stop()
Otherwise first connection establish after cutpower suspend will
fail.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:59:00 +02:00
Kalle Valo ec4b7f602d ath6kl: create ath6kl_cfg80211_stop()
Just take code from deep sleep for now, will be improved later. No
functional changes.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:58:59 +02:00
Kalle Valo 1c17d31389 ath6kl: add aborted parameter to ath6kl_cfg80211_scan_complete_event()
Currently it takes an error code as status, but what we really want to
tell is if the scan was aborted or not.

Also fix a bug where we were comparing firmware scan status values
with kernel error codes, which is obviously wrong. This meant
that ath6kl didn't detect when firmware informed about failed scans. I
doubt that this fix doesn't make any difference in practise but it
still needs to be fixed. This is fixed by adding an enum for the success
status code and checking for that.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:58:59 +02:00
Kalle Valo 2387f0dcd1 ath6kl: print seqno in htc debug logs
Makes it easier to debug where frames are going.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
2011-11-11 12:58:59 +02:00