[PATCH] wlcore: make wlcore_cmd_send_failsafe() static

2014-11-09 Thread Luca Coelho
From: Luciano Coelho The wlcore_cmd_send_failsafe() function is only called in the cmd.c file, where it is definde. Make it static. Additionally, move the EXPORT_SYMBOL macro for wl1271_cmd_send() to the right place. Signed-off-by: Luciano Coelho --- drivers/net/wireless/ti/wlcore/cmd.c | 7

[PATCH] wlcore: check minimum buffer size in some cmd_send functions

2014-11-09 Thread Luca Coelho
From: Luciano Coelho Check for the minimum required buffer length in wlcore_cmd_send() and wlcore_cmd_configure_failsafe. This ensures that we will never try to use a buffer that is smaller than the required header. Reported-by: Dan Carpenter Signed-off-by: Luciano Coelho --- NOTE: this is o

Re: [PATCH] mac80211: add back support for radiotap vendor namespace data

2014-11-09 Thread Luca Coelho
Hi Arend, On Sat, 2014-11-08 at 14:33 +0100, Arend van Spriel wrote: > On 11/07/14 20:37, Luca Coelho wrote: > > On November 7, 2014 9:15:21 PM EET, Johannes > > Berg wrote: > >> On Fri, 2014-11-07 at 14:37 +0200, Luca Coelho wrote: > >> > +#if 0 > +struct ieee80211_vendor_rad

Re: [PATCH 11/16] cfg80211: introduce TDLS channel switch commands

2014-11-09 Thread Arend van Spriel
On 11/09/14 17:50, Arik Nemtsov wrote: Introduce commands to initiate and cancel TDLS channel-switching. Once TDLS channel-switching is started, the lower level driver is responsible for continually initiating channel-switch operations and returning to the base (AP) channel to listen for beacons

[PATCH] brcmfmac: unlink URB when request timed out

2014-11-09 Thread Mathy Vanhoef
From: Mathy Vanhoef Unlink the submitted URB in brcmf_usb_dl_cmd if the request timed out. This assures the URB is never submitted twice, preventing a driver crash. Signed-off-by: Mathy Vanhoef --- Currently brcmfmac may crash when a USB device is attached (tested with a LG TWFM-B003D). In part

[PATCH 05/16] mac80211: add function to create data frame template including key

2014-11-09 Thread Arik Nemtsov
From: Johannes Berg For some TDLS channel switch implementations data frames need to be sent by the firmware based on a template. This template should be created by mac80211, and thus needs to properly be built from an 802.3 frame into an 802.11 frame. In addition, the device will need the key in

[PATCH 12/16] mac80211: add parsing of TDLS specific IEs

2014-11-09 Thread Arik Nemtsov
These are used in TDLS channel switching code. Signed-off-by: Arik Nemtsov Reviewed-by: Johannes Berg Signed-off-by: Arik Nemtsov --- include/linux/ieee80211.h | 15 +++ net/mac80211/ieee80211_i.h | 2 ++ net/mac80211/util.c| 16 3 files changed, 33 inser

[PATCH 06/16] mac80211: add supported channels IE during TDLS setup

2014-11-09 Thread Arik Nemtsov
This information element is mandatory in case TDLS channel-switching is to be supported. The channels given are ones supported and allowed to be active in the current regulatory setting. Signed-off-by: Arik Nemtsov Reviewed-by: Johannes Berg Signed-off-by: Arik Nemtsov --- net/mac80211/tdls.c

[PATCH 13/16] mac80211: introduce TDLS channel switch ops

2014-11-09 Thread Arik Nemtsov
Implement the cfg80211 TDLS channel switch ops and introduce new mac80211 ones for low-level drivers. Verify low-level driver support for the new ops when using the relevant wiphy feature bit. Also verify the peer supports channel switching before passing the command down. Add a new STA flag to tr

[PATCH 04/16] mac80211: factor out 802.11 header building code

2014-11-09 Thread Arik Nemtsov
From: Johannes Berg Factor out the 802.11 header building code from the xmit function to be able to use it separately in a later commit. While at it, fix up some documentation. Signed-off-by: Johannes Berg Signed-off-by: Arik Nemtsov --- net/mac80211/tx.c | 142 ++

[PATCH 10/16] mac80211: prepare TDLS mgmt code for channel-switch templates

2014-11-09 Thread Arik Nemtsov
Split the data-generating from the Tx-sending functionality, as we do not want to send templates to the lower driver. Also add an optional chandef argument to the data-generating portion. It will be used for channel-switch templates. Signed-off-by: Arik Nemtsov Reviewed-by: Johannes Berg Signed-

[PATCH 15/16] mac80211: add specific-queue flushing support

2014-11-09 Thread Arik Nemtsov
From: Liad Kaufman If the HW supports IEEE80211_HW_QUEUE_CONTROL, allow flushing only specific queues rather than all of them. Signed-off-by: Liad Kaufman Reviewed-by: Johannes Berg Signed-off-by: Arik Nemtsov --- net/mac80211/ieee80211_i.h | 3 +++ net/mac80211/util.c| 20 +

[PATCH 09/16] mac80211: track AP and peer STA TDLS chan-switch support

2014-11-09 Thread Arik Nemtsov
The AP or peer can prohibit TDLS channel switch via a bit in the extended capabilities IE. Parse the IE and track this bit. Set an appropriate STA flag if both the AP and peer STA support TDLS channel-switching. Add the new STA flag and the missing TDLS_INITIATOR to debugfs. Signed-off-by: Arik N

