GitHub/LineageOS/G12/android_kernel_amlogic_linux-4.9.git
8 years agoMerge ath-next from ath.git
Kalle Valo [Thu, 3 Dec 2015 15:10:25 +0000 (17:10 +0200)]
Merge ath-next from ath.git

Major changes:

ath10k

* support Manegement Frame Protection (MFP)
* add thermal throttling support for 10.4 firmware
* add support for pktlog in QCA99X0
* add debugfs file to enable Bluetooth coexistence feature
* use firmware's native mesh interface type instead of raw mode

8 years agoath10k: implement fw_checksums debugfs file
Kalle Valo [Wed, 25 Nov 2015 13:38:41 +0000 (15:38 +0200)]
ath10k: implement fw_checksums debugfs file

When debugging firmware problems it's useful to check checksums of each
component. Add a debugfs interface to retrieve crc32 checksums:

# cat /sys/kernel/debug/ieee80211/phy0/ath10k/fw_checksums
firmware-N.bin          cc3fb466
athwlan                 c0089f21
otp                     f3efeb4f
codeswap                00000000
board-N.bin             bebc7c08
board                   bebc7c08

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: print crc32 checksums for firmware and board files
Kalle Valo [Wed, 25 Nov 2015 13:38:34 +0000 (15:38 +0200)]
ath10k: print crc32 checksums for firmware and board files

To detect cases if the firmare or board file is corrupted or otherwise modified print crc32 value
of both. Now the output looks like:

ath10k_pci 0000:02:00.0: pci irq msi interrupts 1 irq_mode 0 reset_mode 0
ath10k_pci 0000:02:00.0: qca99x0 hw2.0 target 0x01000000 chip_id 0x003801ff sub 168c:0002
ath10k_pci 0000:02:00.0: kconfig debug 1 debugfs 1 tracing 1 dfs 1 testmode 1
ath10k_pci 0000:02:00.0: firmware ver 10.4.1.00030-1 api 5 features no-p2p crc32 d2901e01
ath10k_pci 0000:02:00.0: board_file api 1 bmi_id 1:1 crc32 7e56fd07
ath10k_pci 0000:02:00.0: htt-ver 2.2 wmi-op 6 htt-op 4 cal otp max-sta 512 raw 0 hwcrypto 1

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: split driver info messages during device initialisation
Kalle Valo [Wed, 25 Nov 2015 13:38:27 +0000 (15:38 +0200)]
ath10k: split driver info messages during device initialisation

Earlier we printed all the info messages after a successful device
initialisation and firmware boot, but that's problematic if something goes
wrong and there's no easy way to know what firmware version was used and so on.

Split the info messages into smaller pieces and print them as soon as we have
the info available.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: always show bmi chip ids and subdevice ids
Kalle Valo [Wed, 25 Nov 2015 13:38:19 +0000 (15:38 +0200)]
ath10k: always show bmi chip ids and subdevice ids

That way we can split the messages to be printed in different stages of
device initialisation.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: reorganise hardware and firmware info messages
Kalle Valo [Wed, 25 Nov 2015 13:38:12 +0000 (15:38 +0200)]
ath10k: reorganise hardware and firmware info messages

This is to make it easier to split them later and also make room for crc32
checksums.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: fix otp board id error message
Kalle Valo [Wed, 25 Nov 2015 13:38:05 +0000 (15:38 +0200)]
ath10k: fix otp board id error message

We check board id from all board types, not just qca99x0, so the error message
was misleading.

Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: apply Mesh subtype when Mesh interface created.
Peter Oh [Tue, 24 Nov 2015 17:37:35 +0000 (09:37 -0800)]
ath10k: apply Mesh subtype when Mesh interface created.

QCA988X firmware starting from 10.2.4.70.12-2 has capability to support
Mesh Control Field Present bit in QoS field in native Wi-Fi mode.
Hence apply Mesh subtype according to the WMI service map.

Firmware will allows unicast, broadcast, multicast, and WDS frame
(FromDS = 1 and ToDS = 1) to be received via the interface, once Mesh
subtype is used.

The firmware and this patch together make native Wi-Fi mode comply to
IEEE802.11s Mesh frame in open mode, but the firmware doesn't yet
support secured Mesh mode.

Signed-off-by: Peter Oh <poh@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: introduce new subtypes for proxy STA and Mesh
Peter Oh [Tue, 24 Nov 2015 17:37:34 +0000 (09:37 -0800)]
ath10k: introduce new subtypes for proxy STA and Mesh

QCA988X firmware starting from 10.2.4.70.12-2 supports new
vdev subtypes for proxy STA and Mesh, hence add them to be used
as needed.

Signed-off-by: Peter Oh <poh@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: update WMI 10.x service map
Peter Oh [Tue, 24 Nov 2015 17:37:33 +0000 (09:37 -0800)]
ath10k: update WMI 10.x service map

Update WMI 10.x service map to sync with firmware 10.2.4.70.12-2
released on 11/11/2015 which is the latest QCA988X firmware as of
11/18/2015.

Signed-off-by: Peter Oh <poh@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: Fix write permission on few debugfs files
Mohammed Shafi Shajakhan [Tue, 24 Nov 2015 16:56:37 +0000 (22:26 +0530)]
ath10k: Fix write permission on few debugfs files

Fix write permission for few of the debugfs entries
which support write file operations as well.

Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: stop abusing GFP_DMA
Felix Fietkau [Tue, 24 Nov 2015 10:36:52 +0000 (11:36 +0100)]
ath10k: stop abusing GFP_DMA

Allocations from the DMA zone were originally added for legacy ISA
stuff, or PCI devices that have specific limitations in their DMA
addressing capabilities. It has no place in ath10k, which can do
full 32-bit DMA.

Fixes memory allocation errors on some platforms.

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: Enable AP + STA interface combination support for 10.x
Mohammed Shafi Shajakhan [Sat, 21 Nov 2015 09:54:41 +0000 (15:24 +0530)]
ath10k: Enable AP + STA interface combination support for 10.x

Enable AP + STA interface combination support for 10.x and
this enables Repeater mode testing (with WDS Repeater combinations
as well). Fix indentation as well.

Based on the suggestions from Michal and Yanbo Li,
thanks to them

Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: fix board data fetch error message
Peter Oh [Fri, 20 Nov 2015 17:33:14 +0000 (09:33 -0800)]
ath10k: fix board data fetch error message

