diff options
author | Johannes Berg <johannes.berg@intel.com> | 2024-02-18 19:51:44 +0200 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2024-02-21 15:19:04 +0100 |
commit | 9a43c1902e56231fcf11780d7e2015638ff43cca (patch) | |
tree | 29f0306a6fa5fa80e308195b0a74171a3c1557f9 | |
parent | 3eab2034364dc446d3ccd0bee15af681638fcb9d (diff) | |
download | lwn-9a43c1902e56231fcf11780d7e2015638ff43cca.tar.gz lwn-9a43c1902e56231fcf11780d7e2015638ff43cca.zip |
wifi: iwlwifi: mvm: support PHY context version 6
Fill the new puncture mask in the PHY context command if
supported. In this case, also don't send it in the link
context command.
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://msgid.link/20240218194912.16d9f5fc41df.I9eeb55787d8483f820f5790e8874761f598da314@changeid
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/mvm/link.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c | 5 |
2 files changed, 6 insertions, 2 deletions
diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/link.c b/drivers/net/wireless/intel/iwlwifi/mvm/link.c index 129eefcc45d6..f13f13e6b71a 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/link.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/link.c @@ -204,7 +204,8 @@ int iwl_mvm_link_changed(struct iwl_mvm *mvm, struct ieee80211_vif *vif, def = iwl_mvm_chanctx_def(mvm, ctx); if (iwlwifi_mod_params.disable_11be || - !link_conf->eht_support || !def) + !link_conf->eht_support || !def || + iwl_fw_lookup_cmd_ver(mvm->fw, PHY_CONTEXT_CMD, 1) >= 6) changes &= ~LINK_CONTEXT_MODIFY_EHT_PARAMS; else cmd.puncture_mask = cpu_to_le16(def->punctured); diff --git a/drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c b/drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c index 5db44514d025..ce264b386029 100644 --- a/drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c +++ b/drivers/net/wireless/intel/iwlwifi/mvm/phy-ctxt.c @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause /* - * Copyright (C) 2012-2014, 2018-2023 Intel Corporation + * Copyright (C) 2012-2014, 2018-2024 Intel Corporation * Copyright (C) 2013-2014 Intel Mobile Communications GmbH * Copyright (C) 2017 Intel Deutschland GmbH */ @@ -224,6 +224,9 @@ static int iwl_mvm_phy_ctxt_apply(struct iwl_mvm *mvm, cmd.sbb_ctrl_channel_loc = iwl_mvm_get_ctrl_pos(ap); } + if (ver == 6) + cmd.puncture_mask = cpu_to_le16(chandef->punctured); + ret = iwl_mvm_send_cmd_pdu(mvm, PHY_CONTEXT_CMD, 0, sizeof(cmd), &cmd); } else if (ver < 3) { |