summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/iwlwifi/mvm
AgeCommit message (Collapse)AuthorFilesLines
2013-04-03iwlwifi: mvm: set keepalive period regardless of PM stateAlexander Bondar2-3/+11
The firmware starts sending nulldata frames for keepalive immediately after association, regardless of power management state. The driver thus needs to configure keep alive period unconditionally. Signed-off-by: Alexander Bondar <alexander.bondar@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-04-03iwlwifi: mvm: always send power table commandAlexander Bondar1-14/+12
The driver distinguishes between power management and device's power down enablement. Power management enablement depends both on driver's module power parameters and mac80211 decision. The device's power down depends only on driver's module power parameters. Change the driver to always send Power Table command to enable or disable both power management and device's power down. Signed-off-by: Alexander Bondar <alexander.bondar@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-04-03iwlwifi: mvm: Fix active-to-powersave transition time unitsAlexander Bondar1-4/+4
Active to power save mode transition time for TX/RX in the power table command is in microseconds, fix the units in the driver. Signed-off-by: Alexander Bondar <alexander.bondar@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-04-03iwlwifi: mvm: don't disable power management due to P2P deviceAlexander Bondar2-5/+17
Currently power management is supported only when only a single virtual interface is present. The driver verifies number of created interfaces and disables power management when multiple interfaces present. However, this rule does not extend to a P2P device that is handled differently in the firmware. If a P2P device is added power management can remain enabled. Signed-off-by: Alexander Bondar <alexander.bondar@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-04-03iwlwifi: mvm: Rename some power management definitions and methodsAlexander Bondar2-7/+8
Replace SLEEP_OVER_DTIM by SKIP_OVER_DTIM. Add iwl_mvm prefix to a function name. Signed-off-by: Alexander Bondar <alexander.bondar@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-04-03iwlwifi: mvm: downgrade to old power management APIAlexander Bondar2-67/+27
Current available FW still doesn't support new PM API. Therefore, to enable basic power management with the existing firmware, change the API in the driver back to the API used in the current firmware. Signed-off-by: Alexander Bondar <alexander.bondar@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-04-03iwlwifi: mvm: remove BT Coex constraints upon roaming to A bandEmmanuel Grumbach3-17/+52
When we roam to A band, we don't need to constraint WiFi any more since it is operating on a different band. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-04-03iwlwifi: mvm: implement reduced Tx powerEmmanuel Grumbach5-38/+283
This allows to have better wifi TPT when BT is active under good RSSI conditions. Wifi will have better chance to send Acks and Cts even if BT is active. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-04-03iwlwifi: mvm: add per-interface debugfs with mac_params fileJohannes Berg3-2/+124
Use the per-interface debugfs infrastructure to create a directory and symlink, and add a file containing debug data related to each virtual interface. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-26iwlwifi: mvm: split long debug printEmmanuel Grumbach1-4/+6
This caused issues with tracing as it's longer than the buffer size used there. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-26iwlwifi: mvm: ignore bt_ch_announce module parameterEmmanuel Grumbach1-2/+1
This module parameter isn't and won't be used. So ignore its value and set BT_CH_ANNOUNCE unconditionally. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: Add support for different ROC typesIlan Peer3-17/+24
Schedule different time event based on the ROC type Signed-off-by: Ilan Peer <ilan.peer@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20Merge remote-tracking branch 'wireless-next/master' into iwlwifi-nextJohannes Berg3-6/+7
2013-03-20iwlwifi: mvm: Increase the max remain on channel timeIlan Peer1-1/+1
Increase the maximal remain on channel time as longer remain on channel requests are handled by the FW using fragmented time events. This reduces the number of user/kernel space iterations during flows such as p2p_listen. In addition it is currently required for flows which require longer duration such as p2p_sd. Signed-off-by: Ilan Peer <ilan.peer@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: fix WoWLAN RF-kill bugJohannes Berg1-7/+3
The RF-kill wakeup trigger flag is set in the wrong command, which means it won't work. Also fix the comment in the TCP wakeup trigger code -- the firmware was changed to look at all the different trigger flags. Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: tune the move to static SMPS due to BT loadEmmanuel Grumbach1-1/+3
We should disable MIMO only if bt_traffic_load goes up to 3. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: take the valid_{rx,tx}_ant from the TLVEmmanuel Grumbach4-11/+10
This is the right source of information for the valid Tx antennas, not the NVM. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: take the radio type / step / dash from TLVsEmmanuel Grumbach1-16/+6
This data should taken from TLVs and not from the NVM. This is true for the value written in CSR_HW_IF_CONFIG_REG too. Also, no need to set the CSR_HW_IF_CONFIG_REG_BIT_MAC_SI bit for 7000 devices which are the only devices currently supported. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: specify filter flags in monitor modeJohannes Berg1-1/+6
In firmware "listener" (monitor) mode, we still need to open up the filters with the filter flags to receive all frames. Reviewed-by: Ilan Peer <ilan.peer@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: print the flags in ALIVE notificationEmmanuel Grumbach1-2/+3
This has valuable data about RFkill state seen from the fw side. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: Fix quota handling for monitor interfaceIlan Peer3-3/+9
1. Quota for the monitor interface should be added only if there is a channel context assigned to the interface. 2. In the unassign channel context flow, need to remove the quota for the monitor interface binding, before unbinding. Signed-off-by: Ilan Peer <ilan.peer@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: Remove obsolete queue definitionsIlan Peer5-14/+10
Signed-off-by: Ilan Peer <ilan.peer@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: don't support multi-channel inhibitionEmmanuel Grumbach1-2/+1
This feature is not implemented yet in firmware. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: fix the {ack,cts}_kill_mskEmmanuel Grumbach1-7/+7
The masks were wrong. They should be 0xffffffff when SCO, HID or SNIFF profiles are used. They should be 0xffff0000 in any other case (default) to get a bit more throughput when the BT profile allows for it. Fix a debug print on the way. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: Add beacon notification handlerIlan Peer5-0/+31
Mostly for debugging purposes Signed-off-by: Ilan Peer <ilan.peer@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: suppress key error messages in AP modeJohannes Berg1-0/+13
In AP mode, don't attempt to program GTKs into the device, they're used for TX only so not needed and programming them causes error messages. Also, in this case and if key programming fails, avoid trying to remove the key that isn't present later. Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-20iwlwifi: mvm: MVM op_mode is supported on 7000 onlyEmmanuel Grumbach5-162/+38
The code removed in this patch was used for bring up on older NICs. No MVM capable fw will ever be released for older NICs, so remove that code. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-08Merge branch 'for-john' of ↵John W. Linville33-267/+1504
git://git.kernel.org/pub/scm/linux/kernel/git/iwlwifi/iwlwifi-next
2013-03-06iwlwifi: mvm: the SCD byte count is a TLV flagEmmanuel Grumbach1-2/+1
The SCD byte count layout is decided by the configuration done in fw, it is then logical to export it as a TLV flag and not per HW SKU. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: move firmware restart debugfs hook to op_modeEmmanuel Grumbach1-0/+24
This allows to test fw restart flow. The hook in transport layer doesn't really make the fw assert. Moving this hook to the op_mode allows to use the fw API to actually send a host command that will make the fw assert. Change the restart_fw module parameter to be a boolean on the way. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: update firmware API - MAC ID in RXEmmanuel Grumbach1-1/+2
The firmware tells the driver to what MACs the received frame belongs (based on the time slot in which it was received). Note that there can be several MACs if they share the same binding. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: export last bt_notif through debugfsEmmanuel Grumbach3-0/+104
This will allow to track how BT core updates the driver. This is required to debug the BT Coexistence mechanism. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: update SMPS when BT gets activeEmmanuel Grumbach1-0/+52
When BT traffic load gets higher, we want to avoid using the shared antenna. In order to do so, we need to tell the AP that we don't support MIMO any more, or at least not all the time: in short, use the SMPS to achieve this. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: handle BT-coex notificationEmmanuel Grumbach3-0/+58
The BT-Coex notification is sent by the fw when there are updates wrt. BT activity. Driver action might be taken based on the info in this notification. For now, update the Ack/Cts_kill_msk if HID / SCO / A2DP profiles are active. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: begin basic BT-Coex implementationEmmanuel Grumbach4-1/+259
Send the PRIO table before the calibrations. This table tells the fw what priority to give to what (WiFi / BT) according to events. Send a hardcoded BT_COEX command to the fw to enable basic BT coexistence. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: add BT Coex FW APIEmmanuel Grumbach3-0/+330
This is the API to tell the fw to handle the BT Coexistence. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: add CARD_STATE_NOTIFICATION to the cmd stringsEmmanuel Grumbach1-0/+1
Then the transport can print it nicely in its debug prints. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: Change NVM default section read sizeDor Shaish1-3/+6
Signed-off-by: Dor Shaish <dor.shaish@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: don't read system time when modifying AP/GO MACJohannes Berg2-7/+20
When modifying a MAC, we update its beacon system time which is taken as a base to calculate TBTT. The firmware doesn't use the new timestamp because the time is never used after the MAC and broadcast station were added, but it is safer to not rely on this and avoids the overhead of reading the register every time the MAC is updated. Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Reviewed-by: Ilan Peer <ilan.peer@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: set up initial SMPS/NSS station infoJohannes Berg1-2/+49
When a station is added, we need to tell the firmware what the SMPS settings and number of streams are. After having the initial data, the firmware will track future changes by itself. Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: implement remote wakeJohannes Berg3-1/+334
With remote wake, the firmware creates a TCP connection and sends some configurable data on it, until a special TCP data packet from the server is received that triggers a wakeup. The configuration is a bit tricky because it is based on packet pattern matching but this is hidden in the driver and the exposed API in cfg80211 is just based on the required TCP connection parameters. Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: convert to use simple_open()Wei Yongjun1-9/+3
This removes an open coded simple_open() function and replaces file operations references to the function with simple_open() instead. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: support IEEE80211_AMPDU_TX_STOP_FLUSHEmmanuel Grumbach3-1/+33
mac80211 tells us when we need to dump the frames from the AGG queue instead of releasing them as single MPDUs. Being able to differentiate between the different cases (IEEE80211_AMPDU_TX_STOP_*) allows us to handle races better. When the station is removed, mac80211 asks to flush and removes the station right away. This allows to avoid a case where we still have frames in AGG queues, but the station has been remove already. Note that we can have frames on the shared queues, but this is not a problem: the station in the fw will be kept until all the frames on the shared queues have been drained. AGG queues are a special case since they are dynamically allocated. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: Add support for additional addressesIlan Peer2-6/+10
Use the number of addresses (max 5) from the NVM instead of limiting to 2 artificially. Signed-off-by: Ilan Peer <ilan.peer@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: disable greenfield transmissions as a workaroundBeni Lev1-6/+8
There's a bug that causes the rate scaling to get stuck when it has to use single-stream rates with a peer that can do GF and SGI; the two are incompatible so we can't use them together, but that causes the algorithm to not work at all, it always rejects updates. Disable greenfield for now to prevent that problem. The MVM driver currently only works on devices that don't support greenfield anyway, but better be safe and not allow us to forget about this. Signed-off-by: Beni Lev <beni.lev@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: Update MAC context filter flagsIlan Peer1-1/+13
1. For P2P Device filter in only probe requests. 2. For station mode filter in all group cast frames, and in addition beacons as long as we are not associated. 3. For AP/GO filter in all group cast and in addition probe requests. Signed-off-by: Ilan Peer <ilan.peer@intel.com> Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: don't use cts to selfDor Shaish1-2/+2
The current fw doesn't currently support cts to self. There is a bug in the fw that prevents us from using cts to self. Use full protection (including RTS) for now. Signed-off-by: Dor Shaish <dor.shaish@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: free AGG queue when we STA is removedEmmanuel Grumbach1-3/+3
When we stop an AGG session, we need to look at the sequence numbers in in the private area of the ieee80211_sta struct. This allows us to know is the queue is empty. To get access to this private area, we use fw_id_to_mac_id that maps sta_id (index of the STA in fw table) to ieee80211_sta. When the STA exists in fw, but not in mac80211, we set an ERR ptr in fw_id_to_mac_id. But if we first set an ERR ptr to fw_id_to_mac_id, and only then flush the queues, then we won't be able to access the sequence numbers in ieee80211_sta from the reclaim flow. This means that we will never be able to release an AGG queue when a station is deleted. So first, flush the queue. That will let the reclaim flow call iwl_mvm_check_ratid_empty which will disable the AGG queue as needed, and only then, remove the mapping in fw_id_to_mac_id. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: mvm: respect disable Tx AGG parameterEmmanuel Grumbach1-0/+4
We didn't check that we allowed to start Tx AGG. This can possibly be avoided by a module parameter. Fix that. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2013-03-06iwlwifi: a few fixes in licenseEmmanuel Grumbach29-29/+29
7000.c was released as GPL only by mistake: it should be dual licensed - GPL / BSD. The file that contains the license in the kernel is COPYING and not LICENSE.GPL. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>