The error message order of board data fetch is board info,
directory, and then file name, hence place print arguments
in the order.

Fixes: 0a51b343abfe ("ath10k: add board 2 API support")
Signed-off-by: Peter Oh <poh@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agowireless: airo: re-use mac_pton()
Andy Shevchenko [Fri, 27 Nov 2015 16:29:31 +0000 (18:29 +0200)]
wireless: airo: re-use mac_pton()

mac_pton() converts 6-byte MAC / BSSID to binary format. Change an open coded
variant by the generic one.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agobrcm80211: fix error code in brcmf_pcie_exit_download_state()
Dan Carpenter [Fri, 27 Nov 2015 13:43:27 +0000 (16:43 +0300)]
brcm80211: fix error code in brcmf_pcie_exit_download_state()

The original code returns 1 on failure and 0 on success but the caller
was expecting an error code on failure.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agolibertas: cleanup a variable name
Dan Carpenter [Thu, 26 Nov 2015 12:04:49 +0000 (15:04 +0300)]
libertas: cleanup a variable name

"&card->priv->driver_lock" and "&priv->driver_lock" are the same and
it's nicer to use the shorter one consistently.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agort2x00: type bug in _rt2500usb_register_read()
Dan Carpenter [Thu, 26 Nov 2015 11:55:23 +0000 (14:55 +0300)]
rt2x00: type bug in _rt2500usb_register_read()

This code causes a static checker bug.

drivers/net/wireless/ralink/rt2x00/rt2500usb.c:232 _rt2500usb_register_read()
warn: passing casted pointer 'value' to 'rt2500usb_register_read()' 32 vs 16.

If the low 16 bits were initialized to zero then this code would only be
a problem on big endian systems.  But in this case this is case the low
16 bits are never initialized.  This is called from a function which is
created using a macro:

RT2X00DEBUGFS_OPS(csr, "0x%.8x\n", u32);

We end up copying uninitialized data to the user which is bogus and an
information leak.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agobrcmfmac: Fix double free on exception at module load.
Hante Meuleman [Wed, 25 Nov 2015 10:32:47 +0000 (11:32 +0100)]
brcmfmac: Fix double free on exception at module load.

Reviewed-by: Arend Van Spriel <arend@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>
8 years agobrcmfmac: Unify methods to define and map firmware files.
Hante Meuleman [Wed, 25 Nov 2015 10:32:46 +0000 (11:32 +0100)]
brcmfmac: Unify methods to define and map firmware files.

All bus drivers (sdio, usb and pcie) require firmware files which
needs to be downloaded to the device, The definitions and mapping
of device id and revision to firmware and nvram file is done by
each bus driver. This patch creates common functions and defines
to simplify and unify the definition of these firmware and nvram
files and mapping.

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>
8 years agobrcmfmac: assure net_ratelimit() is declared before use
Arend van Spriel [Wed, 25 Nov 2015 10:32:45 +0000 (11:32 +0100)]
brcmfmac: assure net_ratelimit() is declared before use

Under some kernel configuration we get build issue with implicit
declaration of net_ratelimit() function. Fix this by explicitly
including the file providing the prototype.

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>
8 years agobrcmfmac: Add beamforming support.
Hante Meuleman [Wed, 25 Nov 2015 10:32:43 +0000 (11:32 +0100)]
brcmfmac: Add beamforming support.

Some devices support beamforming. This patch enables tx beamforming
if supported and reports beamforming capabilities per channel if
supported.

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>
8 years agobrcmfmac: Cleanup roaming configuration.
Hante Meuleman [Wed, 25 Nov 2015 10:32:42 +0000 (11:32 +0100)]
brcmfmac: Cleanup roaming configuration.

Put all roaming configuration related code in one place and
configure timeout based upon roaming setting.

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>
8 years agobrcmfmac: Remove redundant parameter action from scan.
Hante Meuleman [Wed, 25 Nov 2015 10:32:41 +0000 (11:32 +0100)]
brcmfmac: Remove redundant parameter action from scan.

ESCAN is always performed using action start scan. No need to
pass this parameter on to different functions.

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>
8 years agobrcmfmac: no retries on rxglom superframe errors
Franky Lin [Wed, 25 Nov 2015 10:32:40 +0000 (11:32 +0100)]
brcmfmac: no retries on rxglom superframe errors

Aborting the current read attempt on the superframe also removes the
packet from the pipeline. Retries should not be attempted on the next
packet since it would not be a superframe(either a superframe descriptor
or other data packet) and should not be handled by brcmf_sdio_rxglom

Reviewed-by: Hante Meuleman <meuleman@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: Arend Van Spriel <arend@broadcom.com>
Signed-off-by: Franky Lin <frankyl@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agobrcmfmac: Change error print on wlan0 existence.
Hante Meuleman [Wed, 25 Nov 2015 10:32:39 +0000 (11:32 +0100)]
brcmfmac: Change error print on wlan0 existence.

During initialization of the device, but also on some other
moments the driver prints an error that the netdev already exists.
This is a result of the way the driver is initializing the
firmware and not really an error. The code is not treating it as
an error either. This error print has resulted in many questions
by users and is confusing and incorrect. This patch changes the
error log into a debug info log.

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>
8 years agobrcmfmac: Return actual error by fwil.
Hante Meuleman [Wed, 25 Nov 2015 10:32:38 +0000 (11:32 +0100)]
brcmfmac: Return actual error by fwil.

FWIL is always mapping back errors to EBADE. This is not very
conventient when trying to understand problems by reading logs.
Some callers print the error code, but that is quite useless
when the exact error code is not returned. It also makes it
impossible to differentiate based on error code. This patch
changes the return of EBADE into the actual error code.

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>
8 years agobrcmfmac: Cleanup ssid storage.
Hante Meuleman [Wed, 25 Nov 2015 10:32:37 +0000 (11:32 +0100)]
brcmfmac: Cleanup ssid storage.

SSIDs used for connect and p2p got stored, but never used.

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>
8 years agowcn36xx: use new response format for wcn3620 remove_bsskey
Andy Green [Tue, 10 Nov 2015 08:25:55 +0000 (03:25 -0500)]
wcn36xx: use new response format for wcn3620 remove_bsskey

On wcn3620, firmware response to remove_bsskey uses the new, larger
"v2" format

