Commit graph

495206 commits

Author SHA1 Message Date
Avinash Patil
09f63ae65f mwifiex: set wiphy params only once
RTS threshold, fragmentation threshold are per device properties.
Setting them on any interface would be reflected for all other
interfaces as well. This patch removes unnesessary command download
per interface.

Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Cathy Luo <cluo@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 10:20:08 +02:00
Avinash Patil
e52a85d383 mwifiex: remove redundant nick_name variable
This is not used anywhere execpt initialization.

Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Amitkumar Karwar <akarwar@marvell.com>
Signed-off-by: Cathy Luo <cluo@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 10:20:06 +02:00
Pramod Gurav
c72599bf4a ssb: Fix Sparse error in main
This change fixes below sparse error:
drivers/ssb/main.c:94:16: warning: symbol 'ssb_sdio_func_to_bus'
was not declared. Should it be static?

Acked-by: Michael Buesch <m@bues.ch>
Signed-off-by: Pramod Gurav <pramod.gurav@smartplayin.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 10:17:56 +02:00
Arend van Spriel
4165fe9a92 brcmfmac: fix nvram processing
The nvram file can hold a key=value combination in which the value
may have spaces, ie. 'RAW1=80 02 fe ff'. The parsing functionality
did not deal with this so it gives an error message:

[621746.311635] brcmfmac: brcmf_nvram_handle_key
	warning: ln=90:col=11: '=' expected, skip invalid key entry

because RAW1=80 is being considerd as key=value pair and it expects
'=' sign after '02' for next key=value pair. This entry can be
completely ignored as firmware does not need it.

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 10:00:19 +02:00
Arend van Spriel
7f52c81d02 brcmfmac: store revinfo retrieval result
When revinfo retrieval fails we can not show the firmware version
in ethtool driver info. Store the result to be used when handling
ethtool driver info callback.

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:17 +02:00
Arend van Spriel
e749c7d49c brcmfmac: show firmware release info in ethtool driver info
The ethtool driver info already contained the unique firmware
identifier. This patch adds the firmware release version.

   $ ethtool -i wlan4
   driver: brcmfmac
   version: 6.10.224.22
   firmware-version: 01-32bd010f

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:14 +02:00
Arend van Spriel
4862290319 brcmfmac: always obtain device revision info upon intialization
Obtain device revision information and store it.

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:12 +02:00
Arend van Spriel
9b1933a3bd brcmfmac: determine chip info when not provided by bus layer
In some scenarios the chip number and revision may not be provided
by the bus layer. If the chip number is not filled, the common
layer will ask the firmware for this information.

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:11 +02:00
Arend van Spriel
31fc436f18 brcmutil: use define for boardrev string function
Introducing a define that the caller of brcmu_boardrev_str() can
use to allocate enough room for buffer passed to the function.

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:09 +02:00
Arend van Spriel
86fec35e17 brcmfmac: do not load firmware when device is already running
In brcmf_usb_probe_cb() the device is checked to determine whether
it is already running firmware. However, when no firmware download
is needed it still continues to request the firmware files. This
is fixed by returning after successful setup.

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:07 +02:00
Hante Meuleman
649f38ae9e brcmfmac: Reopen netdev queue on bus state data.
During suspend the bus state is put in the down state. When data
is being transmitted during this state then the netdev queue will
be close. This patch will wake the queue on state data if the
queue was closed.

Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:05 +02:00
Hante Meuleman
a1cee865c3 brcmfmac: SDIO: avoid using bus state for private states.
Each bus driver is maintaing an exported bus state indicating
if upper layers can or cannot send data. SDIO is using this state
also for more private states. This makes handling the states and
state changes complex. This patch minimises the exposed states
and makes SDIO keep track of an internal state where necessary.

Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:03 +02:00
Arend van Spriel
8982cd40ac brcmfmac: wait for driver to go idle during suspend
Before going in suspend state the watchdog thread needs to put the
device in bus sleep state, which assures it can go in deep-sleep
state during D3 state.

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:59:00 +02:00
Arend van Spriel
9b7a0ddc60 brcmfmac: pass DEAUTH/DISASSOC reason code to user-space
The driver always called cfg80211_disconnected() with reason parameter
set to zero, ie. unknown. However, firmware does provide a valid
802.11 reason code in DEAUTH and DISASSOC event message to the driver.
This patch passes the reason code to cfg80211_disconnected().

Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:58:58 +02:00
Hante Meuleman
4dd8b26a40 brcmfmac: use SDIO DPC for control frames.
Control frames are normally handled outside DPC, but sometimes
within DPC. To simplify code always handle control within DPC.

Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:58:56 +02:00
Hante Meuleman
69d03ee0b7 brcmfmac: prevent possible deadlock on resuming SDIO device.
When the system is resumed a deadlock can occur when DPC gets
entered before resume is complete. This patch fixes this by
properly checking the suspend state outside the claim_host code
block.

Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Daniel (Deognyoun) Kim <dekim@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:58:54 +02:00
Hante Meuleman
5ef1e60419 brcmfmac: Relax scheduling of msgbuf worker on high throughput.
On every tx the flow worker is triggered. When running high
throughput data this causes an excessive amount of times the worker
gets activated. This patch starts scheduling the worker more relaxed
once outstanding tx has reached a certain depth.

Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:58:49 +02:00
Vladimir Kondratiev
382afc3d05 wil6210: move Rx reorder buffer allocation out of spinlock
This fixes issue reported by Dan Carpenter:
The patch 3277213feb: "wil6210: ADDBA/DELBA flows" from Dec 23,
2014, leads to the following static checker warning:

        drivers/net/wireless/ath/wil6210/rx_reorder.c:205 wil_tid_ampdu_rx_alloc()
        error: scheduling with locks held: 'spin_lock:tid_rx_lock'