[PATCH 14/16] mac80211: add TDLS channel-switch Rx flow

2014-11-09 Thread Arik Nemtsov
When receiving a TDLS channel switch request or response, parse the frame and call a new tdls_recv_channel_switch op in the low level driver with the parsed data. Signed-off-by: Arik Nemtsov Reviewed-by: Johannes Berg Signed-off-by: Arik Nemtsov --- include/net/mac80211.h | 37 - net/

[PATCH 08/16] cfg/mac80211: define TDLS channel switch feature bit

2014-11-09 Thread Arik Nemtsov
Define some related TDLS protocol constants and advertise channel switch support in the extended-capabilities IE when the feature bit is defined. Actually supporting TDLS channel-switching also requires support for some new nl80211 commands, to be introduced by future patches. Signed-off-by: Arik

[PATCH 11/16] cfg80211: introduce TDLS channel switch commands

2014-11-09 Thread Arik Nemtsov
Introduce commands to initiate and cancel TDLS channel-switching. Once TDLS channel-switching is started, the lower level driver is responsible for continually initiating channel-switch operations and returning to the base (AP) channel to listen for beacons from time to time. Upon cancellation of

[PATCH 07/16] mac80211: add BSS coex IE to TDLS setup frames

2014-11-09 Thread Arik Nemtsov
Add the BSS coex IE in case we support HT40 channels, as mandated by section 8.5.13 in IEEE802.11 2012. Signed-off-by: Arik Nemtsov Reviewed-by: Johannes Berg Signed-off-by: Arik Nemtsov --- include/linux/ieee80211.h | 3 +++ net/mac80211/tdls.c | 15 +++ 2 files changed, 18

[PATCH 16/16] mac80211: synchronously reserve TID per station

2014-11-09 Thread Arik Nemtsov
From: Liad Kaufman In TDLS (e.g., TDLS off-channel) there is a requirement for some drivers to supply an unused TID between the AP and the device to the FW, to allow sending PTI requests and to allow the FW to aggregate on a specific TID for better throughput. To ensure that the allocated TID is

[PATCH 01/16] mac80211: add option for setting skb flags before xmit

2014-11-09 Thread Arik Nemtsov
From: Liad Kaufman Allows setting of an skb's flags - if needed - when calling ieee80211_subif_start_xmit(). Signed-off-by: Liad Kaufman Reviewed-by: Johannes Berg Signed-off-by: Arik Nemtsov --- net/mac80211/ieee80211_i.h | 3 +++ net/mac80211/tx.c | 21 + 2 fi

[PATCH 02/16] mac80211: retransmit TDLS teardown packet through AP if not ACKed

2014-11-09 Thread Arik Nemtsov
From: Liad Kaufman Since the TDLS peer station might not receive the teardown packet (e.g., when in PS), this makes sure the packet is retransmitted - this time through the AP - if the TDLS peer didn't ACK the packet. Signed-off-by: Liad Kaufman Reviewed-by: Johannes Berg Signed-off-by: Arik N

[PATCH 03/16] mac80211: move skb info band assignment out

2014-11-09 Thread Arik Nemtsov
From: Johannes Berg Instead of passing the band as a parameter to ieee80211_xmit() and ieee80211_tx(), move it outside of the two functions while making sure info->band is set up before calling them. This removes the parameter and simplifies the follow commit. Signed-off-by: Johannes Berg Sign

Re: brcmfmac not working on ECS LIVA

2014-11-09 Thread Arend van Spriel
On 11/08/14 21:39, Felipe Contreras wrote: Hi, I just got an ECS LIVA and I haven't been able to get the wireless working. First I got the error that the brcmfmac43241b4-sdio.txt file was missing. I got the file from the ECS's beta drivers [1], but it's still not working. brcmfmac: brcmf_sdio_d

[PATCH V2 2/3] ath: use seq_file api for ath9k debugfs files

2014-11-09 Thread Arend van Spriel
The debugfs files that are defined in debug.c which are read-only and using a simple_open as .open file operation have been modified to use the single_open seq_file API. This simplifies the read functions defining the file contents. Signed-off-by: Arend van Spriel --- drivers/net/wireless/ath/at

[PATCH V2 3/3] ath: ath9k: use debugfs_create_devm_seqfile() helper for seq_file entries

2014-11-09 Thread Arend van Spriel
Use the helper to get rid of the file operations per debugfs file. The struct ath9k_softc pointer is set as device driver data to be obtained in the seq_file read operation. Signed-off-by: Arend van Spriel --- drivers/net/wireless/ath/ath9k/ahb.c | 1 + drivers/net/wireless/ath/ath9k/debug.c

[PATCH V2 1/3] debugfs: add helper function to create device related seq_file

2014-11-09 Thread Arend van Spriel
This patch adds a helper function that simplifies adding a so-called single_open sequence file for device drivers. The calling device driver needs to provide a read function and a device pointer. The field struct seq_file::private will reference the device pointer upon call to the read function so

[PATCH V2 0/3] debugfs: adding helper for single seq_file

2014-11-09 Thread Arend van Spriel
This series replaces the initial series posted: Message-ID: <1414498752-9746-1-git-send-email-ar...@broadcom.com> This series include changes in driver code to investigate potential code savings. As example used the ath9k driver as it has a fair amount of debugfs files. In this series it changes