summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/mvm/phy-ctxt.c
Commit message (Collapse)AuthorAgeFilesLines
* iwlwifi: mvm: don't allow diversity if BT Coex / TT forbid itEmmanuel Grumbach2014-05-191-2/+1
| | | | | | | | | | We should not allow diversity when BT Coex needs the second antenna. Thermal Throttling can also request to stop using the second antenna. Honour those requests. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Reviewed-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
* iwlwifi: mvm: enable RX chain diversity if neededJohannes Berg2014-05-131-0/+13
| | | | | | | | | In some situations (see comment) it makes sense to enable both chains (if available) to get better throughput by having chain diversity available. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
* iwlwifi: remove CMD_SYNCEmmanuel Grumbach2014-05-131-1/+1
| | | | | | | | | CMD_SYNC is really 0 which is confusing: if (cmd.flags & CMD_SYNC) is always false. Fix this by simply removing its definition. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
* iwlwifi: mvm: remove useless variableJohannes Berg2014-05-061-6/+3
| | | | | | | | There's no need to use a variable just to return the result of another function call at the end of a function, remove it. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
* iwlwifi: remove iwl_fw_valid_(tx|rx)_ant inlinesJohannes Berg2014-02-131-2/+2
| | | | | | | | | These inlines are pretty pointless now as they just return a fixed struct value, remove them - the code even gets shorter. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Reviewed-by: Eran Harary <eran.harary@intel.com> Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
* iwlwifi: Update Copyright to 2014Emmanuel Grumbach2013-12-311-2/+2
| | | | | | Happy new year! Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
* iwlwifi: mvm: implement D3 testingJohannes Berg2013-05-291-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For testing the D3 (WoWLAN) firmware, it is useful to be able to run the firmware with instrumentation while the host isn't sleeping and can poke at the firmware debug logging etc. Implement this by a debugfs file. When the file is opened the D3 firmware is loaded and all regular commands are blocked. While the file is being read, poll the firmware's PME status flag and report EOF once it changes to non-zero. When it is closed, do (most of) the resume processing. This lets a user just "cat" the file. Pressing Ctrl-C to kill the cat process will resume the firwmare as though the platform resumed for non-wireless reason and when the firmware wants to wake up reading from the file automatically completes. Unlike in real suspend, only disable interrupts and don't reset the TX/RX hardware while in the test mode. This is a workaround for some interrupt problems that happen only when the PCIe link isn't fully reset (presumably by changing the PCI config space registers which the core PCI code does.) Note that while regular operations are blocked from sending commands to the firmware, they could still be made and cause strange mac80211 issues. Therefore, while using this testing feature you need to be careful to not try to disconnect, roam or similar, and will see warnings for such attempts. Als note that this requires an upcoming firmware change to tell the driver the location of the PME status flag in SRAM. D3 test will fail if the firmware doesn't report the pointer. Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* iwlwifi: mvm: sanity check context in iwl_mvm_phy_ctxt_unref()Johannes Berg2013-05-141-0/+4
| | | | | | | | | | In some botched (!) restart scenarios we seem to get here with a NULL PHY context, so warn and exit instead of crashing. Reported-by: Omer Kremer <omerx.kremer@intel.com> 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>
* iwlwifi: mvm: Change PHY context handlingIlan Peer2013-05-131-32/+0
| | | | | | | | | | | | | | | 1. All the phy contexts are added immediately after the firmware is loaded and up. 2. Whenever a PHY context needs to be used, its reference counter is incremented and the PHY context is being configured to the appropriate configuration. 3. When a PHY context is no longer needed, its reference count is decremented. 4. PHY contexts are never removed. 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>
* iwlwifi: mvm: Loosen the channel context/phy context couplingIlan Peer2013-05-131-39/+34
| | | | | | | | | | | | | | | | In current implementation, the phy context is tightly coupled with the channel context. This complicates the possibility of using the same phy context for both netdev interfaces and the P2P Device interface. To loosen this coupling: 1. Manage all the phy contexts in the mvm op mode, and only save the phy context id in the chanctx memory. 2. Reference count the phy contexts and free them only when they are not longer used (both by mac80211 and P2P Device). 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>
* iwlwifi: mvm: remove TODO which has been addressedEmmanuel Grumbach2013-04-161-5/+0
| | | | | | | | Chain noise is done in the firmware and Bluetooth Coexistence is implemented now. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
* iwlwifi: mvm: take the valid_{rx,tx}_ant from the TLVEmmanuel Grumbach2013-03-201-4/+3
| | | | | | | | 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>
* iwlwifi: a few fixes in licenseEmmanuel Grumbach2013-03-061-1/+1
| | | | | | | | | | 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>
* iwlwifi: add the MVM driverJohannes Berg2013-02-011-0/+292
Newer firmware revisions have a completely new firmware API. This is the new driver for this new API. I've listed the people who directly contributed code, but many others from various teams have contributed in other ways. Cc: Alexander Bondar <alexander.bondar@intel.com> Cc: Amit Beka <amit.beka@intel.com> Cc: Amnon Paz <amnonx.paz@intel.com> Cc: Assaf Krauss <assaf.krauss@intel.com> Cc: David Spinadel <david.spinadel@intel.com> Cc: Dor Shaish <dor.shaish@intel.com> Cc: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Cc: Eytan Lifshitz <eytan.lifshitz@intel.com> Cc: Ilan Peer <ilan.peer@intel.com> Signed-off-by: Johannes Berg <johannes.berg@intel.com>
OpenPOWER on IntegriCloud