Commit Graph

153 Commits

Author SHA1 Message Date
Jose Ignacio Tornos Martinez da570a2db5 Revert "wifi: iwlwifi: remove retry loops in start"
JIRA: https://issues.redhat.com/browse/RHEL-67113

commit bfc0ed73e095cc3858d35731f191fa6e3d813262
Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Date:   Tue Oct 22 09:22:11 2024 +0200

    Revert "wifi: iwlwifi: remove retry loops in start"
    
    Revert commit dfdfe4be183b ("wifi: iwlwifi: remove retry loops in
    start"), it turns out that there's an issue with the PNVM load
    notification from firmware not getting processed, that this patch
    has been somewhat successfully papering over. Since this is being
    reported, revert the loop removal for now.
    
    We will later at least clean this up to only attempt to retry if
    there was a timeout, but currently we don't even bubble up the
    failure reason to the correct layer, only returning NULL.
    
    Fixes: dfdfe4be183b ("wifi: iwlwifi: remove retry loops in start")
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    Link: https://patch.msgid.link/20241022092212.4aa82a558a00.Ibdeff9c8f0d608bc97fc42024392ae763b6937b7@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-11-22 10:58:20 +01:00
Jose Ignacio Tornos Martinez da7b564c0d wifi: iwlwifi: s/IWL_MVM_STATION_COUNT_MAX/IWL_STATION_COUNT_MAX
JIRA: https://issues.redhat.com/browse/RHEL-67113

commit b61ed2b80911f981fa500252012330c54b9af5a0
Author: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Date:   Sun Sep 1 07:17:52 2024 +0300

    wifi: iwlwifi: s/IWL_MVM_STATION_COUNT_MAX/IWL_STATION_COUNT_MAX
    
    This isn't mvm specific.
    
    Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
    Reviewed-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    Link: https://patch.msgid.link/20240901071542.5d71a0a2b56c.I7e0fe636d914852963e7a2f5e6037d0c3e367145@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-11-22 10:58:04 +01:00
Jose Ignacio Tornos Martinez c4bec5665d wifi: iwlwifi: remove struct iwl_trans_ops
JIRA: https://issues.redhat.com/browse/RHEL-50013

commit 0d91a2bfc3dcae0a586e67c904abef002c848e6c
Author: Yedidya Benshimol <yedidya.ben.shimol@intel.com>
Date:   Wed Jun 5 14:05:03 2024 +0300

    wifi: iwlwifi: remove struct iwl_trans_ops
    
    This was needed when we had multiple types of transports. Now we only
    have pcie, so there is no need for this ops.
    Cleanup the code such as the different trans APIs will call the pcie
    function directly, instead of calling the callback,
    and remove struct iwl_trans_ops.
    
    Signed-off-by: Yedidya Benshimol <yedidya.ben.shimol@intel.com>
    Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
    Link: https://msgid.link/20240605140327.8315ff64f9f3.Ifdbc1f26d49766f7de553dcb5f613885f4ee65cc@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-10-29 08:18:03 +01:00
Jose Ignacio Tornos Martinez 63bab8bb6a wifi: iwlwifi: always print the firmware version in hex
JIRA: https://issues.redhat.com/browse/RHEL-50013

commit 45eeee1f300d2b0b1ad8570b4ef6e2a23932f1a5
Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Date:   Sun May 12 07:31:05 2024 +0300

    wifi: iwlwifi: always print the firmware version in hex
    
    All our firmware versions should now be printed in hex.
    
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    Reviewed-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
    Link: https://msgid.link/20240512072733.cae4c562b2c3.I5043383bd0e81f872c55046afd2c6560f482c8e0@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-10-29 08:17:46 +01:00
Jose Ignacio Tornos Martinez 6645ef7c00 wifi: iwlwifi: dbg_ini: move iwl_dbg_tlv_free outside of debugfs ifdef
JIRA: https://issues.redhat.com/browse/RHEL-50013

commit 87821b67dea87addbc4ab093ba752753b002176a
Author: Shahar S Matityahu <shahar.s.matityahu@intel.com>
Date:   Fri May 10 17:06:39 2024 +0300

    wifi: iwlwifi: dbg_ini: move iwl_dbg_tlv_free outside of debugfs ifdef
    
    The driver should call iwl_dbg_tlv_free even if debugfs is not defined
    since ini mode does not depend on debugfs ifdef.
    
    Fixes: 68f6f492c4 ("iwlwifi: trans: support loading ini TLVs from external file")
    Signed-off-by: Shahar S Matityahu <shahar.s.matityahu@intel.com>
    Reviewed-by: Luciano Coelho <luciano.coelho@intel.com>
    Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
    Link: https://msgid.link/20240510170500.c8e3723f55b0.I5e805732b0be31ee6b83c642ec652a34e974ff10@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-10-29 08:17:26 +01:00
Jose Ignacio Tornos Martinez 73561e0d18 wifi: iwlwifi: Use request_module_nowait
JIRA: https://issues.redhat.com/browse/RHEL-50013

commit 3d913719df14c28c4d3819e7e6d150760222bda4
Author: Ben Greear <greearb@candelatech.com>
Date:   Tue Apr 30 16:42:12 2024 -0700

    wifi: iwlwifi: Use request_module_nowait
    
    This appears to work around a deadlock regression that came in
    with the LED merge in 6.9.
    
    The deadlock happens on my system with 24 iwlwifi radios, so maybe
    it something like all worker threads are busy and some work that needs
    to complete cannot complete.
    
    Link: https://lore.kernel.org/linux-kernel/20240411070718.GD6194@google.com/
    Fixes: f5c31bcf604d ("Merge tag 'leds-next-6.9' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/leds")
    Signed-off-by: Ben Greear <greearb@candelatech.com>
    Link: https://msgid.link/20240430234212.2132958-1-greearb@candelatech.com
    [also remove unnecessary "load_module" var and now-wrong comment]
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-10-29 08:17:15 +01:00
Jose Ignacio Tornos Martinez d2b27c6f8a wifi: iwlwifi: remove devices that never came out
JIRA: https://issues.redhat.com/browse/RHEL-50013

commit f473a7fd6d604c972853561fef853ea62d965647
Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Date:   Wed Mar 20 23:26:27 2024 +0200

    wifi: iwlwifi: remove devices that never came out
    
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
    Link: https://msgid.link/20240320232419.b3715c0d4bdd.I1337ed9c3edbec4ea9ff7e8a8b02410d5e69bf74@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-10-29 08:16:43 +01:00
Jose Ignacio Tornos Martinez d01ccab035 wifi: iwlwifi: load b0 version of ucode for HR1/HR2
JIRA: https://issues.redhat.com/browse/RHEL-34696

commit 32a1bbd3fe3ff21deca67e3508ab3cc05931ccd2
Author: Mukesh Sisodiya <mukesh.sisodiya@intel.com>
Date:   Sun Feb 18 19:51:52 2024 +0200

    wifi: iwlwifi: load b0 version of ucode for HR1/HR2
    
    load b0 version of ucode for both a0 and b0 step of HR RF.
    
    Signed-off-by: Mukesh Sisodiya <mukesh.sisodiya@intel.com>
    Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
    Link: https://msgid.link/20240218194912.0166f5d2d5d2.I34c1d46aefd70b34c1c75cea67792bc5ec8bc285@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-06-17 09:19:41 +02:00
Jose Ignacio Tornos Martinez cef2f3617c wifi: iwlwifi: remove retry loops in start
JIRA: https://issues.redhat.com/browse/RHEL-34696

commit dfdfe4be183b27b278d78225d48b98b3c1ca6285
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Tue Jan 23 20:08:15 2024 +0200

    wifi: iwlwifi: remove retry loops in start
    
    There's either the pldr_sync case, in which case we didn't want
    or do the retry loops anyway, or things will just continue to
    fail. Remove the retry loop that was added in a previous attempt
    to address the issue that was later (though still a bit broken)
    addressed by the pldr_sync case.
    
    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/20240123200528.f80a88a18799.I48f21eda090f4cc675f40e99eef69a986d21b500@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-06-17 09:18:51 +02:00
Jose Ignacio Tornos Martinez 25413fe18f wifi: iwlwifi: fix double-free bug
JIRA: https://issues.redhat.com/browse/RHEL-28754

commit 353d321f63f7dbfc9ef58498cc732c9fe886a596
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Tue Jan 23 20:08:11 2024 +0200

    wifi: iwlwifi: fix double-free bug
    
    The storage for the TLV PC register data wasn't done like all
    the other storage in the drv->fw area, which is cleared at the
    end of deallocation. Therefore, the freeing must also be done
    differently, explicitly NULL'ing it out after the free, since
    otherwise there's a nasty double-free bug here if a file fails
    to load after this has been parsed, and we get another free
    later (e.g. because no other file exists.) Fix that by adding
    the missing NULL assignment.
    
    Cc: stable@vger.kernel.org
    Fixes: 5e31b3df86ec ("wifi: iwlwifi: dbg: print pc register data once fw dump occurred")
    Reported-by: Guy Kaplan <guy.kaplan@intel.com>
    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/20240123200528.675f3c24ec0d.I6ab4015cd78d82dd95471f840629972ef0331de3@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-03-18 17:58:15 +01:00
Jose Ignacio Tornos Martinez 8d362fb449 wifi: iwlwifi: add new RF support for wifi7
JIRA: https://issues.redhat.com/browse/RHEL-19746

commit 5356b8c8f652039481e9569575e4491d594482f7
Author: Mukesh Sisodiya <mukesh.sisodiya@intel.com>
Date:   Wed Oct 11 13:07:17 2023 +0300

    wifi: iwlwifi: add new RF support for wifi7
    
    Add the support for new RF based on step-id.
    
    Signed-off-by: Mukesh Sisodiya <mukesh.sisodiya@intel.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20231011130030.d902aa8cfd1b.I7c7b357ba41c00015d6c6255b45b3d17549948f0@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-02-01 15:29:48 +01:00
Jose Ignacio Tornos Martinez 715f3053bb wifi: iwlwifi: check for kmemdup() return value in iwl_parse_tlv_firmware()
JIRA: https://issues.redhat.com/browse/RHEL-19746

commit 3c8aaaa7557b1e33e6ef95a27a5d8a139dcd0874
Author: Dmitry Antipov <dmantipov@yandex.ru>
Date:   Mon Oct 9 20:04:49 2023 +0300

    wifi: iwlwifi: check for kmemdup() return value in iwl_parse_tlv_firmware()
    
    In 'iwl_parse_tlv_firmware()', check for 'kmemdup()' return value
    when handling IWL_UCODE_TLV_CURRENT_PC and set the number of parsed
    entries only if an allocation was successful (just like it does with
    handling IWL_UCODE_TLV_CMD_VERSIONS above). Compile tested only.
    
    Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru>
    Acked-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20231009170453.149905-1-dmantipov@yandex.ru
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-02-01 15:29:47 +01:00
Jose Ignacio Tornos Martinez 479eb6fece wifi: iwlwifi: fix opmode start/stop race
JIRA: https://issues.redhat.com/browse/RHEL-19746

commit 7186d271acec33496de73b3a9271e780b94241e6
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Tue Sep 26 11:07:16 2023 +0300

    wifi: iwlwifi: fix opmode start/stop race
    
    There's a race when the device is unbound (maybe because the
    module is unloaded) while the opmode start hasn't finished yet.
    The complete(request_firmware_complete) after the opmode start
    was meant (and commented accordingly) to prevent this problem,
    but it's not sufficient when the opmode module is loaded after
    the firmware load already completed, which happens regularly
    now because firmware load doesn't require userspace, unlike
    module load.
    
    Fix this by using the existing opmode registration mutex to
    protected the start/stop flows against each other properly.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20230926110319.85951554fed8.I62f20f40d79d0f136fa05e46d7fc16dc437fa3db@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-02-01 15:29:41 +01:00
