aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/intel/iwlwifi/mvm/fw-api.h
AgeCommit message (Collapse)AuthorFilesLines
2019-01-29iwlwifi: mvm: add location APIsJohannes Berg1-0/+1
Add the location/time-of-flight/FTM APIs that we'll use in follow-up patches to implement FTM responder and initiator. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-01-29iwlwifi: remove TOF implementationJohannes Berg1-1/+2
This is an ancient (~2015) implementation that no longer matches the firmware in any way, and most likely never worked. Remove all of it so it can be reintroduced properly. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2018-08-31iwlwifi: remove all occurrences of the FSF address paragraphLuca Coelho1-5/+0
The Free Software Foundation address is superfluous and causes checkpatch to issue a warning when present. Remove all paragraphs with FSF's address to prevent that. Signed-off-by: Luca Coelho <[email protected]>
2017-08-09iwlwifi: mvm: use firmware LED command where applicableJohannes Berg1-0/+1
On devices starting from 8000 series, the host can no longer toggle the LED through the CSR_LED_REG register, but must do it via the firmware instead. Add support for this. Note that this means that the LED cannot be turned on while the firmware is off, so using an arbitrary LED trigger may not work as expected. Fixes: 503ab8c56ca0 ("iwlwifi: Add 8000 HW family support") Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-08-01iwlwifi: reorganize firmware APIJohannes Berg1-2687/+27
Apart from DVM, all firmware uses the same base API, and there's code outside iwlmvm that needs to interact with it. Reflect this in the source better and reorganize the firmware API to a new fw/api/ directory. While at it, split the already pretty large fw-api.h file into a number of smaller files, going from almost 3k lines in there to a maximum number of lines less than 1k. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-08-01iwlwifi: refactor shared mem parsingJohannes Berg1-87/+0
Refactor the shared memory command parsing into common code. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-08-01iwlwifi: refactor out paging codeJohannes Berg1-44/+0
Refactor the paging code from mvm to be used by different opmodes. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-29iwlwifi: mvm: update rx statistics cmd apiLiad Kaufman1-1/+5
The API has changed - update the code. Signed-off-by: Liad Kaufman <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-29iwlwifi: mvm: remove version 2 of paging commandJohannes Berg1-22/+3
Only a000-series devices were going to use this, but actually initialize using the context info, which includes paging, so this code is never invoked; remove it. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-29iwlwifi: mvm: rename iwl_shared_mem_cfg_v1 to the correct _v2Johannes Berg1-3/+3
This structure represents V2, V1 has the three last fields missing. Rename it to be more accurate. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-29iwlwifi: mvm: fix a bunch of kernel-doc warningsJohannes Berg1-8/+18
Fix the kernel-doc, and remove some fields even the firmware doesn't use in ToF, RX, scan, station and generic FW APIS. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-29iwlwifi: mvm: add documentation for all command IDsJohannes Berg1-9/+267
Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-29iwlwifi: mvm: remove various unused command IDs/structsJohannes Berg1-28/+0
Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-29iwlwifi: mvm: fix various "Excess ... description" kernel-doc warningsJohannes Berg1-3/+2
Fix various "Excess struct/union/enum/typedef member '...' description in '...'" warnings from kernel-doc, mostly caused by typos. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-29iwlwifi: mvm: remove some CamelCase from firmware APIJohannes Berg1-2/+2
Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-23iwlwifi: mvm: fix typo in CTDP_CMD_OPERATION_REPORT descriptionChaya Rachel Ivgi1-1/+1
Signed-off-by: Chaya Rachel Ivgi <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-23iwlwifi: mvm: add documentation for enum iwl_debug_cmdsJohannes Berg1-0/+17
Add kernel-doc documentation for enum iwl_debug_cmds, linking the structures used by the commands. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-23iwlwifi: mvm: disentangle union in TX status structJohannes Berg1-1/+2
This improves documentation, since kernel-doc can't deal with the union well. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-23iwlwifi: mvm: docs: fix enum link, provide TX response linkJohannes Berg1-1/+2
Fix the enum link by adding the missing & and provide the link to the TX response documentation. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-05iwlwifi: mvm: remove SCAN_GROUPJohannes Berg1-1/+0
The firmware no longer uses this command group, so remove it from the driver as well. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-05iwlwifi: mvm: link to TX commands in documentationJohannes Berg1-1/+3
Link from the TX_CMD enum value to the TX command structs. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-05iwlwifi: mvm: document structures used for BEACON_TEMPLATE_CMDJohannes Berg1-0/+6
Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-05iwlwifi: mvm: link queue cmd docs to A000 command structsJohannes Berg1-1/+3
Document which structures are used with the command for the A000 hardware flavour. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-05iwlwifi: mvm: document RX structuresJohannes Berg1-0/+8
Document the structures used in RX and link them to the command ID. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: remove unused REPLY_MAXJohannes Berg1-2/+0
This value is unused, and there's no reason we'd ever use it. Just remove it. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: document structures used by commandsJohannes Berg1-11/+207
Add documentation to a lot of command IDs that links to the appropriate structure(s) used with those IDs. In one case, actually add and use a new struct for that purpose. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: create/name various enumsJohannes Berg1-14/+47
Some values should be in enums so documentation can refer to them, some values should be named for the same reason. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: disentangle binding command versionsJohannes Berg1-2/+21
The comments/size of the different binding commands get lost in documentation, so introduce two different command structs that can be used there. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: add documentation links to various fieldsJohannes Berg1-12/+19
Link various fields to the documentation of the enums that define their values. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: fix some kernel-docJohannes Berg1-30/+32
This mostly fixes missing tags/struct names, but also some other things. Lots of issues remain though. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: disentangle paging command structsJohannes Berg1-7/+22
Instead of using a union and hard-coding the size difference, declare both command structs properly, use a union on the stack to build them and the right sizeof() for the size. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: use u8 for reserved fieldsJohannes Berg1-2/+2
There's no saying what kind of type a reserved field will get in the future, so use u8 arrays to reserve space. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: fix MCC endianness bugJohannes Berg1-1/+1
Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: document which group enums are used with which group IDJohannes Berg1-3/+24
Make it explicit which command definition enum is supposed to be used with which command group, rather than relying on being able to figure it out by name. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-06-02iwlwifi: mvm: support getting nvm data from firmwareSara Sharon1-0/+77
This API replaces the complex NVM parsing of the iwlwifi module. Instead, we get all needed data from firmware. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-04-19iwlwifi: mvm: support changing band for phy contextSara Sharon1-1/+1
In a000 CDB firmware, we cannot update phy context to a different band - we must first remove it and add it again. Support this flow for all a000 devices since we may have various combinations that cause us to fail regardless if CDB is active. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-04-19iwlwifi: mvm: support init extended commandSara Sharon1-0/+23
When we load firmware in extended mode (as we do by default for now) driver should send a command what kind of commands ucode should stop and wait for before proceeding with phy calibrations. Support this command. Currently we only do NVM access - so mark this bit only. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-04-19iwlwifi: mvm: add GEO_TX_POWER_LIMIT cmd for geographic tx power tableHaim Dreyfuss1-0/+1
To utilize the maximum allowed tx power, an additional table was added to the BIOS. The table consists of up to seven different regions (currently only three are in use). Each region contains per band: 1. Maximum allowed tx power on the band. 2. Tx power offset for chain A. 3. Tx power offset for chain B. On init flow driver reads this table by means of ACPI and passes it to the firmware with GEO_TX_POWER_LIMIT cmd. The firmware will use this table to enhance tx power with the offset in the relevant table as well as verifying it does not violate the maximum allowed tx power. Signed-off-by: Haim Dreyfuss <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-04-19iwlwifi: mvm: support change to a000 smem APISara Sharon1-6/+35
API was changed once more to support 2 LMACs. Adapt to change while preserving current functionality. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-04-11iwlwifi: mvm: support MFUART dump in case of MFUART assertGolan Ben-Ami1-3/+23
In case of a MFUART assert, get a notification from the fw that consists of the assert id and debug data. The notification may be divided to multiple chunks, depending on the size of the debug data sent to the driver, which would be up to 1KB. Get the notification, and if the debug info flag is enabled, print the debug data to the dmesg. Signed-off-by: Golan Ben-Ami <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-04-11iwlwifi: mvm: support new binding APISara Sharon1-3/+11
For a000 devices the binding API needs to include relevant lmac ID - support the new API. The new API should be used regardless if the device had CDB or not. If there is no actual CDB support the binding is bound to first lmac regardless of the band. There are some functionality changes in binding restrictions and quota allocations that will be handled in future patches. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-02-03iwlwifi: mvm: support new alive notificationSara Sharon1-54/+18
Support getting alive from two LMACs and dumping debug data from both. Deprecate older alive notifications no one is using. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-02-03iwlwifi: mvm: cleanup incorrect and redundant defineSara Sharon1-1/+0
Currently we have up to 3 phy contexts - defined by NUM_PHY_CTX. However - some code paths validate the ID by using MAX_PHYS define which is set to 4. While there is no harm it is incorrect - since the maximum is 3. Remove the define and use the correct one. Cleanup the code a bit while at it. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-02-03iwlwifi: mvm: support v2 of mfuart load notificationGolan Ben-Ami1-1/+4
Add to the v1 of the mfuart loading notification, the size of the mfuart image, and write it to dmesg once the notification is received. Signed-off-by: Golan Ben-Ami <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-02-03iwlwifi: mvm: support unification of INIT and RT imagesSara Sharon1-0/+12
For a000 devices the INIT and RT images are unified to one image. The changes in the flow are the following: * Driver load only RT firmware - meaning that the nvm access command will be done in the RT image load flow. * A new command (NVM_ACCESS_COMPLETE) now signals to the FW that the driver is done accessing the NVM and FW can proceed with phy calibrations. * Phy DB is no longer sent from INIT FW to be restored by driver for the RT FW - all the phy DB is now internal to the FW. INIT complete will now follow the NVM access command, without phy DB calls before. * Paging command is sent earlier in the flow before NVM access to enable a complete load of FW. * caution must be care when restart is called since we may have not completed init flow even though we are in RT firmware. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2017-01-26iwlwifi: mvm: support version 2 of stored beacon notificationSara Sharon1-3/+3
For 9000 devices withg upload, FW cannot send the entire phy flags, and will send only the band - which is what we really care about anyway. Change is backward compatible. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2016-10-19iwlwifi: mvm: use firmware station PM notification for AP_LINK_PSJohannes Berg1-0/+1
When using RSS on 9000 series devices, we can't rely on processing the received frames for station powersave handling, since they could be processed on different CPUs and out of order. In order to still manage the powersave of stations, the firmware sends a notification on sleep->wake, wake->sleep and - for U-APSD - frames received with PM while already sleeping (with the TID.) With this, the driver can set AP_LINK_PS, which is required for real parallel RX. In addition, this requires checking for PS-Poll frames and calling ieee80211_sta_pspoll() appropriately. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Emmanuel Grumbach <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2016-09-19iwlwifi: mvm: set HCMD_NAME for PHY_DB as wellSara Sharon1-1/+1
Currently it is logged as UNKNOWN. Also, 0x6c seems to be the permanent ID for this command, remove incorrect comment and uncomment the command from the commands list. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2016-09-19iwlwifi: mvm: Add mem debugfs entryIdo Yariv1-0/+50
In order to access cached/paged memory, there are a couple of firmware commands (one for UMAC and one for LMAC) that let the host access memory and registers indirectly. Since this is done by the firmware on behalf of the host, even if memory is paged out or cached, the host will retrieve the memory as the firmware sees it (paged out memory will get paged in). Export this mechanism via a debugfs entry for both read and write access. WARNING: This mechanism has no protections at all. Invalid addresses may crash or hang the firmware. Writing to arbitrary memory also comes with no guarantees. Signed-off-by: Ido Yariv <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2016-09-15iwlwifi: mvm: support new shared memory config APISara Sharon1-3/+19
In a000 devices we have 15 fifos, so in the shared memory config the number of tx fifos in the array was changed accordingly. As it is in the middle of the struct, the parsing code needs to be duplicated. To minimize the duplication, do not save variables we never actually use. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>