drivers/net/wireless/ath/wil6210/rx_reorder.c
   202  struct wil_tid_ampdu_rx *wil_tid_ampdu_rx_alloc(struct wil6210_priv *wil,
   203                                                  int size, u16 ssn)
   204  {
   205          struct wil_tid_ampdu_rx *r = kzalloc(sizeof(*r), GFP_KERNEL);
                                                                 ^^^^^^^^^^
   206
   207          if (!r)
   208                  return NULL;
   209
   210          r->reorder_buf =
   211                  kcalloc(size, sizeof(struct sk_buff *), GFP_KERNEL);
                                                                ^^^^^^^^^^^
   212          r->reorder_time =
   213                  kcalloc(size, sizeof(unsigned long), GFP_KERNEL);
                                                             ^^^^^^^^^^^
   214          if (!r->reorder_buf || !r->reorder_time) {
   215                  kfree(r->reorder_buf);
   216                  kfree(r->reorder_time);
   217                  kfree(r);
   218                  return NULL;
   219          }
   220

[ snip ]

   331          spin_lock_bh(&sta->tid_rx_lock);
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
spin lock held.

   332
   333          wil_tid_ampdu_rx_free(wil, sta->tid_rx[tid]);
   334          sta->tid_rx[tid] = wil_tid_ampdu_rx_alloc(wil, agg_wsize, ssn);
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
function called with the lock held.

   335
   336          spin_unlock_bh(&sta->tid_rx_lock);

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:55:27 +02:00
Vladimir Kondratiev
40822a901e wil6210: implement cfg80211 probe_client() op
Access point require this API to check peer alive status.
Assume peer is alive when it is connected, because
firmware implements keep alive checks and will disconnect
peer if it is not alive.

Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:55:19 +02:00
Vladimir Kondratiev
713c8a29e4 wil6210: implement skb Tx status reporting
Implement Tx status reporting using skb_complete_wifi_ack().

Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:54:46 +02:00
Vladimir Shulman
1f80af2e38 wil6210: remove unnecessary interrupt moderation module parameters
Interrupt moderation parameters will never be passed as module
parameters. For product, they will be hard-coded after lab testing,
and for debugging, they can be altered via debugfs.

Signed-off-by: Vladimir Shulman <qca_shulmanv@qca.qualcomm.com>
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:54:07 +02:00
Vladimir Shulman
918465a3c2 wil6210: interrupt moderation configuration update
Due to HW limitation, inter-packet gap timeout max value is 13 usec.
Update of current thresholds from 15 to 13 usec.

Signed-off-by: Vladimir Shulman <qca_shulmanv@qca.qualcomm.com>
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:53:56 +02:00
Vladimir Shulman
3baedd9167 wil6210: tuning rings size
Tuning rings size for performance optimization.
Increasing Tx ring size, allows buffering more packets for HW, thus
eliminating idle periods which were observed with smaller ring at
high throughput, because HW was fetching packets faster than driver was
filling them into the TX ring. Rx ring was similarly increased to
avoid same problems in Rx.

Signed-off-by: Vladimir Shulman <qca_shulmanv@qca.qualcomm.com>
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:53:47 +02:00
Vladimir Shulman
f1871cd950 wil6210: Add Tx queue len configuration
Tx queue was hard-coded to 1000 in ether_setup. Add wil_dev_setup
function which configures tx queue len to chosen default value
after calling ether_setup.

Signed-off-by: Vladimir Shulman <qca_shulmanv@qca.qualcomm.com>
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:53:42 +02:00
Dedy Lansky
32a20d46b3 wil6210: ignore firmware failure to gracefully stop AP
upon cfg80211_stop_ap, a graceful AP shutdown is requested from firmware
followed by firmware reset.
In case graceful request failed, error was returned to cfg80211.

The change is to return success in this scenario, because firmware
reset will anyhow shutdown the AP.

Signed-off-by: Dedy Lansky <qca_dlansky@qca.qualcomm.com>
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:53:37 +02:00
Dedy Lansky
c5e96c91fa wil6210: fix timing of netif_carrier_on indication
netif_carrier_on indication was too late. In case Rx packet received
before netif_carrier_on indication, upper layers could not send
Tx packet back.

The fix is to indicate netif_carrier_on earlier:
for STA, indicate netif_carrier_on when association starts.
for AP/PCP, indicate netif_carrier_on upon starting AP/PCP.

Signed-off-by: Dedy Lansky <qca_dlansky@qca.qualcomm.com>
Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:53:32 +02:00
Vladimir Kondratiev
8c6796758f wil6210: sync WMI with firmware
Incorporate changes from firmware.

Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-29 09:53:14 +02:00
Taehee Yoo
314112e002 rtlwifi: rtl8192cu: Set fw_ready flag
After rtl8192cu download firmware routine, set fw_ready flag.

Signed-off-by: Taehee Yoo <ap420073@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-27 20:20:09 +02:00
Avinash Patil
1fe192d8d6 mwifiex: selectively choose ext_scan support
Some devices do not support extended scan.
This patch adds support to enble ext_scan selectively.
For SD/PCIe interfaces, deefine ext_scan_support as part of
card structure and use it to initialize ext_scan in adapter
during registering device. For USB interfaces, we initialize
ext_scan during register_dev handler.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-27 20:18:20 +02:00
Yogesh Ashok Powar
eaa3d9fa08 mwifiex: add support for USB8801
USB8801 is Marvell's 1x1 802.11bgn offering.
Patch adds Device IDs support and defines TX buffer size.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Nishant Sarmukadam <nishants@marvell.com>
Signed-off-by: Cathy Luo <cluo@marvell.com>
Signed-off-by: Frank Huang <frankh@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-27 20:18:18 +02:00
Yogesh Ashok Powar
52bd3d2023 mwifiex: add support for SD8801
SD8801 is Marvell's 1x1 802.11bgn offering.
This patch adds Device IDs for SD8801 and also defines card
structure which has definition for register offsets, buffer sizes etc.

Signed-off-by: Yogesh Ashok Powar <yogeshp@marvell.com>
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Nishant Sarmukadam <nishants@marvell.com>
Signed-off-by: Cathy Luo <cluo@marvell.com>
Signed-off-by: Frank Huang <frankh@marvell.com>
Reviewed-by: James Cameron <quozl@laptop.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-27 20:18:16 +02:00
Hong Xu
0c8a1e43aa ath9k and ath9k_htc: rename variable "led_blink"
ath9k and ath9k_htc use the variable name "led_blink" to indicate
whether the module parameter "blink" is on. This name is easy to
conflict with other variables, and has caused a compiler error found
by kbuild test bot. The compiler error is as following:

drivers/net/wireless/ath/ath9k/ath9k_htc.o:(.data+0x47c): multiple definition of `led_blink'
drivers/net/wireless/ath/ath9k/ath9k.o:(.bss+0x20): first defined here

Fixes: 3a939a6712 ("ath9k_htc: Add a module parameter to disable blink")
Reported-by: kbuild test robot <fengguang.wu@intel.com>
Signed-off-by: Hong Xu <hong@topbug.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-27 20:06:27 +02:00
Chun-Yeow Yeoh
0b70dc273c rtl8192cu: fix the mesh beaconing
Patch "rtlwifi: add support to send beacon frame" allows
the beaconing of rtl8192cu. But mesh beaconing is not
working. Fix this.

Signed-off-by: Chun-Yeow Yeoh <yeohchunyeow@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-27 19:58:43 +02:00
Taehee Yoo
33511b157b rtlwifi: add support to send beacon frame.
In AP mode, beacon frame is necessary to keep connection.
this patch adds a sending beacon frame routine in initialization routine.

Signed-off-by: Taehee Yoo <ap420073@gmail.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-27 19:51:49 +02:00
Johannes Berg
ea2325b89d mwifiex: set netif carrier off in ndo_open
This patch adds fix to set carrier state off during ndo_open.
Carrier should be set to ON when device is ready to send data.
In case of station/adhoc interface device is able to transfer
data after successful association/join operation.
For AP this would be after bss_active event.

Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Avinash Patil <patila@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-27 19:40:47 +02:00
Rafał Miłecki
c5ed1df781 bcma: use standard bus scanning during early register
Starting with kernel 3.19-rc1 early registration of bcma on MIPS is done
a bit later, with memory allocator available. This allows us to simplify
code by using standard bus scanning method.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 21:47:55 +02:00
Rasmus Villemoes
908414af25 atmel: Remove open-coded and wrong strcasecmp
The kernel's string library does in fact have strcasecmp, at least
since ded220bd8f ("[STRING]: Move strcasecmp/strncasecmp to
lib/string.c"). Moreover, this open-coded version is in fact wrong: If
the strings only differ in their last character, a and b have already
been incremented to point to the terminating NUL bytes, so they would
wrongly be treated as equal.

Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 21:38:54 +02:00
Nicholas Mc Guire
961d1bbecf p54pci: add handling of signal case
if(!wait_for_completion_interruptible_timeout(...))
only handles the timeout case - this patch adds handling the
signal case the same as timeout.

Signed-off-by: Nicholas Mc Guire <der.herr@hofr.at>
Acked-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 21:37:04 +02:00
Nicholas Mc Guire
5b4c6b4f0b p54: add handling of the signal case
if(!wait_for_completion_interruptible_timeout(...))
only handles the timeout case - this patch adds handling the
signal case the same as timeout.

Signed-off-by: Nicholas Mc Guire <der.herr@hofr.at>
Acked-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 21:33:42 +02:00
John Linville
c0719334bf ath5k: document a fall-through case in ath5k_hw_set_opmode
Coverity: CID 114932

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Acked-by: Nick Kossifidis <mickflemm@gmail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 21:17:26 +02:00
John Linville
811c69e63a ath9k_htc: remove dead code in error path of ath9k_htc_txcompletion_cb
This clause is conditioned on htc_hdr != NULL, but it will only be NULL
when that check is reached.

Coverity: CID 114318

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 21:16:02 +02:00
Vaishali Thakkar
362126cddb brcmfmac: Use put_unaligned_le32
This patch introduces the use of function put_unaligned_le32.

This is done using Coccinelle and semantic patch used is as follows:

@a@
typedef u32, __le32, uint32_t;
{u32,__le32,uint32_t} e32;
identifier tmp;
expression ptr;
expression y,e;
type T;
type T;
@@

- tmp = cpu_to_le32(y);

<+... when != tmp
(
- memcpy(ptr, (T)&tmp, \(4\|sizeof(u32)\|sizeof(__le32)\|sizeof(uint32_t)\|sizeof(e32)\));
+ put_unaligned_le32(y,ptr);
|
- memcpy(ptr, (T)&tmp, ...);
+ put_unaligned_le32(y,ptr);
)
...+>
? tmp = e

@@ type T; identifier a.tmp; @@

- T tmp;
...when != tmp

Signed-off-by: Vaishali Thakkar <vthakkar1994@gmail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 21:12:52 +02:00
Rafał Miłecki
799038ea9b bcma: clean bus initialization code
This moves main bus init code to the main.c and renames old function to
make its purpose clear.
Thanks to this change we'll also be able to separate scanning from
registration (and support PCIe Gen 2 devices) in the future.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 19:44:58 +02:00
Sabrina Dubroca
6b47aacaa4 b43: stop leds during suspend
Call b43_leds_stop during suspend to avoid this WARN:

WARNING: CPU: 1 PID: 0 at net/mac80211/util.c:755 ieee80211_can_queue_work.isra.11+0x35/0x50 [mac80211]()
queueing ieee80211 work while going to suspend

 [...]

Call Trace:
 [<c165fb2a>] dump_stack+0x48/0x69
 [<c1052f7b>] warn_slowpath_common+0x8b/0xc0
 [<f9c30225>] ? ieee80211_can_queue_work.isra.11+0x35/0x50 [mac80211]
 [<f9c30225>] ? ieee80211_can_queue_work.isra.11+0x35/0x50 [mac80211]
 [<c1052fe3>] warn_slowpath_fmt+0x33/0x40
 [<f9c30225>] ieee80211_can_queue_work.isra.11+0x35/0x50 [mac80211]
 [<f9c30260>] ieee80211_queue_work+0x20/0x40 [mac80211]
 [<f9f25d78>] b43_led_brightness_set+0x28/0x30 [b43]
 [<c14f3835>] led_timer_function+0xd5/0xe0
 [<c10cb534>] call_timer_fn+0xa4/0x4a0

Signed-off-by: Sabrina Dubroca <sd@queasysnail.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 19:40:40 +02:00
Dan Carpenter
bcb514413e wlcore: unlock on error in wl1271_op_suspend()
We recently introduced a new error path which needs an unlock.

Fixes: 6d5a748d48 ('wlcore: add ability to reduce FW interrupts during suspend')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 19:37:42 +02:00
Colin Ian King
59b23ebd7f rtlwifi/rtl8192de: remove redundant else if check
The else if check condition checks for the opposite of the
if check, hence the else if check is redundant and can be
replaced with a simple else:

if (rtlpriv->rtlhal.macphymode == SINGLEMAC_SINGLEPHY) {
	..
} else if (rtlpriv->rtlhal.macphymode != SINGLEMAC_SINGLEPHY) {
	..
}

replaced with:

if (rtlpriv->rtlhal.macphymode == SINGLEMAC_SINGLEPHY) {
	..
} else {
	..
}

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 19:30:45 +02:00
Hong Xu
3a939a6712 ath9k_htc: Add a module parameter to disable blink
Add an option "blink" to enable or disable the LED blink. The default
value is set to 1 so that existing users would not experience any
unexpected changes.

Signed-off-by: Hong Xu <hong@topbug.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 19:16:11 +02:00
Bob Copeland
e26dc173a6 wcn36xx: initiate TX BA sessions
Currently, wcn36xx only asks for a TX BA session if it has
already established one for RX.  Thus, two wcn36xx devices cannot
do a-mpdu between themselves since they both wait for the other
to go first.  Fix this by starting a BA session after a few QoS
data frames have been sent to a STA.

Signed-off-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 19:12:12 +02:00
Bob Copeland
5f3f928585 wcn36xx: move set_tx_pdu inside set_tx_data/mgmt
The pdu is part of the buffer descriptor, so it makes
sense that one function would fill both.  Also, passing
the whole skb instead of just the header pointer to the
set_tx_data function paves the way for using its fields
for ampdu setup inside set_tx_data().

Signed-off-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 19:12:09 +02:00
Bob Copeland
4b12462a3a wcn36xx: initialize dxe lock
The dxe lock is missing its initialization, so add it.

Signed-off-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-01-23 19:12:06 +02:00