Signed-off-by: Andy Green <andy.green@linaro.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agowcn36xx: use new response format for wcn3620 trigger_ba
Andy Green [Tue, 10 Nov 2015 08:25:54 +0000 (03:25 -0500)]
wcn36xx: use new response format for wcn3620 trigger_ba

On wcn3620, firmware response to trigger_ba uses the new, larger
"v2" format

Signed-off-by: Andy Green <andy.green@linaro.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agowcn36xx: handle new hal response format
Andy Green [Tue, 10 Nov 2015 08:25:53 +0000 (03:25 -0500)]
wcn36xx: handle new hal response format

wcn3620 has a new message structure for the reply to some hal
commands.  This patch adds the struct and helper routine that
uses it if the chip is wcn3620, or falls back to the old
helper routine.

We don't know what to do with the candidate list he sends back,
but we can at least accept and ignore it nicely instead of dying.

Signed-off-by: Andy Green <andy.green@linaro.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agowcn36xx: swallow two wcn3620 IND messages
Andy Green [Tue, 10 Nov 2015 08:25:52 +0000 (03:25 -0500)]
wcn36xx: swallow two wcn3620 IND messages

WCN3620 can asynchronously send two new kinds of indication message,
since we can't handle them just accept them quietly.

Signed-off-by: Andy Green <andy.green@linaro.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agowcn36xx: introduce WCN36XX_HAL_AVOID_FREQ_RANGE_IND
Andy Green [Tue, 10 Nov 2015 08:25:51 +0000 (03:25 -0500)]
wcn36xx: introduce WCN36XX_HAL_AVOID_FREQ_RANGE_IND

WCN3620 firmware introduces a new async indication, we need to
add it as a known message type so we can accept it

Signed-off-by: Andy Green <andy.green@linaro.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agolibertas: check for NULL before use
sudip [Tue, 24 Nov 2015 08:21:38 +0000 (13:51 +0530)]
libertas: check for NULL before use

If kzalloc fails it will return NULL. Lets check for NULL first before
using the pointer.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agortlwifi: btcoexist: re-use %*ph specifier to hexdump
Andy Shevchenko [Wed, 18 Nov 2015 14:09:18 +0000 (16:09 +0200)]
rtlwifi: btcoexist: re-use %*ph specifier to hexdump

Instead of printing each byte from the given buffer the code is converted to
use %*ph specifier.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agortlwifi: Delete unnecessary checks before the function call "kfree_skb"
Markus Elfring [Mon, 16 Nov 2015 12:12:25 +0000 (13:12 +0100)]
rtlwifi: Delete unnecessary checks before the function call "kfree_skb"

The kfree_skb() function tests whether its argument is NULL and then
returns immediately. Thus the test around the calls is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agobrcmfmac: constify brcmf_bus_ops structures
Julia Lawall [Sat, 14 Nov 2015 16:22:07 +0000 (17:22 +0100)]
brcmfmac: constify brcmf_bus_ops structures

The brcmf_bus_ops structures are never modified, so declare them as const.

Done with the help of Coccinelle.

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Acked-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agoath9k_htc: check for underflow in ath9k_htc_rx_msg()
Dan Carpenter [Fri, 6 Nov 2015 10:01:20 +0000 (13:01 +0300)]
ath9k_htc: check for underflow in ath9k_htc_rx_msg()

We check for overflow here, but we don't check for underflow so it
causes a static checker warning.

Fixes: fb9987d0f748 ('ath9k_htc: Support for AR9271 chipset.')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agobrcm80211: Delete an unnecessary check before the function call "release_firmware"
Markus Elfring [Fri, 6 Nov 2015 07:48:23 +0000 (08:48 +0100)]
brcm80211: Delete an unnecessary check before the function call "release_firmware"

The release_firmware() function tests whether its argument is NULL and then
returns immediately. Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Acked-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agobrcmfmac: Add wowl wake indication report.
Hante Meuleman [Thu, 29 Oct 2015 19:33:19 +0000 (20:33 +0100)]
brcmfmac: Add wowl wake indication report.

On wakeup of the system (resume) a wowl wakeup indication report
can be sent to cfg80211. This patch adds support for this. The
report specifies if the device was responsible for the wakeup
and if so, will specify the exact reason.

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>
8 years agobrcmfmac: Use new methods for pcie Power Management.
Hante Meuleman [Thu, 29 Oct 2015 19:33:18 +0000 (20:33 +0100)]
brcmfmac: Use new methods for pcie Power Management.

Currently the legacy methods suspend and resume are used for pcie
devices. This is not the preferable method and is also causing
issues with some setups when doing hibernate. Changing this to
use the new PM methods.

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>
8 years agobrcmfmac: Use consistent naming for bsscfgidx.
Hante Meuleman [Thu, 29 Oct 2015 19:33:17 +0000 (20:33 +0100)]
brcmfmac: Use consistent naming for bsscfgidx.

The variable bsscfgidx is used in different places with different
names, e.g. bsscfg, bssidx, bsscfg_idx. This patch cleans this up
by using bsscfgidx everywhere.

Reviewed-by: Arend Van Spriel <arend@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>
8 years agobrcmfmac: Add RSDB support.
Hante Meuleman [Thu, 29 Oct 2015 19:33:16 +0000 (20:33 +0100)]
brcmfmac: Add RSDB support.

Broadcom devices with a single 802.11 core can work on two band
concurrently using VSDB feature, ie. Virtual Simultaneous Dual-Band.
For devices that are fitted with two 802.11 cores and RF paths the
driver should support a firmware feature called RSDB, which stands
for Real Simultaneous Dual-Band. RSDB works almost autonomously in
firmware except for AP config. When the device supports RSDB then
the interface should not be brought down when configuring it,
otherwise the link (if configured) on the other interface will be
lost.

Reviewed-by: Arend Van Spriel <arend@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>
[kvalo@codeaurora.org: changed the commit log based on discussion]
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
8 years agobrcmfmac: Disable runtime pm for USB.
Hante Meuleman [Thu, 29 Oct 2015 19:33:15 +0000 (20:33 +0100)]
brcmfmac: Disable runtime pm for USB.

Currently runtime pm is enabled for USB, but it is not properly
supported by driver. This patch disables the runtime PM support
completely for USB, as it currently can result in problems on
some systems.

