]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
wifi: iwlwifi: mvm: handle version 3 GET_TAS_STATUS notification
authorAnjaneyulu <pagadala.yesu.anjaneyulu@intel.com>
Tue, 31 Dec 2024 11:59:11 +0000 (13:59 +0200)
committerJohannes Berg <johannes.berg@intel.com>
Mon, 13 Jan 2025 14:34:07 +0000 (15:34 +0100)
Add a check to ensure only version-3 of GET_TAS_STATUS notification
is allowed.

Signed-off-by: Anjaneyulu <pagadala.yesu.anjaneyulu@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20241231135726.1d571ac80957.Ia48b1cf5585a2a9f9c461e80f5a0ba2bb16c3af4@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/intel/iwlwifi/mvm/debugfs.c

index 6ec1cae5314a5e557f7772b9625327e767ab52b2..f6f5117b93c0e8a9be9d05afb0b06008edf0773d 100644 (file)
@@ -579,6 +579,10 @@ static ssize_t iwl_dbgfs_tas_get_status_read(struct file *file,
        if (!iwl_mvm_firmware_running(mvm))
                return -ENODEV;
 
+       if (iwl_fw_lookup_notif_ver(mvm->fw, DEBUG_GROUP, GET_TAS_STATUS,
+                                   0) != 3)
+               return -EOPNOTSUPP;
+
        mutex_lock(&mvm->mutex);
        ret = iwl_mvm_send_cmd(mvm, &hcmd);
        mutex_unlock(&mvm->mutex);