Jose Ignacio Tornos Martinez f43e83ade9 wifi: iwlwifi: skip opmode start retries on dead transport
JIRA: https://issues.redhat.com/browse/RHEL-19746

commit eb8efbac9087230fccce8e6873c873f837a05219
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Tue Sep 26 11:07:15 2023 +0300

    wifi: iwlwifi: skip opmode start retries on dead transport
    
    These retries aren't going to succeed if the device was
    deemed dead and needs to be unbound/rebound/... to be
    recovered; skip the retries in that case.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20230926110319.9f472069d75d.Ib6684c5b2ea8ed98f082c9b0e9bb2b03c3ea4fe3@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-02-01 15:29:41 +01:00
Jose Ignacio Tornos Martinez bdcf99ceaf wifi: iwlwifi: honor the enable_ini value
JIRA: https://issues.redhat.com/browse/RHEL-19746

commit e0c1ca236e28e4263fba76d47a108ed95dcae33e
Author: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Date:   Wed Aug 30 11:30:52 2023 +0300

    wifi: iwlwifi: honor the enable_ini value
    
    In case the user sets the enable_ini to some preset, we want to honor
    the value.
    
    Remove the ops to set the value of the module parameter is runtime, we
    don't want to allow to modify the value in runtime since we configure
    the firmware once at the beginning on its life.
    
    Fixes: b49c2b252b58 ("iwlwifi: Configure FW debug preset via module param.")
    Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20230830112059.5734e0f374bb.I6698eda8ed2112378dd47ac5d62866ebe7a94f77@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2024-02-01 15:28:57 +01:00