Reviewed-by: Arend Van Spriel <arend@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>
8 years agobrcmfmac: Remove unncessary variable irq_requested.
Hante Meuleman [Thu, 29 Oct 2015 19:33:14 +0000 (20:33 +0100)]
brcmfmac: Remove unncessary variable irq_requested.

The variable irq_requested is unneeded as the functionality
it is providing, is also provided by the variable irq_allocated.

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>
8 years agobrcmfmac: Remove unnecessary check from start_xmit.
Hante Meuleman [Thu, 29 Oct 2015 19:33:13 +0000 (20:33 +0100)]
brcmfmac: Remove unnecessary check from start_xmit.

The brcmf_netdev_start_xmit checks if the ndev is still valid by
checking if it still exists in database. This check is not needed
and therefor removed.

Reviewed-by: Arend Van Spriel <arend@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>
8 years agobrcmfmac: Simplify and fix usage of brcmf_ifname.
Hante Meuleman [Thu, 29 Oct 2015 19:33:12 +0000 (20:33 +0100)]
brcmfmac: Simplify and fix usage of brcmf_ifname.

brcmf_ifname is a debug function to return a name related to an ifp,
but is using a rather complex implementation. It was also used
wrongly from bcdc as it did not use the bsscfgidx as it was supposed
to, but bssidx. This patch fixes that bug and simplifies
brcmf_ifname.

Reviewed-by: Arend Van Spriel <arend@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>
8 years agobrcmfmac: Add support for the BCM4359 11ac RSDB PCIE device.
Hante Meuleman [Thu, 29 Oct 2015 19:33:11 +0000 (20:33 +0100)]
brcmfmac: Add support for the BCM4359 11ac RSDB PCIE device.

Reviewed-by: Arend Van Spriel <arend@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>
8 years agoath10k: store msdu_id instead of txbuf pointers
Michal Kazior [Wed, 18 Nov 2015 05:59:23 +0000 (06:59 +0100)]
ath10k: store msdu_id instead of txbuf pointers

Txbuf is no longer a DMA pool and can be easily
tracked with a mere msdu_id. This saves 10 bytes
on 64bit systems and 6 bytes on 32bit systems of
precious sk_buff control buffer.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: replace vdev_id and tid in skb cb
Michal Kazior [Wed, 18 Nov 2015 05:59:22 +0000 (06:59 +0100)]
ath10k: replace vdev_id and tid in skb cb

This prepares the driver for future ieee80211_txq
and wake_tx_queue() support.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: fix tx header parsing
Michal Kazior [Wed, 18 Nov 2015 05:59:21 +0000 (06:59 +0100)]
ath10k: fix tx header parsing

Frames are not guaranteed to be 802.11 frames in
ath10k_htt_tx() and the tx completion handler.
In some cases, like TDLS, they can be Ethernet.
Hence checking, e.g. frame_control could yield
bogus results and behavior.

Fortunately this wasn't a real problem so far
because there's no FW/HW combination to encounter
this problem.

However it is good to fix this in advance.

Fixes: 75d85fd9993c ("ath10k: introduce basic tdls functionality")
Fixes: eebc67fef3ee ("ath10k: fix pmf for wmi-tlv on qca6174")
Fixes: 7b7da0a02192 ("ath10k: drop probe responses when too many are queued")
Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: pack up flags in skb_cb
Michal Kazior [Wed, 18 Nov 2015 05:59:20 +0000 (06:59 +0100)]
ath10k: pack up flags in skb_cb

It was wasteful to have all the flags as separate
bools.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: remove freq from skb_cb
Michal Kazior [Wed, 18 Nov 2015 05:59:19 +0000 (06:59 +0100)]
ath10k: remove freq from skb_cb

It was wasteful to keep it in the struct.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: remove is_offchan
Michal Kazior [Wed, 18 Nov 2015 05:59:18 +0000 (06:59 +0100)]
ath10k: remove is_offchan

It was wasteful to keep it in the struct.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: remove txmode from skb_cb
Michal Kazior [Wed, 18 Nov 2015 05:59:17 +0000 (06:59 +0100)]
ath10k: remove txmode from skb_cb

It was wasteful to keep it in the struct because
it can be passed as function argument down the tx
path.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: rename function to adhere to naming convention
Michal Kazior [Wed, 18 Nov 2015 05:59:16 +0000 (06:59 +0100)]
ath10k: rename function to adhere to naming convention

All functions should have ath10k_{filename}_
prefixes.

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: merge is_protected with nohwcrypt
Michal Kazior [Wed, 18 Nov 2015 05:59:15 +0000 (06:59 +0100)]
ath10k: merge is_protected with nohwcrypt

It was wasteful to have two flags describing
the same thing.

While at it fix code style of
ath10k_tx_h_use_hwcrypto().

Signed-off-by: Michal Kazior <michal.kazior@tieto.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
8 years agoath10k: adjust the RX packet pad offset at QCA99X0 4addr mode
Yanbo Li [Mon, 16 Nov 2015 20:22:02 +0000 (22:22 +0200)]
ath10k: adjust the RX packet pad offset at QCA99X0 4addr mode

The QCA99X0 4 addresses RX packets pad 2 bytes at the beginning of
MSDU instead the end of ieee80211 header to keep alignment. The currently RX
data path can't parse the header correctly in this case. This patch fixes it
for QCA99X0.

Signed-off-by: Yanbo Li <yanbol@qca.qualcomm.com>
[kvalo@qca.qualcomm.com: checkpatch fixes and naming changes]
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
9 years agomac80211_hwsim: move Kconfig entry for sorting alphabetically
Kalle Valo [Wed, 18 Nov 2015 08:45:54 +0000 (10:45 +0200)]
mac80211_hwsim: move Kconfig entry for sorting alphabetically

mac80211_hwsim was not placed alphabetically correctly in menuconfig, fix that.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoath: unify Kconfig with other vendors
Kalle Valo [Wed, 18 Nov 2015 08:38:32 +0000 (10:38 +0200)]
ath: unify Kconfig with other vendors

Change menuconfig to config to keep the Kconfig entries unified. Part of
reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoti: unify Kconfig with other vendors
Kalle Valo [Wed, 18 Nov 2015 08:27:43 +0000 (10:27 +0200)]
ti: unify Kconfig with other vendors

Rename WL_TI to WLAN_VENDOR_TI to match with other vendor configs and make sure
that it's enabled by default in new configs. Convert menuconfigs to regular
configs to unify the wireless drivers menuconfig. Part of reorganising wireless
drivers directory and Kconfig.

