aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/wireless/intel/iwlwifi/fw
AgeCommit message (Collapse)AuthorFilesLines
2019-04-18Merge tag 'wireless-drivers-next-for-davem-2019-04-18' of ↵David S. Miller10-301/+618
git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next Kalle Valo says: ==================== wireless-drivers-next patches for 5.2 Nothing really special standing out this time, iwlwifi being the most active driver. Major changes: iwlwifi * send NO_DATA events so they can be captured in radiotap * support for multiple BSSID * support for some new FW API versions * support new hardware * debugfs cleanups by Greg-KH qtnfmac * allow each MAC to specify its own regulatory rules ==================== Signed-off-by: David S. Miller <[email protected]>
2019-04-03iwlwifi: mvm: support HE context cmd API changeSara Sharon2-1/+79
Support API change to pass all mbssid parameters to the firmware. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg: fill radio registers data regardless of fifos data dumpingShahar S Matityahu1-2/+3
The driver calculates memory regions dump size, allocate memory and fills the data. The driver fills the radio registers data only if the memory size of the fifos is greater then zero, so in case the user masked out the fifos from the dump, the driver will skip filling the radio register data. Solve this by checking filling radio registers data independently from fifos data. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: apply rx fifo offset after reading the region registersShahar S Matityahu1-2/+6
The region registers comes in abolute value so read the registers before applying the rx fifo offset. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: remove redundant type argument from iwl_dump_ini_memShahar S Matityahu1-16/+12
Since iwl_dump_ini_mem receive struct iwl_fw_ini_region_cfg which holds the region type, there is no point to pass the type separately. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: remove redundant curly brackets from trigger collection flowShahar S Matityahu1-4/+2
remove redundant curly brackets from iwl_fw_ini_dump_trigger and iwl_fw_ini_get_trigger_len Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: add monitor header to smem monitorShahar S Matityahu2-19/+88
Add write pointer and cycle count registers to smem monitor header. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: fix the dram monitor header sizeShahar S Matityahu1-1/+2
Add sizeof(struct iwl_fw_ini_error_dump_range) to the header of the dram monitor. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: change memory range base address to u64Shahar S Matityahu2-8/+8
AX210 devices will use u64 for the base address to the DRAM monitor buffer. To support this, change the structure for all device families so both address sizes fit. Also move range_data_size to the top of the struct to ease the parsing of the memory range. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: add registers addresses in fifo dumpShahar S Matityahu2-16/+45
Add to the fifo dump the registers addresses. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: add region id to the region dumpShahar S Matityahu2-0/+3
Add the region id of the collected memory to the header of the memory region. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: add version to dump headerShahar S Matityahu2-0/+11
Add version to dump header to allow future changes of the dump struct, once the ini debug flow becomes operational, without breaking backwards compatibility. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: add memory offset to the base address of a memory regionShahar S Matityahu1-15/+11
Add the offset to the base address of a memory region to show the actual addresses being read. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: fix iwl_dump_ini_dev_mem_iter memory base addressShahar S Matityahu1-2/+2
The driver is using range->start_addr before assigning it a value. Set value into range->start_addr and then use it. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: enforce always on domain checkingShahar S Matityahu1-0/+8
Enforce domain checking before sending host commands and collecting memory regions. Currently the driver supports always on domain only. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-04-03iwlwifi: dbg_ini: support HW error triggerShahar S Matityahu1-0/+10
Differentiate between SW and HW error interrupts and support ini HW error trigger. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: dbg_ini: align to FW api version 1Shahar S Matityahu1-59/+118
align to ini debug struct version 1 and enforce version checking. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: dbg_ini: separate between ini and legacy dump flowsShahar S Matityahu3-88/+119
Separate between ini and legacy dump flows to allow adding ini triggers that are not supported in the legacy flow and to increase readabilty. iwl_fw_dbg_ini_collect function is now called with legacy trigger id and _iwl_fw_dbg_ini_collect is called with ini trigger id. Also make the actual dumping function static so that any dump collection will go through iwl_fw_dbg_collect_sync. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: dbg: add DRAM monitor support for AX210 device familyShahar S Matityahu1-1/+5
Allows to perform monitor dumping on AX210 device family Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: pcie: switch to correct RBD/CD layout for 22560Johannes Berg1-65/+2
The layout of the RBD (receive buffer descriptor) isn't quite right, the hardware ended up being implemented differently. Switch to the correct RBD layout. While at it, remove the now useless extra defines. Also, switch the CD (completion descriptor) to the right format, which is basically just a code cleanup because the only field we really used (rbid) is still in the same place. We may need fragmentation later if we ever want to use it. Signed-off-by: Johannes Berg <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: mvm: Support new format of SCAN_OFFLOAD_PROFILES_QUERY_RSPIlan Peer2-4/+54
Newer FWs use a new format of the SCAN_OFFLOAD_PROFILES_QUERY_RSP, which now supports indicating match on an higher number of channels. Modify the code to support both the old format and the newer one, based on a FW TLV. Signed-off-by: Ilan Peer <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: support new NVM response APIShaul Triebitz2-6/+36
Support REGULATORY_NVM_GET_INFO_RSP_API_S_VER_4. This API adds the new 6-7GHz channels. Signed-off-by: Shaul Triebitz <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: mvm: track CSA beaconsSara Sharon1-0/+2
Send to FW modify command for every beacon we receive during channel switch. FW will track the count, and make sure the event is scheduled in time even if AP changed count. Signed-off-by: Sara Sharon <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: use sync nmi in case of init flow failureShahar S Matityahu2-24/+3
In case of alive interrupt timeout or any failure in the init flow the driver generates FW nmi. The driver assumes that the nmi will generate SW interrupt. This assumption does not hold and leads to faulty behavior in the recovery flow. Solve this by using sync nmi, this way, even if the driver does not receive SW interrupt, it still starts the recovery flow. Also remove the wait queue from iwl_fwrt_stop_device since the driver is handling the SW interrupt synchronously. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: dbg_ini: fix bad dump size calculationShahar S Matityahu1-3/+3
The driver initiates the size value with the size of the struct and then adds the size of the data and checks if the size is zero so size can not be equal to zero. Solve this by getting the data size, check that it is not equal to zero and only then add the struct size. Signed-off-by: Shahar S Matityahu <[email protected]> Fixes: 7a14c23dcdee ("iwlwifi: dbg: dump data according to the new ini TLVs") Signed-off-by: Luca Coelho <[email protected]>
2019-03-22iwlwifi: dbg_ini: in case of region dump failure set memory to 0Shahar S Matityahu1-0/+2
In case the driver fails to dump a memory region, and this is the last region, then partial region would be extracted. Solve this by setting the data to zero in case of failure. This will cause dump to be a list of consecutive successful memory regions and trailing zeros with no partial memories extracted. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-22Merge tag 'wireless-drivers-next-for-davem-2019-02-22' of ↵David S. Miller19-430/+1515
git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next Kalle Valo says: ==================== wireless-drivers-next patches for 5.1 Most likely the last set of patches for 5.1. WPA3 support to ath10k and qtnfmac. FTM support to iwlwifi and ath10k. And of course other new features and bugfixes. wireless-drivers was merged due to dependency in mt76. Major changes: iwlwifi * HE radiotap * FTM (Fine Timing Measurement) initiator and responder implementation * bump supported firmware API to 46 * VHT extended NSS support * new PCI IDs for 9260 and 22000 series ath10k * change QMI interface to support the new (and backwards incompatible) interface from HL3.1 and used in recent HL2.0 branch firmware releases * support WPA3 with WCN3990 * support for mac80211 airtime fairness based on transmit rate estimation, the firmware needs to support WMI_SERVICE_PEER_STATS to enable this * report transmit airtime to mac80211 with firmwares having WMI_SERVICE_REPORT_AIRTIME feature, this to have more accurate airtime fairness based on real transmit time (instead of just estimated from transmit rate) * support Fine Timing Measurement (FTM) responder role * add dynamic VLAN support with firmware having WMI_SERVICE_PER_PACKET_SW_ENCRYPT * switch to use SPDX license identifiers ath * add new country codes for US brcmfmac * support monitor frames with the hardware/ucode header qtnfmac * enable WPA3 SAE and OWE support mt76 * beacon support for USB devices (mesh+ad-hoc only) rtlwifi * convert to use SPDX license identifiers libertas_tf * get the MAC address before registering the device ==================== Signed-off-by: David S. Miller <[email protected]>
2019-02-22Merge remote-tracking branch 'net-next/master' into mac80211-nextJohannes Berg16-535/+1080
Merge net-next to resolve a conflict and to get the mac80211 rhashtable fixes so further patches can be applied on top. Signed-off-by: Johannes Berg <[email protected]>
2019-02-22mac80211: update HE IEs to D3.3Liad Kaufman1-2/+24
Update element names and new fields according to D3.3 of the HE spec. Signed-off-by: Liad Kaufman <[email protected]> Signed-off-by: Luca Coelho <[email protected]> Signed-off-by: Johannes Berg <[email protected]>
2019-02-20iwlwifi: dbg_ini: implement Rx fifos dumpShahar S Matityahu2-2/+134
Implement Rx fifos dump in the new dump mechanism. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-20iwlwifi: dbg_ini: implement Tx fifos dumpShahar S Matityahu4-14/+218
Implement Tx fifos dump in the new dump mechanism. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-20iwlwifi: dbg_ini: add region to fill_header handlerShahar S Matityahu1-9/+12
Add iwl_fw_ini_region_cfg region struct to fill_header handler of iwl_dump_ini_mem_ops. it is needed for future support in fifos dumping. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-20iwlwifi: dbg_ini: make fill_range handler accept generic range pointerShahar S Matityahu1-24/+29
Make fill_range handler of iwl_dump_ini_mem_ops accept a generic range pointer. It is needed for future support in fifos dumping. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-20iwlwifi: dbg_ini: make memory dump get_size handler include headersShahar S Matityahu1-49/+49
Make the get size handler of iwl_dump_ini_mem_ops include the total size of the region. It is needed for fifos dumping. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-20iwlwifi: dbg_ini: add print to iwl_dump_ini_mem in case of invalid rangeShahar S Matityahu1-2/+6
Add informative print in case the range is not available. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-20iwlwifi: dbg_ini: fix infinite time ignore consecutive dumpsShahar S Matityahu1-2/+0
The driver sets ignore_consec to -1 which is 0xffffffff in u32 so when iwl_fw_ini_trigger_on is called, it will always return false and each trigger could be used only once. Solve this by removing the assignment to -1. Signed-off-by: Shahar S Matityahu <[email protected]> Fixes: fe1b7d6c2888 ("iwlwifi: add support for triggering ini triggers") Signed-off-by: Luca Coelho <[email protected]>
2019-02-20iwlwifi: remove redundant condition from prior alive dump flowShahar S Matityahu1-16/+0
After the FW image was loaded for the first time, fwrt->smem_cfg.num_lmacs value will no longer be zero since we don't clean it when we stop the device. So if we load the image once and then we fail on a consecutive attempt, the driver will abort any dumping. Solve this by removing the condition. It is safe to remove since when we do the actual dumping in iwl_fw_dbg_collect_sync we check that STATUS_DEVICE_ENABLED bit is still active. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-20iwlwifi: fw: no need to check return value of debugfs_create functionsGreg Kroah-Hartman2-14/+6
When calling debugfs functions, there is no need to ever check the return value. The function can work or not, but the code logic should never do something different based on this. Cc: Johannes Berg <[email protected]> Cc: Emmanuel Grumbach <[email protected]> Cc: Luca Coelho <[email protected]> Cc: Intel Linux Wireless <[email protected]> Cc: Kalle Valo <[email protected]> Cc: [email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: dbg: buffer overflow in non_collect_ts_start arrayShahar S Matityahu1-1/+1
The size of the buffer is IWL_FW_TRIGGER_ID_NUM - 1 which is equal to IWL_FW_TRIGGER_ID_HOST_CHANNEL_SWITCH_COMPLETE so if the driver receives this trigger, it will cause a buffer overflow. Solve this by increasing the buffer size by 1. Signed-off-by: Shahar S Matityahu <[email protected]> Fixes: fe1b7d6c2888 ("iwlwifi: add support for triggering ini triggers") Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: dbg_ini: enable ignore consecutive trigger featureShahar S Matityahu2-24/+16
Enable ignore consecutive trigger feature which allows to configure the driver to skip consecutive triggers from the same type. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: properly use delay option in dump trigger flowShahar S Matityahu1-2/+4
Fix several issues related to dump delay: 1. In legacy dump trigger, use stop_delay field instead of trig_dis_ms. 2. ini delay is messured in usec so align both ini and legacy to usec. 3. schedule_delayed_work receives the delay value in jiffies so translate the dump delay to jiffies. Signed-off-by: Shahar S Matityahu <[email protected]> Fixes: ea7cb8293874 ("iwlwifi: dbg: make trigger functions type agnostic") Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: mvm: add support for new FTM fw APIAvraham Stern2-10/+176
The FTM new API uses API TLV bit 15. The driver mistakenly uses this bit for beacon filter API, although no TLV was assigned for the beacon filter API. For now, make beacon filter use bit 16 instead (not set by the fw anyway). Once a TLV is assigned to the beacon filter API it should be updated. Signed-off-by: Avraham Stern <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwiwifi: mvm: Fix FW scan concurrency support assumptionsIlan Peer1-3/+3
- The FW supports up to 4 concurrent scans, so adjust the definitions accordingly. - Only a single periodic scan is supported, so enforce it in the code. Signed-off-by: Ilan Peer <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: mvm: add a debug_enable opShahar S Matityahu2-3/+6
D3 debug data is disabled by default. Currently it is done by tampering the dump mask. Add an operation that will allow this to be changed without recompilation. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: align to new periphery address space for AX210 familyShaul Triebitz2-12/+16
In AX210 family, UMAC periphery address space moved from 0xA00000 to 0xD00000. Signed-off-by: Shaul Triebitz <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: dbg: temporarily skip periphery dump for AX210 devicesShaul Triebitz1-3/+5
Many periphery addresses have changed in AX210 devices. Until sorting out which peripheries should be dumped, skip that step for now. Signed-off-by: Shaul Triebitz <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: mvm: add support for 32kHz external clock indicationHaim Dreyfuss3-5/+62
In low power modes, the chip clock source for platform integrated devices is 32kHz. It is generated internally and supplied by a crystal oscillator. However using a 32kHz sourced from crystal oscillator has high power penalty. There is an option to get an external 32kHz clock from the platform. Past experience shows that the reliability is platform dependent, i.e. on some platforms it works good and on other it doesn’t. Working from external clock will save 0.5 mW in sleep state, from overall 1.8mW that we have today, i.e. almost 30%. Each OEM can enable or disable the use of the external 32kHz clock by setting a BIOS configuration. In case the OEM configured to use 32kHz external clock the driver will pass this indication to the FW. Signed-off-by: Haim Dreyfuss <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: add FW recovery flowMordechay Goodstein4-0/+28
Add new API and TLV for the ability to send commands in the beginning and end of reset flow. The full flow of recovery is: 1. While loading FW, get address (from the TLV) of target buffer to read in case of reset 2. If an error/assert happens read the address data from step 1. 3. Reset the HW and load the FW. 4. Send the data read in step 2. 5. Add station keys 6. Send notification to FW that reset flow is done. The main use of the recovery flow is for support in PN/SN recovery when offloaded Signed-off-by: Mordechay Goodstein <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: dbg_ini: rewrite trigger flow and align to FW API changesShahar S Matityahu5-49/+107
Trigger field ignore_default was changed to override_trig. The first byte of the field indicates the driver to override existing configuration or keep the previous one The second byte of the field indicated the driver to replace the regions of the previous trigger or to append new regions to it. Change the way the active triggers are maintained to support trigger override in different apply points. Do this by making a trigger that updates at runtime by the triggers that are being used in the different apply points. In case of an assert, the driver does not reconfigure the triggers and uses the old configuration which leads to undefined behavior. Solve this by clearing the triggers in assert recovery flow. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>
2019-02-14iwlwifi: receive umac and lmac error table addresses from TLVsShahar S Matityahu3-10/+40
TLV 54 holds umac debug related addresses. TLV 55 holds lmac debug related addresses. These TLVs aim to replace the alive notification data in the future. Parse and keep error table addresses received from the TLVs for both lmac and umac and use these addresses instead of the pointer received from alive notification. The feature supports only unified image. Signed-off-by: Shahar S Matityahu <[email protected]> Signed-off-by: Luca Coelho <[email protected]>