Jose Ignacio Tornos Martinez ba5935cd64 wifi: iwlwifi: cfg: remove trailing dash from FW_PRE constants
JIRA: https://issues.redhat.com/browse/RHEL-2907

commit 31aeae2446d50665b6ec51d564f5e7fe751d53d4
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Wed Jun 21 13:12:18 2023 +0300

    wifi: iwlwifi: cfg: remove trailing dash from FW_PRE constants
    
    We have the trailing dash here, but that complicates all
    the code. Simplify this by removing the dashes, adding
    them to the *_MODULE_FIRMWARE macros, and adjusting the
    code using this accordingly.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20230621130443.72240ca13b83.I1f4ed547f0964719ed98a3ef928080462d594491@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2023-11-27 15:01:51 +01:00
Jose Ignacio Tornos Martinez 1d59cd2b2b wifi: iwlwifi: unify Bz/Gl device configurations
JIRA: https://issues.redhat.com/browse/RHEL-2907

commit 3fd31289d5de8392c914db4f8cb36e0999afdac2
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Wed Jun 21 13:12:15 2023 +0300

    wifi: iwlwifi: unify Bz/Gl device configurations
    
    All the configurations for the various Bz/Gl devices
    are basically identical, except for Gl A-step and the
    firmware filename prefixes.
    
    Add some infrastructure to auto-generate the firmware
    filename prefix based on the detected MAC step and
    RF name/step, and remove all the unneeded configs.
    
    This reduces the size of the iwlwifi module by ~9k:
     517582   27111     560  545253   851e5 drivers/net/wireless/intel/iwlwifi/iwlwifi.ko
     526885   27083     560  554528   87620 drivers/net/wireless/intel/iwlwifi/iwlwifi.ko
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20230621130443.1dc121ba338f.I07d651516eb82cbaded4724ef30558a50f2fa866@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2023-11-27 15:01:51 +01:00
Íñigo Huguet 63781fdd13 wifi: iwlwifi: mvm: allow number of beacons from FW
Bugzilla: https://bugzilla.redhat.com/2196821