Also remove WLCORE dependency to WL_TI. It should not be needed as WLCORE is
already under if  WLAN_VENDOR_TI.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agomediatek: unify Kconfig with other vendors
Kalle Valo [Wed, 18 Nov 2015 08:23:52 +0000 (10:23 +0200)]
mediatek: unify Kconfig with other vendors

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agort2x00: move under ralink vendor directory
Kalle Valo [Wed, 18 Nov 2015 08:18:44 +0000 (10:18 +0200)]
rt2x00: move under ralink vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agorsi: add vendor Kconfig entry
Kalle Valo [Wed, 18 Nov 2015 08:15:33 +0000 (10:15 +0200)]
rsi: add vendor Kconfig entry

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agorealtek: create separate Kconfig file
Kalle Valo [Wed, 18 Nov 2015 08:09:24 +0000 (10:09 +0200)]
realtek: create separate Kconfig file

Add new a Kconfig file and a vendor config for realtek. Also update MAINTAINERS
which we missed to do when earlier moving rtlwifi.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoprism54: move under intersil vendor directory
Kalle Valo [Wed, 18 Nov 2015 07:56:45 +0000 (09:56 +0200)]
prism54: move under intersil vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoorinoco: move under intersil vendor directory
Kalle Valo [Wed, 18 Nov 2015 07:57:18 +0000 (09:57 +0200)]
orinoco: move under intersil vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agop54: move under intersil vendor directory
Kalle Valo [Wed, 18 Nov 2015 07:49:59 +0000 (09:49 +0200)]
p54: move under intersil vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agohostap: move under intersil vendor directory
Kalle Valo [Wed, 18 Nov 2015 07:42:58 +0000 (09:42 +0200)]
hostap: move under intersil vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agozd1211rw: move under zydas vendor directory
Kalle Valo [Wed, 18 Nov 2015 07:27:32 +0000 (09:27 +0200)]
zd1211rw: move under zydas vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agozd1201: move under zydas vendor directory
Kalle Valo [Wed, 18 Nov 2015 05:39:37 +0000 (07:39 +0200)]
zd1201: move under zydas vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agomwl8k: move under marvell vendor directory
Kalle Valo [Tue, 17 Nov 2015 19:18:12 +0000 (21:18 +0200)]
mwl8k: move under marvell vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agomwifiex: move under marvell vendor directory
Kalle Valo [Tue, 17 Nov 2015 19:14:51 +0000 (21:14 +0200)]
mwifiex: move under marvell vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agolibertas_tf: move under marvell vendor directory
Kalle Valo [Tue, 17 Nov 2015 19:11:21 +0000 (21:11 +0200)]
libertas_tf: move under marvell vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agolibertas: move under marvell vendor directory
Kalle Valo [Tue, 17 Nov 2015 19:07:19 +0000 (21:07 +0200)]
libertas: move under marvell vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoiwlwifi: move under intel vendor directory
Kalle Valo [Tue, 17 Nov 2015 18:57:38 +0000 (20:57 +0200)]
iwlwifi: move under intel vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoiwlegacy: move under intel directory
Kalle Valo [Tue, 17 Nov 2015 18:37:11 +0000 (20:37 +0200)]
iwlegacy: move under intel directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoipw2x00: move under intel vendor directory
Kalle Valo [Tue, 17 Nov 2015 18:24:59 +0000 (20:24 +0200)]
ipw2x00: move under intel vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agocw1200: move under st vendor directory
Kalle Valo [Tue, 17 Nov 2015 18:09:02 +0000 (20:09 +0200)]
cw1200: move under st vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agobrcm80211: move under broadcom vendor directory
Kalle Valo [Tue, 17 Nov 2015 17:52:05 +0000 (19:52 +0200)]
brcm80211: move under broadcom vendor directory

Part of reorganising wireless drivers directory and Kconfig. Note that I had to
edit Makefiles from subdirectories to use the new location.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agob43legacy: move under broadcom vendor directory
Kalle Valo [Tue, 17 Nov 2015 17:49:26 +0000 (19:49 +0200)]
b43legacy: move under broadcom vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agob43: move under broadcom vendor directory
Kalle Valo [Tue, 17 Nov 2015 17:49:23 +0000 (19:49 +0200)]
b43: move under broadcom vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoatmel: move under atmel vendor directory
Kalle Valo [Tue, 17 Nov 2015 17:49:20 +0000 (19:49 +0200)]
atmel: move under atmel vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoairo: move under cisco vendor directory
Kalle Valo [Tue, 17 Nov 2015 17:49:19 +0000 (19:49 +0200)]
airo: move under cisco vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agoadm80211: move under admtek vendor directory
Kalle Valo [Tue, 17 Nov 2015 17:49:19 +0000 (19:49 +0200)]
adm80211: move under admtek vendor directory

Part of reorganising wireless drivers directory and Kconfig.

Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
9 years agowil6210: hold wil->mutex while managing vrings
Vladimir Kondratiev [Fri, 6 Nov 2015 10:50:44 +0000 (12:50 +0200)]
wil6210: hold wil->mutex while managing vrings

To prevent race when connect flow may run in parallel with
the disconnect event.

Scenario leading to the bug is: while running connect flow on the AP,
STA sends disconnect. log follows.

