summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi
AgeCommit message (Collapse)AuthorFilesLines
2015-11-18iwlwifi: move under intel vendor directoryKalle Valo122-89829/+0
Part of reorganising wireless drivers directory and Kconfig. Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-11-04Merge tag 'driver-core-4.4-rc1' of ↵Linus Torvalds1-3/+3
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core Pull driver core updates from Greg KH: "Here's the "big" driver core updates for 4.4-rc1. Primarily a bunch of debugfs updates, with a smattering of minor driver core fixes and updates as well. All have been in linux-next for a long time" * tag 'driver-core-4.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: debugfs: Add debugfs_create_ulong() of: to support binding numa node to specified device in devicetree debugfs: Add read-only/write-only bool file ops debugfs: Add read-only/write-only size_t file ops debugfs: Add read-only/write-only x64 file ops debugfs: Consolidate file mode checks in debugfs_create_*() Revert "mm: Check if section present during memory block (un)registering" driver-core: platform: Provide helpers for multi-driver modules mm: Check if section present during memory block (un)registering devres: fix a for loop bounds check CMA: fix CONFIG_CMA_SIZE_MBYTES overflow in 64bit base/platform: assert that dev_pm_domain callbacks are called unconditionally sysfs: correctly handle short reads on PREALLOC attrs. base: soc: siplify ida usage kobject: move EXPORT_SYMBOL() macros next to corresponding definitions kobject: explain what kobject's sd field is debugfs: document that debugfs_remove*() accepts NULL and error values debugfs: Pass bool pointer to debugfs_create_bool() ACPI / EC: Fix broken 64bit big-endian users of 'global_lock'
2015-10-28Merge tag 'iwlwifi-next-for-kalle-2015-10-25' of ↵Kalle Valo20-101/+296
https://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next * bug fix for TDLS * fixes and cleanups in scan * support of several scan plans * improvements in FTM * fixes in FW API * improvements in the failure paths when the bus is dead * other various small things here and there
2015-10-25iwlwifi: nvm: free old section data when reading nvm fileMoshe Harel1-0/+1
When reading external NVM file, if a section exists both in OTP and in the external file, the memory that was allocated at OTP reading is not freed. This is possible only on systems that have an external NVM file which is typically the case on embedded systems. Signed-off-by: Moshe Harel <moshe.harel@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: disable TDLS ac queues correctlyArik Nemtsov1-2/+3
The iwl_mvm_disable_queue function requires the TID to be set to IWL_MAX_TID_COUNT when disabling an AC queue. Call it correctly for TDLS scenarios. Fixes: 4ecafae9e568 ("iwlwifi: mvm: support using multiple ACs on single HW queue") Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: take scan ref only on successEliad Peller1-9/+6
In some cases, scan reference was taken, but wasn't released even though scan command wasn't actually issued. Change the current code to simply take the reference only on success. Signed-off-by: Eliad Peller <eliadx.peller@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: remove pointless scan plan checksJohannes Berg1-14/+0
As cfg80211 already enforces these limits, there's little point in having them again here in our code. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: clean up some whitespace in scan codeJohannes Berg1-3/+2
Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: Implement per vif frame registration APIAndrei Otcheretianski2-0/+25
Implement config_iface_filter() driver op. Currently support only probe request registration for p2p client vifs, by setting MAC_FILTER_IN_PROBE_REQUEST flag in MAC_CONTEXT_CMD. This is needed since WFDS spec and certification require a P2P client to be discoverable on its operating channel. Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: avoid read/write operations if the bus is deadEliad Peller2-0/+8
Recovery takes too much time if the bus is dead (each timeout is 2000ms, etc.). Explicitly skip fw dump in this case, as it will result in garbage data (and might take signifcant time) Signed-off-by: Eliad Peller <eliadx.peller@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: Add support for two scheduled scan plansAvraham Stern3-42/+87
Add support for two scan plans for scheduled scan. The first plan will run for a limited number of iterations, then the second plan will run infinitely. Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: let any command flag be passed to iwl_mvm_flushtx_path()Luca Coelho6-10/+8
Instead of only allowing the caller to decide whether the CMD_ASYNC flag is set, let it pass the entire flags bitmask. This allows more flexibility and will be needed when we call this function in the suspend flow (where other flags are needed). Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: Allow setting ctrl-chnl-position in FTM responderAssaf Krauss1-3/+22
This patch enables the debugfs user to configure an FTM responder with the appropriate control channel position. Signed-off-by: Assaf Krauss <assaf.krauss@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: use short timeouts in P2P low latency if supportedJohannes Berg3-7/+24
Those timeouts are used for AM-to-PSM transition. We already have those pairs defined for default and WOWLAN use cases. We expect that by using shorter threshold for low latency P2P, e.g. for Miracast video scenario, we might save a considerable amount of power. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Avri Altman <avri.altman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: use wowlan RX/TX timeouts in D0i3Johannes Berg1-10/+7
In "hostless" mode (D3 or D0i3) the same parameters were intended to be used, but the code doesn't do that properly. Fix it. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Avri Altman <avri.altman@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: correctly request DTS-measure for new cardsArik Nemtsov3-2/+74
Since the 8000 series, the DTS measurement request command has been changed. Use an ucode capability flag to determine which version is supported and send the extended command when needed. Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: pcie: fix (again) prepare card flowEmmanuel Grumbach1-8/+2
The hardware bug in the commit mentioned below forces us not to re-enable the clock gating in the Host Cluster. The impact on the power consumption is minimal and it allows the WAKE_ME interrupt to propagate. CC: <stable@vger.kernel.org> [4.1+] Fixes: c9fdec9f3970 ("iwlwifi: pcie: fix prepare card flow") Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: mvm: Dump FW's virtual image in the case of a NIC errorMatti Gottlieb2-0/+43
When paging is enabled the driver stores part of the FW's image in the DRAM. Dump FW's virtual image in the case of a NIC error. Signed-off-by: Golan Ben-Ami <golan.ben.ami@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-25iwlwifi: rs: Remove workaround that disables MIMO on P2PAlexander Bondar2-7/+0
Remove an old workaround that's no longer needed and enable MIMO on P2P interfaces. Signed-off-by: Alexander Bondar <alexander.bondar@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
2015-10-22Merge tag 'mac80211-next-for-davem-2015-10-21' of ↵David S. Miller2-2/+3
git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next Johannes Berg says: ==================== Here's another set of patches for the current cycle: * I merged net-next back to avoid a conflict with the * cfg80211 scheduled scan API extensions * preparations for better scan result timestamping * regulatory cleanups * mac80211 statistics cleanups * a few other small cleanups and fixes ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-20Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller8-20/+27
Conflicts: drivers/net/usb/asix_common.c net/ipv4/inet_connection_sock.c net/switchdev/switchdev.c In the inet_connection_sock.c case the request socket hashing scheme is completely different in net-next. The other two conflicts were overlapping changes. Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-13cfg80211: Add multiple scan plans for scheduled scanAvraham Stern2-2/+3
Add the option to configure multiple 'scan plans' for scheduled scan. Each 'scan plan' defines the number of scan cycles and the interval between scans. The scan plans are executed in the order they were configured. The last scan plan will always run infinitely and thus defines only the interval between scans. The maximum number of scan plans supported by the device and the maximum number of iterations in a single scan plan are advertised to userspace so it can configure the scan plans appropriately. When scheduled scan results are received there is no way to know which scan plan is being currently executed, so there is no way to know when the next scan iteration will start. This is not a problem, however. The scan start timestamp is only used for flushing old scan results, and there is no difference between flushing all results received until the end of the previous iteration or the start of the current one, since no results will be received in between. Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2015-10-12Merge tag 'wireless-drivers-next-for-davem-2015-10-09' of ↵David S. Miller38-717/+994
git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next Kalle Valo says: ==================== Major changes: iwlwifi * some debugfs improvements * fix signedness in beacon statistics * deinline some functions to reduce size when device tracing is enabled * filter beacons out in AP mode when no stations are associated * deprecate firmwares version -12 * fix a runtime PM vs. legacy suspend race * one-liner fix for a ToF bug * clean-ups in the rx code * small debugging improvement * fix WoWLAN with new firmware versions * more clean-ups towards multiple RX queues; * some rate scaling fixes and improvements; * some time-of-flight fixes; * other generic improvements and clean-ups; brcmfmac * rework code dealing with multiple interfaces * allow logging firmware console using debug level * support for BCM4350, BCM4365, and BCM4366 PCIE devices * fixed for legacy P2P and P2P device handling * correct set and get tx-power ath9k * add support for Outside Context of a BSS (OCB) mode mwifiex * add USB multichannel feature ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2015-10-05iwlwifi: mvm: add minimal multi-RXQ infrastructureJohannes Berg2-27/+83
Since the new multi-queue capability depends on a new firmware API, we can already add some code for it. If the new API is present, a new opmode ops struct is used that handles the new rx_rss method. For now, only restructure the RX handling to distinguish between the two. Future patches will convert the new infrastructure to actually use the new RX descriptor layout. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: size firmware flags memory correctlyJohannes Berg3-7/+20
Instead of relying on a hard-coded constant of a maximum of 64 API and capability bits, add a new enum value after the others that will then always track the number of used bits in the API/capabilities. We thus no longer need to maintain the maximum number, and on 32-bit platforms even (currently) reduce the number of bits kept in memory. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: make threshold temperatures unsignedJohannes Berg1-6/+6
There's no need to have negative threshold temperatures, so make them unsigned to avoid signedness warnings in debugfs. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: nvm: add nvm phy_sku section to debugfsMoshe Harel3-0/+8
The only NVM section not captured in debugfs. Signed-off-by: Moshe Harel <moshe.harel@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: fix signedness warnings in ToF debugfsJohannes Berg1-6/+10
Using an int* instead of u32* as the kstrtou32() output argument obviously results in signedness warnings, change that. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: rs: dynamically switch between 80MHz and 20MHz in some scenariosEyal Shapira2-0/+48
This is a tweak which has been shown to improve performance when moving away from the AP while working in 80Mhz. When RS decides to go down to 80MHz SISO MCS0 instead switch to 20MHz MCS4. Go back to 80MHz MCS1 if RS can sustain 20MHz MCS5. Signed-off-by: Eyal Shapira <eyalx.shapira@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: minor rx code cleanupJohannes Berg1-2/+2
Clean up variable initialisation slightly. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: remove IWL3165_UCODE_API_OK and _MINJohannes Berg1-7/+0
As the 3165 device uses the same firmware as 7265-D and currently all 7000 series (including 3160/3165) use the same API versions remove IWL3165_UCODE_API_OK and _MIN. We might have to put them back if firmware support ever splits, but in that case might also have to add a different MODULE_FIRMWARE statement. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: rs: fix success ratio comparison in rs_get_best_rateEyal Shapira1-2/+2
success_ratio is actually 128 * SR in percentage while IWL_MVM_RS_SR_NO_DECREASE is 85%. Fix this by using RS_PERCENT(). This bug caused the if branch to be always executed. This in turn led to always selecting a rate, following a column switch, in which the expected throughput would exceed the best expected current throughput. In some scenarios where the success ratio isn't >85% such a rate could be too aggressive leading us to avoid the new column. This has the potential of causing sub optimal performance. Reported-by: Moshe Harel <moshe.harel@intel.com> Signed-off-by: Eyal Shapira <eyalx.shapira@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: rs: minor indentation fixEyal Shapira1-2/+2
Indentation was off a bit. Fix it. Signed-off-by: Eyal Shapira <eyalx.shapira@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: rs: remove overflowing debug messageEyal Shapira1-1/+0
This message isn't very useful and creates clutter. Remove it. Signed-off-by: Eyal Shapira <eyalx.shapira@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: rs: improve rate debug messagesEyal Shapira1-9/+51
Pretty print the rate full details to ease debugging. Signed-off-by: Eyal Shapira <eyalx.shapira@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: stop using DEVICE_POWER_FLAGS_CAM_MSKJohannes Berg2-10/+4
The firmware has always treated these two bits to mean that powersave is enabled when POWER_SAVE_ENA is set and CAM is clear; it doesn't use them in any non-combined way. Therefore, it's pointless to send it two bits, and the API should be cleaned up. Prepare the driver by removing the CAM bit and using only POWER_SAVE_ENA to indicate whether PS is enabled or not. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: support enabling a queue with a given ssnLiad Kaufman3-7/+8
When enabling a queue, the default SSN is 0. Allow determining what that SSN should be, if required. This can happen, for example, if a queue gets reconfigured. Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: support using multiple ACs on single HW queueLiad Kaufman7-89/+249
"DQA" is shorthand for "dynamic queue allocation", with the idea of allocating queues per-RA/TID on-demand rather than using shared queues statically allocated per vif. The goal of this is to enable future features (like GO PM) and to improve performance measurements of TX traffic. When RA/TID streams can't be neatly sorted into different AC queues, DQA allows sharing queues for the same RA. This means that DQA allows different ACs may reach the same HW queue. Update the code to allow such queue sharing by having a mapping between the HW queue and the mac80211 queues using it (as this could be more than one queue). Signed-off-by: Liad Kaufman <liad.kaufman@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: transport: track number of allocated queuesJohannes Berg2-0/+6
As the transport will decide how many queues (and MSI-X vectors) to allocate, add a field to indicate that to the op-mode so it can size/allocate its own data structures appropriately. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: op-mode API: add rx_rss methodJohannes Berg1-1/+18
Upcoming hardware will have the ability to do L3 hashing for RSS, directing data packets (and perhaps some associated metadata and management notifications) to different MSI-X vectors. In this case, it makes no sense to go through the full RX dispatch since it's already known that only a subset of the possibilities can come in, requiring a new receive method. In addition this must know which queue the packet was received on. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: remove PHY RX from handlersJohannes Berg1-1/+3
Treat PHY RX specially, since it's actually pretty frequent, doesn't need all the notication etc. code, and will have a different handler in future hardware. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: Improve debugfs tof robustnessAssaf Krauss1-7/+9
Return a proper error when wrong parameters are passed to debugfs tof_range_request. Signed-off-by: Assaf Krauss <assaf.krauss@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: ToF - fill bssid of responder configurationGregory Greenman1-0/+1
The command needs to have the AP interfaces BSSID (which corresponds to its address). Signed-off-by: Gregory Greenman <gregory.greenman@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: Fix tof debugfs formats (dec vs. hex)Assaf Krauss1-19/+21
Make some input formats more natural, e.g. bandwidth and periods are more natural in decimal than in hexadecimal. Signed-off-by: Assaf Krauss <assaf.krauss@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: flush fw_dump_wk when mvm fails to startAndrei Otcheretianski1-0/+1
FW dump may be triggered when running init ucode, for example due to a sysassert. In this case fw_dump_wk may run after mvm is freed, resulting in a kernel panic. Fix it by flushing the work. Fixes: 01b988a708af ("iwlwifi: mvm: allow to collect debug data when restart is disabled") Cc: <stable@vger.kernel.org> [3.18+] Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: init card correctly on ctkill exit checkArik Nemtsov2-2/+7
During the CT-kill exit flow, the card is powered up and partially initialized to check if the temperature is already low enough. Unfortunately the init bails early because the CT-kill flag is set. Make the code bail early only for HW RF-kill, as was intended by the author. CT-kill is self-imposed and is not really RF-kill. Fixes: 31b8b343e019 ("iwlwifi: fix RFkill while calibrating") Cc: <stable@vger.kernel.org> [3.18+] Signed-off-by: Arik Nemtsov <arikx.nemtsov@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: pci: add a few more PCI subvendor IDs for the 7265 seriesLuca Coelho1-0/+5
Add 3 new subdevice IDs for the 0x095A device ID and 2 for the 0x095B device ID. Cc: <stable@vger.kernerl.org> [3.13+] Reported-by: Jeremy <jeremy.bomkamp@gmail.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: fix firmware filename for 3160Johannes Berg1-1/+1
The MODULE_FIRMWARE() for 3160 should be using the 7260 version as it's done in the device configuration struct instead of referencing IWL3160_UCODE_API_OK which doesn't even exist. Cc: <stable@vger.kernel.org> [3.8+] Reported-by: Hauke Mehrtens <hauke@hauke-m.de> Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: clear csa countdown when AP is stoppedAvraham Stern1-0/+1
The csa_countdown flag was not cleared when the AP is stopped. As a result, if the AP was stopped after csa_countdown had started, all the folowing channel switch commands would fail. Fix that by clearing the csa_countdown flag when the AP is stopped. Cc: <stable@vger.kernel.org> [3.17+] Signed-off-by: Avraham Stern <avraham.stern@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2015-10-05iwlwifi: mvm: fix D3 firmware PN programmingJohannes Berg1-6/+6
The code to send the RX PN data (for each TID) to the firmware has a devastating bug: it overwrites the data for TID 0 with all the TID data, leaving the remaining TIDs zeroed. This will allow replays to actually be accepted by the firmware, which could allow waking up the system. Cc: <stable@vger.kernel.org> [3.1+] Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Luca Coelho <luciano.coelho@intel.com>