commit d9bfd5a06448c175ba3a333e13168fb2622e9dd8
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Sun Apr 16 15:47:37 2023 +0300

    wifi: iwlwifi: mvm: allow number of beacons from FW
    
    Newer firmware images have a TLV advertising how many
    beacons they support, use that to permit adding more
    links in AP mode (FW needs to support at least as many
    links as beacons).
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20230416154301.0d7522533557.Ic6b5992e94446c35cb0f3add019defa6e7aded2a@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2023-07-26 13:15:57 +02:00
Íñigo Huguet 3161a315f8 wifi: iwlwifi: Fix spelling mistake "upto" -> "up to"
Bugzilla: https://bugzilla.redhat.com/2196821

commit 41c1b0b5aa4518ed3b7a97f35164dec298072aff
Author: Colin Ian King <colin.i.king@gmail.com>
Date:   Fri Apr 14 13:11:55 2023 +0300

    wifi: iwlwifi: Fix spelling mistake "upto" -> "up to"
    
    There is a spelling mistake in a IWL_ERR error message. Fix it.
    
    Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20230414130637.a00965734d02.I760cb43829b3d7a0f567f0958059f2fae0aa8a93@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2023-07-26 13:15:46 +02:00
Íñigo Huguet e0d8d1e0b7 wifi: iwlwifi: dbg: print pc register data once fw dump occurred
Bugzilla: https://bugzilla.redhat.com/2196821

Omitted-fix: 2b69d242e2 ("wifi: iwlwifi: fw: print PC register value instead of address")
             Not needed for normal working, it only fix a value shown in a debug
	     message. I can't check it's done right, so the risk of backporting
	     the fix out of order is not worth it.

commit 5e31b3df86ec6fbb925eee77fe2c450099c61dff
Author: Mukesh Sisodiya <mukesh.sisodiya@intel.com>
Date:   Thu Apr 13 21:40:21 2023 +0300

    wifi: iwlwifi: dbg: print pc register data once fw dump occurred
    
    Add debug print for different FW program counter details of
    different CPU. Program counter pc details will be read from
    TLV during init.
    
    Signed-off-by: Mukesh Sisodiya <mukesh.sisodiya@intel.com>
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>
    Link: https://lore.kernel.org/r/20230413213309.862790d336a9.I34e2ea05a79e8b2552f7f221bacf3af0166cb9c0@changeid
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2023-07-26 13:15:42 +02:00
Jose Ignacio Tornos Martinez 91aad10d03 wifi: iwlwifi: improve tag handling in iwl_request_firmware
Bugzilla: https://bugzilla.redhat.com/2178526

commit 12de5de4d18869bb226c02e11faa91fa8e84df2c
Author: Heiner Kallweit <hkallweit1@gmail.com>
Date:   Fri Jan 27 00:28:12 2023 +0200

    wifi: iwlwifi: improve tag handling in iwl_request_firmware
    
    We can remove the intermediary string conversion and use drv->fw_index
    in the final snprintf directly.
    
    Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Link: https://lore.kernel.org/r/20230127002430.175bfffdf2f5.I7ec7a29b2d93a977cb0a39dbcc7c875032eb14b7@changeid
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2023-05-09 08:17:55 +02:00
Jose Ignacio Tornos Martinez 735fb0da27 wifi: iwlwifi: mvm: Advertise EHT capabilities
Bugzilla: https://bugzilla.redhat.com/2178526

commit 26d7cc0abe6181148c50982ec2e8e0e46f74b419
Author: Ilan Peer <ilan.peer@intel.com>
Date:   Tue Nov 22 22:10:32 2022 +0200

    wifi: iwlwifi: mvm: Advertise EHT capabilities
    
    Add support for advertising EHT capabilities if supported by
    device SKU and not disabled by module parameters.
    
    Signed-off-by: Ilan Peer <ilan.peer@intel.com>
    Link: https://lore.kernel.org/r/20221122220713.6bc00d851794.I214005645f3da21d8f2458a70355deeca04a19e8@changeid
    Signed-off-by: Gregory Greenman <gregory.greenman@intel.com>

Signed-off-by: Jose Ignacio Tornos Martinez <jtornosm@redhat.com>
2023-05-09 08:16:06 +02:00
Íñigo Huguet 13ae67b2c3 iwlwifi: mvm: remove cipher scheme support
Bugzilla: https://bugzilla.redhat.com/2059999

commit 8b3d2c4882874f32dd1470a92e98417a8d0345cb
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Fri Mar 4 13:21:20 2022 +0200

    iwlwifi: mvm: remove cipher scheme support
    
    There are no shipping firmware versions with this, and there
    will also not be in the future, so remove the support.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20220304131517.8b3c8b4adf41.Ib3ddb6b250ea2dd72b4ecc88bdd5cffb86af1dcc@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:51:08 +02:00