<7>[  668.736269] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Configure for connection CID 1
<7>[  668.736269] wil6210 0000:01:00.0: wlan0: DBG[MISC]wil_vring_init_tx() max_mpdu_size 2048
<7>[  668.736301] wil6210 0000:01:00.0: wlan0: DBG[MISC]wil_vring_alloc()
<7>[  668.736363] wil6210 0000:01:00.0: wlan0: DBG[MISC]vring[1024] 0xffbe8000:d962ce08 0xdb244000
<7>[  668.736394] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Head 0x00880300 -> 0x00880308
<7>[  668.736394] wil6210 0000:01:00.0: wlan0: DBG[ WMI]WMI command 0x0821 [28]
<7>[  668.736426] DBG[ WMI]Cmd 00000000: 20 00 24 00 00 00 00 00 00 00 21 08 00 00 00 00   .$.......!.....
<7>[  668.736426] DBG[ WMI]cmd 00000000: 00 00 00 00 00 00 5f 5c 00 00 00 00 00 04 00 08  ......_\........
<7>[  668.736457] DBG[ WMI]cmd 00000010: 01 01 00 00 00 00 00 00 00 00 ff 0f              ............
<7>[  668.736488] wil6210 0000:01:00.0: wlan0: DBG[ IRQ]Pseudo IRQ 0x00000004
<7>[  668.736519] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Handle WMI 0x1824 (reply_id 0x1821)
<7>[  668.736519] wil6210 0000:01:00.0: wlan0: DBG[ IRQ]wil6210_mask_irq_pseudo()
<7>[  668.736519] wil6210 0000:01:00.0: wlan0: DBG[ IRQ]ISR MISC 0x20000000
<7>[  668.736551] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Handle WMI 0x1003 (reply_id 0x1821)
<7>[  668.736551] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Disconnect 04:ce:14:00:07:70 reason [proto 3 wmi 4]
<7>[  668.736582] wil6210 0000:01:00.0: wlan0: DBG[MISC]wil6210_disconnect()
<7>[  668.736613] wil6210 0000:01:00.0: wlan0: DBG[ IRQ]Thread IRQ
<7>[  668.736613] wil6210 0000:01:00.0: wlan0: DBG[ IRQ]Thread ISR MISC 0x20000000
<7>[  668.736644] wil6210 0000:01:00.0: wlan0: DBG[ IRQ]MBOX event
<7>[  668.736644] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Mbox head 00880330 tail 00880328
<7>[  668.736676] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Mbox evt 001a 0010 0000 00
<7>[  668.736676] wil6210 0000:01:00.0: wlan0: DBG[ WMI]WMI event 0x1821 MID 0 @3255145 msec
<7>[  668.736707] DBG[ WMI]evt 00000000: 1a 00 10 00 00 00 00 10 00 00 21 18 69 ab 31 00  ..........!.i.1.
<7>[  668.736707] DBG[ WMI]evt 00000010: 01 01 00 00 00 00 00 00                          ........
<7>[  668.736738] wil6210 0000:01:00.0: wlan0: DBG[ WMI]queue_work -> 0
<7>[  668.736738] wil6210 0000:01:00.0: wlan0: DBG[ WMI]wmi_recv_cmd -> 1 events queued
<7>[  668.736769] wil6210 0000:01:00.0: wlan0: DBG[ IRQ]wil6210_unmask_irq_pseudo()
<7>[  668.736832] wil6210 0000:01:00.0: wlan0: DBG[MISC]Disconnect 04:ce:14:00:07:70, CID=1, reason=3
<7>[  668.736832] wil6210 0000:01:00.0: wlan0: DBG[MISC]wil_disconnect_cid(CID 1, status 1)
<7>[  668.736894] wil6210 0000:01:00.0: wlan0: DBG[MISC]wil_vring_fini_tx() id=1
<7>[  668.736894] wil6210 0000:01:00.0: wlan0: DBG[MISC]free Tx vring 1 [1024] 0xffbe8000:d962ce08 0xdb244000
<7>[  668.736957] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Handle WMI 0x1821 (reply_id 0x1821)
<7>[  668.736988] wil6210 0000:01:00.0: wlan0: DBG[ WMI]Complete WMI 0x1821
<7>[  668.737019] wil6210 0000:01:00.0: wlan0: DBG[ WMI]wmi_call(0x0821->0x1821) completed in 0 msec
<3>[  668.737019] wil6210 0000:01:00.0: wlan0: Tx config failed, status 0x01
<7>[  668.739518] wil6210 0000:01:00.0: wlan0: DBG[MISC]wil_cfg80211_del_station(04:ce:14:00:07:70, reason=2)
<7>[  668.739550] wil6210 0000:01:00.0: wlan0: DBG[MISC]wil6210_disconnect()
<7>[  668.739550] wil6210 0000:01:00.0: wlan0: DBG[MISC]_wil6210_disconnect(bssid=04:ce:14:00:07:70, reason=2, ev-)
<7>[  668.739581] wil6210 0000:01:00.0: wlan0: DBG[MISC]Disconnect 04:ce:14:00:07:70, CID=-2, reason=2
<7>[  668.742705] wil6210 0000:01:00.0: wlan0: DBG[MISC]free Tx vring 1 [1024] 0x  (null):d962ce08 0x  (null)
<3>[  668.742736] __dma_free_remap: trying to free invalid coherent area:   (null)

Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
9 years agoath10k: fix the wrong RX rate idx report at 11G mode
Yanbo Li [Thu, 12 Nov 2015 18:36:10 +0000 (10:36 -0800)]
ath10k: fix the wrong RX rate idx report at 11G mode

The RX rate idx is not correct for 11G mode OFDM packet.
Because the bitrate table start with CCK index instead of OFDM.

Signed-off-by: Yanbo Li <yanbol@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
9 years agoath10k: fix peerid configuration in htt tx desc for htt version < 3.4
Vasanthakumar Thiagarajan [Thu, 5 Nov 2015 06:04:00 +0000 (11:34 +0530)]
ath10k: fix peerid configuration in htt tx desc for htt version < 3.4

Of a word in struct htt_data_tx_desc htt version >= 3.4 firmware uses
LSB 16-bit for frequency configuration which is used for offchannel tx
and MSB 16-bit is for peerid. But other firmwares using version 2.X
(10.1, 10.2.2, 10.2.4 and 10.4) are using 32-bit for peerid in htt tx
desc. So far no issue is found with the existing code setting peerid and
freq for HTT version 2.X, this could be mainly because of 0 as frequecy
(home channel) is being always passed with those firmwares. There may be
issues when non-zero freq is passed with firmware using < 3.4 htt version.
To be safe use target_version_major and target_version_minor along with
htt-op-version before configuring peer id and freq in htt tx desc. This
patch extends ath10k_mac_tx_frm_has_freq() to check for htt_op_version_tlv
and uses the helper while setting peerid in htt_tx_desc.

Fixes: 8d6d36243610 ("ath10k: fix offchan reliability")
Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
9 years agoath10k: rename the helper which is used for off-channel tx
Vasanthakumar Thiagarajan [Thu, 5 Nov 2015 06:03:59 +0000 (11:33 +0530)]
ath10k: rename the helper which is used for off-channel tx

Rename ath10k_mac_need_offchan_tx_work() to ath10k_mac_tx_frm_has_freq()
to make it more meaningful. This helper will be used in the future
change. No functionality change.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
9 years agoath10k: fix peer assoc complete WMI command for 10.4
Vasanthakumar Thiagarajan [Thu, 5 Nov 2015 06:03:58 +0000 (11:33 +0530)]
ath10k: fix peer assoc complete WMI command for 10.4

