- 02 Feb, 2024 40 commits
-
-
Miri Korenblit authored
For each DSM function, try to first read it from the UEFI. If the UEFI WIFI GUID is unclocked, or the DSM function in UEFI is invalid/unavailable - read it from ACPI. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.27dd626ce2bd.Ib90bab74a9d56deb2362edb712294360e4ddae5b@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
Move all the common items (functions, enumerations and mcaros) to regulatory.h/c files, and rename it to a common name. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.eae9bcbc0023.If1175f3143d6369076669ddd5d6ad4df0ee00659@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
As DSMs are going to be read from UEFI too, we need a unified API to get DSMs for both ACPI and UEFI. The difference in getting DSM in each one of these methods (ACPI, UEFI) is in the GUID, revision (0 for ACPI, 4 for UEFI), and size of the DSM values (8 or 32 for ACPI, 32 for UEFI). Therefore, change the iwl_acpi_get_dsm_x() to iwl_acpi_get_dsm() which determines the GUID, revision (these two are the same for all WiFi DSMs), and size (based on a func-to-size mapping) internally. While at it, fix DSM_FUNC_RFI_CONFIG to expect a 32-bit value (as defined in Intel BIOS spec) and not a 8-bit one. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.1bcd7072a7a5.I344ee0a11abbc27da0c693187d1b8bee653aaeef@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
These functions shouldn't be ACPI_CONFIG dependent, as they don't access the ACPI. The functions that really access ACPI - already handle the case that CONFIG_ACPI is not set. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.1412e6d561f8.I84f67478d01b576457e1bf489fbcb044adfda6fe@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
RFI configuration moved from internal guid to the wifi guid, DSM function 11. Update reading RFI configuration from BIOS. Signed-off-by: Anjaneyulu <pagadala.yesu.anjaneyulu@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.f4e62435310d.I4f9b6860dd8e3c7ae1f816be5ff8b5967eee266f@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
Try to read the ECKV table from UEFI first, and if the WIFI UEFI tables are unlocked or the table doesn't exist - try to read it from ACPI. Change iwl_acpi_get_eckv() to receive fwrt as argument so it will be the same as all iwl_acpi_get_x() functions, so it could be generated by the macro. While at it - move the reading of ECKV to INIT stage. There is no reason to read it each time we load the FW. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.d4937cc00727.I36e5fc7f7850229b9b377c80b5203aa47137c97c@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
Try to read the WRDD table from UEFI first, and if the WIFI UEFI tables are unlocked or the table doesn't exist - try to read it from ACPI. Change iwl_acpi_get_mcc() to receive fwrt as argument so it will be the same as all iwl_acpi_get_x() functions, so it could be generated by the macro. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.5d52eeb109f7.I4d81700a7ae7fe2dfee14e363de358be59de7823@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Shaul Triebitz authored
In version 2, listen_lmac becomes reserved. Signed-off-by: Shaul Triebitz <shaul.triebitz@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240201155157.df1890aba2fd.Icad9ba10f8bab770adc6a559b2c7bff5cccbffe9@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Ayala Beker authored
Set fast balance scan in case of active P2P GO, regardless of the BSS DTIM interval. This will increase the chances of scheduler to successfully schedule out-of-channel events. Signed-off-by: Ayala Beker <ayala.beker@intel.com> Reviewed-by: Ilan Peer <ilan.peer@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240201155157.310a00388e11.Ib136140dffa8704e68ff14e8fb69d35b97057171@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Emmanuel Grumbach authored
New tx devices may have issues sending NDPs from the host. Send a CQM event instead. If the AP is really gone, we will get a beacon loss and disconnect. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Reviewed-by: Berg, Johannes <johannes.berg@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240201155157.e95d53448e94.I0ec92f1ca56a62cd8c13390b9fe60e9a7e9411c7@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
Try to read the SPLC table from UEFI first, and if the WIFI UEFI tables are unlocked or the table doesn't exist - try to read it from ACPI Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.3d9d835b6edb.I7ea262df9431ced787b77c87149c6d7bddb7e7d6@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
As the iwl_bios_get_x() functions are now generated using a macro, and this macro requires the all iwl_acpi_get_x() to have the same prototype, change iwl_acpi_get_pwr_limit() to return a int and the actuall power limit will be filled in a pointer function parameter. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240201155157.4cce81198afe.Ice8b1b97a68da9ec7b5a4799ddb668642198e1af@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
Add some kernel-doc for a union, and fix a couple of typos I noticed looking through this. Link: https://msgid.link/20240131220227.7fd507f09bb1.I278edc9a3d5de7fddcd84009a93c494c42686b68@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
Saw this while going through the code, this function hasn't existed for a while now; remove it. Link: https://msgid.link/20240131220039.6fdb8cbf4814.I6c46065b836cafd93df676dd88c99a626a25bf46@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Emmanuel Grumbach authored
Fix some more kernel-doc warnings in FW API definitions. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Link: https://msgid.link/20240131213817.9f30c6529216.I69e98612c6c81cf1b7bd480d8041b5d3e25610d3@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
The set_active_links API is intended for link switching, so switching to no links at all is not supported. Add a warning to check that. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240129200054.e3c113f94508.Ia35f927f914bf98dd8f9350dd4f78b1d901b1c1d@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
The existing code is enabling all usable links when moving to authorized state, but this should happen only for MLO connections. Fix this. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240129200054.f5459f6c29c8.I397814449e17950fcf882ef44a1e790a71aa1dce@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
For a contiguous mask (starting with bit 0) of allowed values in a bitmap, it's equivalent to check "!(val & ~mask)" and "val ∈ [0, mask]". Use that to move the WPA versions check to the policy, for better error reporting. Reviewed-by: Jeff Johnson <quic_jjohnson@quicinc.com> Link: https://msgid.link/20240129195421.e8cae9866ccb.I2539b395e3476307d702c6867e51a937e52e57a0@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
It doesn't make sense to return BSS change flags in an int, as they're a bigger type. For this particular function it still works OK, but clean it up to avoid future errors (or copying this code in a broken way.) Reviewed-by: Jeff Johnson <quic_jjohnson@quicinc.com> Link: https://msgid.link/20240129195739.e340a7d5e7c6.I1dfcca32d43dce903494a2c474844491682671b4@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
Even if there are a lot of possible ways drivers might call this, at least knowing when they do and with what settings can be useful. Add tracing for it. Link: https://msgid.link/20240129195435.b20d2ead2013.I8213e65c274451d523a3397519ac578c3ed2df4d@changeid [removed link-id contortions as suggested by Jeff] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
To test certain beacon loss scenarios it can be useful to simply not send a couple of beacons. Add a simple debugfs file (per vif) to skip sending the beacons. They're still fully prepared etc. so their DTIM count etc. will appear as if they were simply corrupt over the air or otherwise not received. Reviewed-by: Jeff Johnson <quic_jjohnson@quicinc.com> Link: https://msgid.link/20240129200001.a267383709e6.I36f427d17c3478a7df46e205716f5ebc9b35a918@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
Try to read the WTAS table from UEFI first, and if the WIFI UEFI tables are unlocked or the table doesn't exist - try to read it from ACPI. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.45e6ff7b5063.Id3aec70887e14533b10d564f32c0cf5f2a14b792@changeid [move uefi_tables_lock_status outside ifdef to fix build errors] Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
Currently the TAS 'read-from-BIOS' flow receives the command struct and the version of it as read from FW TLVs, and fills the command accordingly. This seems wrong, we should have the 'read-from-BIOS' flow (iwl_acpi_get_tas in iwlwifi) reading/parsing/validating the table from BIOS, and the 'send-to-FW' flow (iwl_mvm_tas_init) doing all the FW versioning checks and cmd filling. Move the cmd filling to the 'send-to-fw' flow. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.24df27772a71.I57b702af4feb3f38dc21d52593c25de4b1999e4b@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
We are going to support reading BIOS tables from UEFI too, Refactor the TAS table flow: 1. Rename and move the common code to the regulatory.h/c files. 2. Remove the IWL_TAS_BLOCK_LIST_MAX, as we can use IWL_WTAS_BLACK_LIST_MAX instead. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.0c2197cf1feb.Ib0e83d5bd3f4d5cfa9c3d2925317ba49377d257f@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
Currenltly we check the validity of this variable twice. Remove the second check. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.2234490624c4.I6399b652a3c83afff1b0b5f114604d15892ee01e@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
Try to read the PPAG table from UEFI first, and if the WIFI UEFI tables are unlocked or the table doesn't exist - try to read it from ACPI Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.6516da09aec1.I0dcaf0b6d8857417ba1318467a28da5d0d7d7f27@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
We used to check enablement/validity of the PPAG table while reading it from BIOS. For newer FWs this checks were offloaded, and the driver needs to send the PPAG table anyway. The desicion whether the table needs to be validated before sending it is FW related and shouln't be in 'read-from-bios' flow. Move it to 'send-to-fw' flow instead. This will also help to avoid code duplication of checking validity in both ACPI and UEFI caes. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.7043b4087dda.I5a189f9a349556b84a79597fe1e46ffa93664df9@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
As PPAG table is going to be read from UEFI, there are some cleanups required: Move functions/definitions that are common to both UEFI and ACPI to regulatory.h/c. In addition, rename the functions/macros names so it will be clear which one is ACPI specific, and which is common for ACPI and UEFI. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.25623670b422.I8132af7517e4faf0ea8cbeb2efe9651edd319b98@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
1. The name of iwl_read_ppag_table is misleading, as this function only fills the command structure from the previously read table. Rename it. 2. Don't initialize fwrt::ppag_flags to 0 as the entire fwrt is zeroed in the INIT stage anyway. 3. Don't filter out the reserved bits from fwrt::ppag_flags when printing it, as it is already done in 'read-from-bios' flow. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.48acf340e817.I810e457b80015c1931d96d3e13c849f0339723c3@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
All the regulatory tables will be read from UEFI, and only if it doesn't exist - they will be read from ACPI. Read SAR tables (WRDS, EWRD and WGDS) from UEFI. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.533b687e1efb.Icb316291e593c8d53f41fdea2d083367dc97e3c4@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
iwl_geo_tx_power_profiles_cmd::table_revision indicates whether to use South Korea scheme or not. We use South Korea scheme if the revision of WGDS table is 1. We used to read the WGDS table from ACPI inside iwl_sar_geo_fill_table(), so we had to set table_revision only after the call to it. This added an extra if...else for each cmd version. But it has been a while since we moved the BIOS tables reading to INIT stage, and iwl_sar_geo_fill_table() is now only copying the previously stored table to the cmd structure. Set the table_revision before the call to iwl_sar_geo_fill_table() and avoid that extra if...else. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.17a2384d4535.I306570874f1da0c6345066ebbf74a04b6c8aeb37@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
The driver will support reading BIOS tables from UEFI too. Refactor the SAR tables (WRDS, EWRD, WGDS) flows: 1. Move all the SAR logic/definitions that is common to both UEFI and ACPI to a new file - regulatory.h/c. 2. Rename the relevant functions/definitions so it will be clear which is ACPI specific and which is for both ACPI and UEFI 3. Rename the function that copies the stored tables into the different commands structures, so will be clear what these functions do. Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.429a9baff34a.I040460348aa1b43609be3a317b86722d6be71c28@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
Before using EMLSR check the AP actually advertises support for it, otherwise reject the link activation. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240131091413.edaac352488d.Ic3533afc6848591e8977391ae39c144d5e794d26@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
When using MLO, we need to have only a single link active when entering suspend and of course most of the code also needs to be adjusted to not use deflink, apart from older code that's not used with MLO-capable firmware. Implement that. Note that the link selection currently prefers the "best" link, which might really not be the best for D3, but that can be fixed later once we agree. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240131091413.38f0fd4d2db0.I27c7a1d08aecc5da0af2c351212f22e92ed70219@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Miri Korenblit authored
The driver is supposed to read the PNVM from BIOS only for non-Intel SKUs. For Intel SKUs the OEM ID will be 0. Read BIOS PNVM only when a non-Intel SKU is indicated. Fixes: b99e32cb ("wifi: iwlwifi: Take loading and setting of pnvm image out of parsing part") Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Link: https://msgid.link/20240131091413.3625cf1223d3.Ieffda5f506713b1c979388dd7a0e1c1a0145cfca@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Benjamin Berg authored
Extend the test to pass an RNR appropriate for an NSTR and verify that use_for as well as cannot_use_reasons are set correctly. Signed-off-by: Benjamin Berg <benjamin.berg@intel.com> Link: https://msgid.link/20240129220918.b00aee4c4c9f.I942fddf51cabaab761de3865b4e06cce831a46ef@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Benjamin Berg authored
Test a few things around parsing of 6 GHz colocated APs to e.g. ensure that we are not going to scan for a disabled (affiliated) AP. Signed-off-by: Benjamin Berg <benjamin.berg@intel.com> Link: https://msgid.link/20240129220918.079dc50ab43b.Ide898d9f1d4c26d7e774d6fd0ec57766967d6572@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
Refactor the check for using a chanctx's def vs. min_def, to have the same in both places and reuse it later. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240129211905.6fcde4051adf.I343934874612d21727ed167accaa967958b2c25b@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Daniel Gabay authored
When we drop frames due to MIC error we want to have something printed in the logger (this won't be printed by default). Signed-off-by: Daniel Gabay <daniel.gabay@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240129211905.41b0abbf1fd2.Ib6ec6a48ec7bebe769d1e1c1df96380a758a0975@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-
Johannes Berg authored
If the firmware has the necessary support, enable SPP A-MSDUs. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: Daniel Gabay <daniel.gabay@intel.com> Reviewed-by: Gregory Greenman <gregory.greenman@intel.com> Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com> Link: https://msgid.link/20240129211905.15e4570e471f.I87cf284d3b19bb9f5558f0f33afaace6d6492acb@changeidSigned-off-by: Johannes Berg <johannes.berg@intel.com>
-