Íñigo Huguet a00753527f iwlwifi: Configure FW debug preset via module param.
Bugzilla: https://bugzilla.redhat.com/2059999

commit b49c2b252b58e8afa2b0a908d61ef979334d78bd
Author: Ayala Barazani <ayala.barazani@intel.com>
Date:   Fri Mar 4 13:21:19 2022 +0200

    iwlwifi: Configure FW debug preset via module param.
    
    The module param "enable_ini" is currently used to be enable/disable ini.
    Add the option to configure the FW debug preset via this module param,
    by change it type from boolean to an integer.
    
    Signed-off-by: Ayala Barazani <ayala.barazani@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20220304131517.4929e4b14956.I1bdffa4c37d4ee349aa0001978b716b96e38b090@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:51:07 +02:00
Íñigo Huguet e632972893 iwlwifi: drv: load tlv debug data earlier
Bugzilla: https://bugzilla.redhat.com/2059999

commit 8ea28f13bbac05999d6136548e8b8a07d7b387c9
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Fri Feb 4 12:25:06 2022 +0200

    iwlwifi: drv: load tlv debug data earlier
    
    There's no good reason to pick the opmode first and load this
    under the mutex, so just load it before continuing. This will
    let us load it asynchronously more easily later.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20220204122220.a28df852f70d.Icaf6556d81bc137a459aabf0511d46c3861b0413@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:50:52 +02:00
Íñigo Huguet 6e1563d736 iwlwifi: fix various more -Wcast-qual warnings
Bugzilla: https://bugzilla.redhat.com/2059999

commit 86e8e6574340db032f9da5e9514d731d3fbe3c13
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Fri Jan 28 15:34:28 2022 +0200

    iwlwifi: fix various more -Wcast-qual warnings
    
    When enabling W=3 that gets us -Wcast-qual, fix those warnings
    in the code and propagate constness properly, or cast it away
    via (uintptr_t) where really needed.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20220128153014.4ac2f19c121e.Ied9469d93f8199206242bfba96e4e8d1949e3a08@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:50:47 +02:00
Íñigo Huguet ae27cc2b00 iwlwifi: propagate (const) type qualifier
Bugzilla: https://bugzilla.redhat.com/2059999

commit 73c289bac05919286f8c7e1660fcaf6ec0468363
Author: Bjoern A. Zeeb <bz@FreeBSD.ORG>
Date:   Fri Jan 28 15:34:27 2022 +0200

    iwlwifi: propagate (const) type qualifier
    
    Most of this change is a continuation of commit 403ea939ea
    ("iwlwifi: dbg: Mark ucode tlv data as const") propagating the
    (const) type qualifier for ucode based tlv data to avoid having
    the impression that it is writeable.
    The other part of the change preserves the (const) type qualifier
    over casts and function calls where it was previously lost.
    Both changes are needed to avoid compile time errors on system with
    more strict error settings, in this case found with clang on FreeBSD.
    
    Sponsored by:  The FreeBSD Foundation
    Signed-off-by: Bjoern A. Zeeb <bz@FreeBSD.ORG>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    [fix double word in commit message]
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20220128153014.3230c41312fc.I0032c597984834258d5a79b97052ed83dbe53b80@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:50:47 +02:00
Íñigo Huguet 95774281c8 iwlwifi: fix use-after-free
Bugzilla: https://bugzilla.redhat.com/2059999

commit bea2662e7818e15d7607d17d57912ac984275d94
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Tue Feb 8 11:47:30 2022 +0100

    iwlwifi: fix use-after-free
    
    If no firmware was present at all (or, presumably, all of the
    firmware files failed to parse), we end up unbinding by calling
    device_release_driver(), which calls remove(), which then in
    iwlwifi calls iwl_drv_stop(), freeing the 'drv' struct. However
    the new code I added will still erroneously access it after it
    was freed.
    
    Set 'failure=false' in this case to avoid the access, all data
    was already freed anyway.
    
    Cc: stable@vger.kernel.org
    Reported-by: Stefan Agner <stefan@agner.ch>
    Reported-by: Wolfgang Walter <linux@stwm.de>
    Reported-by: Jason Self <jason@bluehome.net>
    Reported-by: Dominik Behr <dominik@dominikbehr.com>
    Reported-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
    Fixes: ab07506b0454 ("iwlwifi: fix leaks/bad data after failed firmware load")
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Kalle Valo <kvalo@kernel.org>
    Link: https://lore.kernel.org/r/20220208114728.e6b514cf4c85.Iffb575ca2a623d7859b542c33b2a507d01554251@changeid

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:50:08 +02:00
Íñigo Huguet 044a73a238 iwlwifi: remove module loading failure message
Bugzilla: https://bugzilla.redhat.com/2059999