There is an extra 4-byte member when compared to WMI 10.2 added to
assoc complete command in WMI 10.4. This new member is used for 160Mhz
related configuration. This WMI command mismatch between host and
firmware does not cause any real issues because this new member is not
used in 10.4 firmwares so far (10.4.1.00030-1). This difference in WMI
command interface brings in a new wmi_ops for 10.4 gen_peer_assoc().
No noticeable functionality differences with this change can be seen
with the current 10.4 firmwares, but the WMI interface has to be
fixed to work with future 10.4 firmwares which may be using this new
member.

Signed-off-by: Vasanthakumar Thiagarajan <vthiagar@qti.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
9 years agoMerge branch 'akpm' (patches from Andrew)
Linus Torvalds [Wed, 11 Nov 2015 05:14:23 +0000 (21:14 -0800)]
Merge branch 'akpm' (patches from Andrew)

Merge final patch-bomb from Andrew Morton:
 "Various leftovers, mainly Christoph's pci_dma_supported() removals"

* emailed patches from Andrew Morton <akpm@linux-foundation.org>:
  pci: remove pci_dma_supported
  usbnet: remove ifdefed out call to dma_supported
  kaweth: remove ifdefed out call to dma_supported
  sfc: don't call dma_supported
  nouveau: don't call pci_dma_supported
  netup_unidvb: use pci_set_dma_mask insted of pci_dma_supported
  cx23885: use pci_set_dma_mask insted of pci_dma_supported
  cx25821: use pci_set_dma_mask insted of pci_dma_supported
  cx88: use pci_set_dma_mask insted of pci_dma_supported
  saa7134: use pci_set_dma_mask insted of pci_dma_supported
  saa7164: use pci_set_dma_mask insted of pci_dma_supported
  tw68-core: use pci_set_dma_mask insted of pci_dma_supported
  pcnet32: use pci_set_dma_mask insted of pci_dma_supported
  lib/string.c: add ULL suffix to the constant definition
  hugetlb: trivial comment fix
  selftests/mlock2: add ULL suffix to 64-bit constants
  selftests/mlock2: add missing #define _GNU_SOURCE

9 years agoMerge branch 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
Linus Torvalds [Wed, 11 Nov 2015 05:11:58 +0000 (21:11 -0800)]
Merge branch 'misc' of git://git./linux/kernel/git/mmarek/kbuild

Pull misc kbuild updates from Michal Marek:
 "This is the non-critical part of kbuild:

   - several coccinelle updates
   - make deb-pkg creates an armhf package if CONFIG_VFP=y
   - make tags understands some more powerpc macros"

* 'misc' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
  coccinelle: Improve checking for missing NULL terminators
  coccinelle: ifnullfree: handle various destroy functions
  coccinelle: ifnullfree: various cleanups
  cocinelle: iterators: semantic patch to delete unneeded of_node_put
  deb-pkg: Add automatic support for armhf architecture
  scripts/coccinelle: fix typos
  coccinelle: misc: remove "complex return code" warnings
  Coccinelle: fix incorrect -include option transformation
  coccinelle: tests: improve odd_ptr_err.cocci
  coccinelle: misc: move constants to the right
  scripts/tags.sh: Teach tags about some powerpc macros

9 years agoMerge branch 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
Linus Torvalds [Wed, 11 Nov 2015 05:06:50 +0000 (21:06 -0800)]
Merge branch 'kconfig' of git://git./linux/kernel/git/mmarek/kbuild

Pull kconfig updates from Michal Marek:

 - 'make xconfig' ported to Qt5, dropping support for Qt3

 - merge_config.sh supports a single-input-file mode and also respects
   $KCONFIG_CONFIG

 - Fix for incorrect display of >= and > in dependency expressions

* 'kconfig' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild: (44 commits)
  Add current selection check.
  Use pkg-config to find Qt 4 and 5 instead of direct qmake
  kconfig: Fix copy&paste error
  kconfig/merge_config.sh: Accept a single file
  kconfig/merge_config.sh: Support KCONFIG_CONFIG
  Update the buildsystem for KConfig finding Qt
  Port xconfig to Qt5 - Update copyright.
  Port xconfig to Qt5 - Fix goParent issue.
  Port xconfig to Qt5 - on Back clicked, deselect old item.
  Port xconfig to Qt5 - Add(back) one click checkbox toggle.
  Port xconfig to Qt5 - Add(back) lineedit editing.
  Port xconfig to Qt5 - Remove some commented code.
  Port xconfig to Qt5 - Source format.
  Port xconfig to Qt5 - Add horizontal scrollbar, and scroll per pixel.
  Port xconfig to Qt5 - Change ConfigItem constructor parent type.
  Port xconfig to Qt5 - Disable ConfigList soring
  Port xconfig to Qt5 - Remove ConfigList::updateMenuList template.
  Port xconfig to Qt5 - Add ConfigList::mode to initializer list.
  Port xconfig to Qt5 - Add ConfigItem::nextItem to initializer list.
  Port xconfig to Qt5 - Tree widget set column titles.
  ...

9 years agoMerge branch 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild
Linus Torvalds [Wed, 11 Nov 2015 04:55:37 +0000 (20:55 -0800)]
Merge branch 'kbuild' of git://git./linux/kernel/git/mmarek/kbuild

Pull kbuild update from Michal Marek:
 "The kbuild branch for v4.4-rc1 only has one commit: A new make
  kselftest-clean target cleans tools/testing/selftests"

* 'kbuild' of git://git.kernel.org/pub/scm/linux/kernel/git/mmarek/kbuild:
  kselftest: add kselftest-clean rule

9 years agoMerge tag 'linux-kselftest-4.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Wed, 11 Nov 2015 04:46:45 +0000 (20:46 -0800)]
Merge tag 'linux-kselftest-4.4-rc1' of git://git./linux/kernel/git/shuah/linux-kselftest

Pull kselftest updates from Shuah Khan:
 "This 12 patch update for 4.4-rc1 consists of a new pstore test and
  fixes to existing tests"

