mirror of
https://github.com/torvalds/linux.git
synced 2026-07-28 01:55:51 +02:00
wifi: iwlwifi: mld: allow NAN data
Allow NAN_DATA interfaces when FW supports it. Link: https://patch.msgid.link/20260511203428.c47453e9329a.I4a250a0df0ca0d184eb6ac84a4a9fcc3491e9e66@changeid Signed-off-by: Miri Korenblit <miriam.rachel.korenblit@intel.com>
This commit is contained in:
parent
bc2f28ead2
commit
b0bb915f75
|
|
@ -62,13 +62,17 @@ static const struct ieee80211_iface_limit iwl_mld_limits_ap[] = {
|
|||
|
||||
static const struct ieee80211_iface_limit iwl_mld_limits_nan[] = {
|
||||
{
|
||||
.max = 2,
|
||||
.max = 1,
|
||||
.types = BIT(NL80211_IFTYPE_STATION),
|
||||
},
|
||||
{
|
||||
.max = 1,
|
||||
.types = BIT(NL80211_IFTYPE_NAN),
|
||||
},
|
||||
{
|
||||
.max = 2,
|
||||
.types = BIT(NL80211_IFTYPE_NAN_DATA),
|
||||
},
|
||||
};
|
||||
|
||||
static const struct ieee80211_iface_combination
|
||||
|
|
@ -87,8 +91,8 @@ iwl_mld_iface_combinations[] = {
|
|||
},
|
||||
/* NAN combination follow, this excludes P2P and AP */
|
||||
{
|
||||
.num_different_channels = 2,
|
||||
.max_interfaces = 3,
|
||||
.num_different_channels = 3,
|
||||
.max_interfaces = 4,
|
||||
.limits = iwl_mld_limits_nan,
|
||||
.n_limits = ARRAY_SIZE(iwl_mld_limits_nan),
|
||||
},
|
||||
|
|
@ -266,6 +270,7 @@ static void iwl_mld_hw_set_nan(struct iwl_mld *mld)
|
|||
struct ieee80211_hw *hw = mld->hw;
|
||||
|
||||
hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_NAN);
|
||||
hw->wiphy->interface_modes |= BIT(NL80211_IFTYPE_NAN_DATA);
|
||||
|
||||
hw->wiphy->nan_supported_bands = BIT(NL80211_BAND_2GHZ);
|
||||
if (mld->nvm_data->bands[NL80211_BAND_5GHZ].n_channels)
|
||||
|
|
@ -363,7 +368,7 @@ static void iwl_mac_hw_set_wiphy(struct iwl_mld *mld)
|
|||
ARRAY_SIZE(iwl_mld_iface_combinations);
|
||||
iwl_mld_hw_set_nan(mld);
|
||||
} else {
|
||||
/* Do not include NAN combinations */
|
||||
/* Do not include NAN combination */
|
||||
wiphy->n_iface_combinations =
|
||||
ARRAY_SIZE(iwl_mld_iface_combinations) - 1;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,8 +18,16 @@
|
|||
|
||||
bool iwl_mld_nan_supported(struct iwl_mld *mld)
|
||||
{
|
||||
return fw_has_capa(&mld->fw->ucode_capa,
|
||||
IWL_UCODE_TLV_CAPA_NAN_SYNC_SUPPORT);
|
||||
const struct iwl_fw *fw = mld->fw;
|
||||
|
||||
if (fw_has_capa(&fw->ucode_capa, IWL_UCODE_TLV_CAPA_NAN_SYNC_SUPPORT) &&
|
||||
iwl_fw_lookup_cmd_ver(fw, WIDE_ID(MAC_CONF_GROUP, NAN_SCHEDULE_CMD), 0) >= 1 &&
|
||||
iwl_fw_lookup_cmd_ver(fw, WIDE_ID(MAC_CONF_GROUP, NAN_PEER_CMD), 0) >= 1 &&
|
||||
iwl_fw_lookup_cmd_ver(fw, WIDE_ID(MAC_CONF_GROUP, STA_CONFIG_CMD), 0) >= 3 &&
|
||||
iwl_fw_lookup_cmd_ver(fw, WIDE_ID(MAC_CONF_GROUP, MAC_CONFIG_CMD), 0) >= 4 &&
|
||||
iwl_fw_lookup_cmd_ver(fw, WIDE_ID(DATA_PATH_GROUP, TLC_MNG_CONFIG_CMD), 0) >= 6)
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
static int iwl_mld_nan_send_config_cmd(struct iwl_mld *mld,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user