commit 6518f83ffa51131daaf439b66094f684da3fb0ae
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Fri Dec 10 11:12:45 2021 +0200

    iwlwifi: remove module loading failure message
    
    When CONFIG_DEBUG_TEST_DRIVER_REMOVE is set, iwlwifi crashes
    when the opmode module cannot be loaded, due to completing
    the completion before using drv->dev, which can then already
    be freed.
    
    Fix this by removing the (fairly useless) message. Moving the
    completion later causes a deadlock instead, so that's not an
    option.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/20211210091245.289008-2-luca@coelho.fi
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:50:00 +02:00
Íñigo Huguet 7ecf6b16f4 iwlwifi: dump RCM error tables
Bugzilla: https://bugzilla.redhat.com/2059999

commit 4cd177b43a1443924c56c6d94b8a77be762a3976
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Fri Dec 10 11:12:39 2021 +0200

    iwlwifi: dump RCM error tables
    
    There's another set of error tables on newer (Bz) hardware,
    support finding and dumping those error tables if present.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20211210110539.c727a975b434.Ie5ad3fd974b700f1b90867b2b52ef7607799e8fe@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:50:00 +02:00
Íñigo Huguet efc63df954 iwlwifi: dump both TCM error tables if present
Bugzilla: https://bugzilla.redhat.com/2059999

commit 57417e1bf9d95449e1d9e4547a69886f9bd16f87
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Fri Dec 10 11:12:38 2021 +0200

    iwlwifi: dump both TCM error tables if present
    
    There can be two TCMs in a given device, dump both of the
    error tables if present.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20211210110539.887cba319301.Ifdc3f617f7e0e3e39c90e8c208e60f11b3bb9404@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:50:00 +02:00
Íñigo Huguet 15e267700a iwlwifi: parse error tables from debug TLVs
Bugzilla: https://bugzilla.redhat.com/2059999

commit aece8927a6512e194309751f5981be4482efbf19
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Fri Dec 10 11:12:36 2021 +0200

    iwlwifi: parse error tables from debug TLVs
    
    With more things being added, we're no longer going to duplicate
    the error tables from the debug TLVs nor send them at runtime.
    Use the debug TLVs to find the locations of the error tables. As
    we've never released firmware using IWL_UCODE_TLV_TCM_DEBUG_ADDRS
    just remove that entirely.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20211210110539.779d68490f68.I472c7d9cbaca46000a10ec18808ef54836b33a8a@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-05-31 14:49:59 +02:00
Íñigo Huguet 93a9364124 iwlwifi: support 4-bits in MAC step value
Bugzilla: http://bugzilla.redhat.com/2043454