* tag 'linux-kselftest-4.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest:
  selftests: breakpoint: Actually build it
  selftests: vm: Try harder to allocate huge pages
  selftests: Make scripts executable
  selftests: kprobe: Choose an always-defined function to probe
  selftests: memfd: Stop unnecessary rebuilds
  selftests: Add missing #include directives
  selftests/seccomp: Be more precise with syscall arguments.
  selftests/seccomp: build and pass on arm64
  selftests: memfd_test: Revised STACK_SIZE to make it 16-byte aligned
  selftests/pstore: add pstore test scripts going with reboot
  selftests/pstore: add pstore test script for pre-reboot
  selftests: add .gitignore for efivarfs

9 years agoMerge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux
Linus Torvalds [Wed, 11 Nov 2015 04:37:28 +0000 (20:37 -0800)]
Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux

Pull drm fixes from Dave Airlie:
 "Two build fixes, one for VC4, one for nouveau where the ARM only code
  is doing something a bit strange.  While people are discussing that,
  just workaround it and fix the build for now.  The code in question
  will never get used on anything non-ARM anyways.

  Also one fix for AST that SuSE had been hiding in their kernel, that
  allows all fbdev apps to work on that driver"

* 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
  drm/nouveau: fix build failures on all non ARM.
  drm/ast: Initialized data needed to map fbdev memory
  drm/vc4: Add dependency on HAVE_DMA_ATTRS, and select DRM_GEM_CMA_HELPER

9 years agodrm/nouveau: fix build failures on all non ARM.
Dave Airlie [Mon, 9 Nov 2015 22:36:59 +0000 (08:36 +1000)]
drm/nouveau: fix build failures on all non ARM.

gk20a is an ARM only GPU, so we can just do the correct thing on
ARM but fail on other architectures. The other option was to use
SWIOTLB as the define, which means phys_to_page exists, but
this seems clearer.

Signed-off-by: Dave Airlie <airlied@redhat.com>
9 years agodrm/ast: Initialized data needed to map fbdev memory
Egbert Eich [Wed, 11 Jun 2014 12:59:55 +0000 (14:59 +0200)]
drm/ast: Initialized data needed to map fbdev memory

Due to a missing initialization there was no way to map fbdev memory.
Thus for example using the Xserver with the fbdev driver failed.
This fix adds initialization for fix.smem_start and fix.smem_len
in the fb_info structure, which fixes this problem.

Requested-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: stable@vger.kernel.org
Signed-off-by: Egbert Eich <eich@suse.de>
[pulled from SuSE tree by me - airlied]
Signed-off-by: Dave Airlie <airlied@redhat.com>
9 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Linus Torvalds [Wed, 11 Nov 2015 02:11:41 +0000 (18:11 -0800)]
Merge git://git./linux/kernel/git/davem/net

Pull networking fixes from David Miller:

 1) Fix null deref in xt_TEE netfilter module, from Eric Dumazet.

 2) Several spots need to get to the original listner for SYN-ACK
    packets, most spots got this ok but some were not.  Whilst covering
    the remaining cases, create a helper to do this.  From Eric Dumazet.

 3) Missiing check of return value from alloc_netdev() in CAIF SPI code,
    from Rasmus Villemoes.

 4) Don't sleep while != TASK_RUNNING in macvtap, from Vlad Yasevich.

 5) Use after free in mvneta driver, from Justin Maggard.

 6) Fix race on dst->flags access in dst_release(), from Eric Dumazet.

 7) Add missing ZLIB_INFLATE dependency for new qed driver.  From Arnd
    Bergmann.

 8) Fix multicast getsockopt deadlock, from WANG Cong.

 9) Fix deadlock in btusb, from Kuba Pawlak.

10) Some ipv6_add_dev() failure paths were not cleaning up the SNMP6
    counter state.  From Sabrina Dubroca.

11) Fix packet_bind() race, which can cause lost notifications, from
    Francesco Ruggeri.

12) Fix MAC restoration in qlcnic driver during bonding mode changes,
    from Jarod Wilson.

13) Revert bridging forward delay change which broke libvirt and other
    userspace things, from Vlad Yasevich.

* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (65 commits)
  Revert "bridge: Allow forward delay to be cfgd when STP enabled"
  bpf_trace: Make dependent on PERF_EVENTS
  qed: select ZLIB_INFLATE
  net: fix a race in dst_release()
  net: mvneta: Fix memory use after free.
  net: Documentation: Fix default value tcp_limit_output_bytes
  macvtap: Resolve possible __might_sleep warning in macvtap_do_read()
  mvneta: add FIXED_PHY dependency
  net: caif: check return value of alloc_netdev
  net: hisilicon: NET_VENDOR_HISILICON should depend on HAS_DMA
  drivers: net: xgene: fix RGMII 10/100Mb mode
  netfilter: nft_meta: use skb_to_full_sk() helper
  net_sched: em_meta: use skb_to_full_sk() helper
  sched: cls_flow: use skb_to_full_sk() helper
  netfilter: xt_owner: use skb_to_full_sk() helper
  smack: use skb_to_full_sk() helper
  net: add skb_to_full_sk() helper and use it in selinux_netlbl_skbuff_setsid()
  bpf: doc: correct arch list for supported eBPF JIT
  dwc_eth_qos: Delete an unnecessary check before the function call "of_node_put"
  bonding: fix panic on non-ARPHRD_ETHER enslave failure
  ...

9 years agoMerge branch 'for-4.4/io-poll' of git://git.kernel.dk/linux-block
Linus Torvalds [Wed, 11 Nov 2015 01:23:49 +0000 (17:23 -0800)]
Merge branch 'for-4.4/io-poll' of git://git.kernel.dk/linux-block

Pull block IO poll support from Jens Axboe:
 "Various groups have been doing experimentation around IO polling for
  (really) fast devices.  The code has been reviewed and has been
  sitting on the side for a few releases, but this is now good enough
  for coordinated benchmarking and further experimentation.

  Currently O_DIRECT sync read/write are supported.  A framework is in
  the works that allows scalable stats tracking so we can auto-tune
  this.  And we'll add libaio support as well soon.  Fow now, it's an
  opt-in feature for test purposes"

* 'for-4.4/io-poll' of git://git.kernel.dk/linux-block:
  direct-io: be sure to assign dio->bio_bdev for both paths
  directio: add block polling support
  NVMe: add blk polling support
  block: add block polling support
  blk-mq: return tag/queue combo in the make_request_fn handlers
  block: change ->make_request_fn() and users to return a queue cookie