commit 55c6d8f89dab6d9bed0165dd4c134856975bd000
Author: Mike Golant <michael.golant@intel.com>
Date:   Tue Dec 7 16:05:51 2021 +0200

    iwlwifi: support 4-bits in MAC step value
    
    We have a MAC component (which is inside the SoC) and it has several
    different HW steps.  3 bits used to be enough but now we need 4-bits
    to represent all the different steps.
    
    Properly support 4-bits in the MAC step value by refactoring all the
    current handling of the MAC step/dash.
    
    Already from family 8000 and up the dash (bits 0-1) no longer exists
    and the step (until 8000 bits 2-3) consists of the dash bits as well.
    
    To do this remove the CSR_HW_REV_STEP and the CSR_HW_REV_DASH
    macros, replace them with CSR_HW_REV_STEP_DASH and add hw_rev_step
    into the trans struct.
    
    In addition remove the CSR_HW_IF_CONFIG_REG_MSK_MAC_STEP and
    CSR_HW_IF_CONFIG_REG_MSK_MAC_DASH macros and create a new macro
    combining the 2 (this way we don't need shifting or anything else.)
    
    Signed-off-by: Matti Gottlieb <matti.gottlieb@intel.com>
    Signed-off-by: Mike Golant <michael.golant@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20211207160459.2e81a14d1f80.Ia5287e37fb3439d805336837361f6491f958e465@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-02-21 11:40:50 +01:00
Íñigo Huguet 06499f747b iwlwifi: fix leaks/bad data after failed firmware load
Bugzilla: http://bugzilla.redhat.com/2043454

commit ab07506b0454bea606095951e19e72c282bfbb42
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Fri Dec 10 11:12:42 2021 +0200

    iwlwifi: fix leaks/bad data after failed firmware load
    
    If firmware load fails after having loaded some parts of the
    firmware, e.g. the IML image, then this would leak. For the
    host command list we'd end up running into a WARN on the next
    attempt to load another firmware image.
    
    Fix this by calling iwl_dealloc_ucode() on failures, and make
    that also clear the data so we start fresh on the next round.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20211210110539.1f742f0eb58a.I1315f22f6aa632d94ae2069f85e1bca5e734dce0@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-02-21 11:40:49 +01:00
Íñigo Huguet 5ef7d1848d iwlwifi: mvm: retry init flow if failed
Bugzilla: http://bugzilla.redhat.com/2043454

commit 5283dd677e52af9db6fe6ad11b2f12220d519d0c
Author: Mordechay Goodstein <mordechay.goodstein@intel.com>
Date:   Wed Nov 10 15:01:59 2021 +0200

    iwlwifi: mvm: retry init flow if failed
    
    In some very rare cases the init flow may fail.  In many cases, this is
    recoverable, so we can retry.  Implement a loop to retry two more times
    after the first attempt failed.
    
    This can happen in two different situations, namely during probe and
    during mac80211 start.  For the first case, a simple loop is enough.
    For the second case, we need to add a flag to prevent mac80211 from
    trying to restart it as well, leaving full control with the driver.
    
    Cc: <stable@vger.kernel.org>
    Signed-off-by: Mordechay Goodstein <mordechay.goodstein@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
    Link: https://lore.kernel.org/r/iwlwifi.20211110150132.57514296ecab.I52a0411774b700bdc7dedb124d8b59bf99456eb2@changeid

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-02-21 11:40:39 +01:00
Íñigo Huguet f474b33111 iwlwifi: yoyo: fw debug config from context info and preset
Bugzilla: http://bugzilla.redhat.com/2043454

commit f21baf244112e646c6b6c9db94834cf06358db06
Author: Mukesh Sisodiya <mukesh.sisodiya@intel.com>
Date:   Sun Oct 17 12:40:19 2021 +0300

    iwlwifi: yoyo: fw debug config from context info and preset
    
    Add new TLV for debug config set to read preset
    based on TLV is set in context info.
    This is needed to set the preset based on ucode in early
    trigger point.
    Add DRAM frag allocation info in first fragment of
    DBGC1 with all details.
    New capability from FW for DBGC frag debug support is
    added and BUFFER_ALLOCATION_CMD is disabled in capability
    is supported.
    
    Signed-off-by: Mukesh Sisodiya <mukesh.sisodiya@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20211017123741.cacf0babc521.If3704b5fda09b344e3e438252360898a3f2e90fa@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-02-21 11:40:33 +01:00
Íñigo Huguet b64b89cabd iwlwifi: parse debug exclude data from firmware file
Bugzilla: http://bugzilla.redhat.com/2043454

commit fad92a1d11f6ef81cca3c1ea24d5703930339291
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Sun Oct 17 12:40:12 2021 +0300

    iwlwifi: parse debug exclude data from firmware file
    
    Parse the memory dump exclusion TLVs from the firmware file
    and save the data to be able to apply them later upon dump.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20211017123741.ec280bcb32cb.Iac0da0e22d7c3c0e237867c9113a06ddd95c7a51@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-02-21 11:40:33 +01:00
Íñigo Huguet b82f7b558f iwlwifi: remove MODULE_AUTHOR() statements
Bugzilla: http://bugzilla.redhat.com/2043454

commit e0e0d16641cd8fa163ba21b98f8da9c5780ded5f
Author: Johannes Berg <johannes.berg@intel.com>
Date:   Sun Oct 17 11:43:47 2021 +0300

    iwlwifi: remove MODULE_AUTHOR() statements
    
    Consensus seems to be emerging that corporations or groups
    shouldn't be listed as module authors, and we will not
    maintain this email address any longer. Just remove it.
    
    Signed-off-by: Johannes Berg <johannes.berg@intel.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20211017113927.32109514aad0.I91a7d745f4ab50ee8ef918ece00dda8251541595@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2022-02-21 11:40:32 +01:00
Íñigo Huguet a624dd8356 iwlwifi: use DEFINE_MUTEX() for mutex lock
Bugzilla: http://bugzilla.redhat.com/2033354

commit 5993c90ccb56b34aaedfd77a1c67c7a2039090ee
Author: Zheng Yongjun <zhengyongjun3@huawei.com>
Date:   Mon Aug 2 17:28:26 2021 +0300

    iwlwifi: use DEFINE_MUTEX() for mutex lock
    
    mutex lock can be initialized automatically with DEFINE_MUTEX()
    rather than explicitly calling mutex_init().
    
    Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
    Link: https://lore.kernel.org/r/iwlwifi.20210802172232.2a583d006739.Ia782c08525397b6430b1c877a870d688a7f3f494@changeid
    Signed-off-by: Luca Coelho <luciano.coelho@intel.com>

Signed-off-by: Íñigo Huguet <ihuguet@redhat.com>
2021-12-22 13:45:58 +01:00
Johannes Berg 48d0c8d5a0 iwlwifi: fw: dump TCM error table if present
If the TCM is present in the hardware (as advertised in the firmware
file TLV data), dump its error log table during firmware error dumps.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20210621103449.2d2149f6654f.Id831f8fbca59900ba7efc623ffca0ca938b664d3@changeid
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2021-06-22 16:57:57 +03:00
Roee Goldfiner 4f7411d648 iwlwifi: mvm: umac error table mismatch
umac_error_table In TLV address was read using mask on MSB
but on the same table in alive message it was without which
caused mismatch in devices with different memory region MSB

Signed-off-by: Roee Goldfiner <roee.h.goldfiner@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20210411124417.179fee442115.Ib6eabe86cfda0b6044f07c07448c366b6e07e53d@changeid
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2021-04-14 12:07:19 +03:00
Takashi Iwai 403ea939ea iwlwifi: dbg: Mark ucode tlv data as const
The ucode TLV data may be read-only and should be treated as const
pointers, but currently a few code forcibly cast to the writable
pointer unnecessarily.  This gave developers a wrong impression as if
it can be modified, resulting in crashing regressions already a couple
of times.

This patch adds the const prefix to those cast pointers, so that such
attempt can be caught more easily in future.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
Acked-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/20210112132449.22243-3-tiwai@suse.de
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2021-02-10 13:58:15 +02:00
Dror Moshe a1d59263e7 iwlwifi: parse phy integration string from FW TLV
Parse phy integration string from FW TLV.

Signed-off-by: Dror Moshe <drorx.moshe@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20210117164916.0c790e930484.I23ef2cb9c871e6adc4aab6be378f3811cb531155@changeid
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2021-02-05 11:55:17 +02:00
Gustavo A. R. Silva 10a0472d18 iwlwifi: iwl-drv: Fix fall-through warnings for Clang
In preparation to enable -Wimplicit-fallthrough for Clang, fix a
warning by replacing a /* fall through */ comment with the new
pseudo-keyword macro fallthrough; instead of letting the code fall
through to the next case.

Notice that Clang doesn't recognize /* fall through */ comments as
implicit fall-through markings.

Link: https://github.com/KSPP/linux/issues/115
Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/edd98d194bfc98b4be93a9bdc303630b719c0e66.1605896060.git.gustavoars@kernel.org
2020-12-11 20:21:28 +02:00
Johannes Berg 8e99ea8d09 iwlwifi: use SPDX tags
Use SPDX tags instead of the long copyright notices.  Also cleanup
some duplicate copyright notices and combine the years where possible.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20201210000603.481bcb512a6f.I8146abe5a637079e7336209f23cb26af98b12b31@changeid
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2020-12-10 00:15:31 +02:00
Johannes Berg 3fa965c2dd iwlwifi: pcie: change 12k A-MSDU config to use 16k buffers
If 12k A-MSDU size is requested, we will actually allocate 16k
due to page allocation. Thus, change it to actually mean 16k,
which is useful for certain sniffer use cases.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20201209231352.84ae405829d4.I31184f4be31f7c3feb9a29aef3a111e70d15c64a@changeid
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
2020-12-10 00:14:17 +02:00
Nathan Errera be9ae34ead iwlwifi: mvm: get number of stations from TLV
FW is changing the max number of supported stations. To adapt to the
change we get the max number from the TLV and act according to the new
number.

Signed-off-by: Nathan Errera <nathan.errera@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/iwlwifi.20201008180656.863ab470babc.I393223392f36436663c4e66add03fefe77b74e60@changeid
2020-10-08 20:09:25 +03:00
Lee Jones 7d4ced8699 iwlwifi: iwl-drv: Provide descriptions debugfs dentries
Also demote a non-conforming kernel-doc function header.

Fixes the following W=1 kernel build warning(s):

 drivers/net/wireless/intel/iwlwifi/iwl-drv.c:124: warning: Function parameter or member 'dbgfs_drv' not described in 'iwl_drv'
 drivers/net/wireless/intel/iwlwifi/iwl-drv.c:124: warning: Function parameter or member 'dbgfs_trans' not described in 'iwl_drv'
 drivers/net/wireless/intel/iwlwifi/iwl-drv.c:124: warning: Function parameter or member 'dbgfs_op_mode' not described in 'iwl_drv'
 drivers/net/wireless/intel/iwlwifi/iwl-drv.c:1329: warning: Function parameter or member 'ucode_raw' not described in 'iwl_req_fw_callback'
 drivers/net/wireless/intel/iwlwifi/iwl-drv.c:1329: warning: Function parameter or member 'context' not described in 'iwl_req_fw_callback'

Cc: Johannes Berg <johannes.berg@intel.com>
Cc: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Cc: Luca Coelho <luciano.coelho@intel.com>
Cc: Intel Linux Wireless <linuxwifi@intel.com>
Cc: Kalle Valo <kvalo@codeaurora.org>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Jakub Kicinski <kuba@kernel.org>
Cc: linux-wireless@vger.kernel.org
Cc: netdev@vger.kernel.org
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20200910065431.657636-16-lee.jones@linaro.org
2020-10-08 13:43:53 +03:00
Johannes Berg e9a7f025e7 iwlwifi: remove outdated copyright print/module statement
Remove the outdated copyright, don't print it, and update the
module author to actually be Intel, not Intel's copyright.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20200425130140.dc86a4e9451a.Ice2e21b6427a4b57f953dba9ceb5b8b96b251a8c@changeid
2020-05-08 09:53:06 +03:00
Emmanuel Grumbach f25c418dca iwlwifi: remove antenna_coupling module parameter
This module parameter should not be mangled by users.
This relates to a very old driver and I doubt people can
really check the antenna coupling in a way that would make
the BT Coexistence work better with a real value.
Drop it.

Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Link: https://lore.kernel.org/r/iwlwifi.20200424182644.6e566897ce0a.I8395a50c1c39522e542366064bff33a33009ce7b@changeid
2020-05-08 09:50:42 +03:00