Commit 5c38beda authored by Johannes Berg's avatar Johannes Berg

wifi: iwlwifi: mvm: unify and fix interface combinations

AP interfaces fundamentally cannot leave the channel, so multi-
channel operation with them isn't really possible. We shouldn't
advertise support for such, at least not as long as we don't
have full multi-radio support. Thus, remove the AP bit from the
interface combinations for two channels and add another set for
just one channel that has it.

Also, to avoid duplicating everything even more, unify the NAN
and non-NAN cases.
Signed-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
Reviewed-by: default avatarIlan Peer <ilan.peer@intel.com>
Signed-off-by: default avatarMiri Korenblit <miriam.rachel.korenblit@intel.com>
Link: https://patch.msgid.link/20240618200104.3213638262ef.I2a0031b37623d7763fd0c5405477ea7206a3e923@changeidSigned-off-by: default avatarJohannes Berg <johannes.berg@intel.com>
parent d1621b00
...@@ -30,21 +30,28 @@ ...@@ -30,21 +30,28 @@
#include "iwl-nvm-parse.h" #include "iwl-nvm-parse.h"
#include "time-sync.h" #include "time-sync.h"
#define IWL_MVM_LIMITS(ap) \
{ \
.max = 1, \
.types = BIT(NL80211_IFTYPE_STATION), \
}, \
{ \
.max = 1, \
.types = ap | \
BIT(NL80211_IFTYPE_P2P_CLIENT) | \
BIT(NL80211_IFTYPE_P2P_GO), \
}, \
{ \
.max = 1, \
.types = BIT(NL80211_IFTYPE_P2P_DEVICE), \
}
static const struct ieee80211_iface_limit iwl_mvm_limits[] = { static const struct ieee80211_iface_limit iwl_mvm_limits[] = {
{ IWL_MVM_LIMITS(0)
.max = 1, };
.types = BIT(NL80211_IFTYPE_STATION),
}, static const struct ieee80211_iface_limit iwl_mvm_limits_ap[] = {
{ IWL_MVM_LIMITS(BIT(NL80211_IFTYPE_AP))
.max = 1,
.types = BIT(NL80211_IFTYPE_AP) |
BIT(NL80211_IFTYPE_P2P_CLIENT) |
BIT(NL80211_IFTYPE_P2P_GO),
},
{
.max = 1,
.types = BIT(NL80211_IFTYPE_P2P_DEVICE),
},
}; };
static const struct ieee80211_iface_combination iwl_mvm_iface_combinations[] = { static const struct ieee80211_iface_combination iwl_mvm_iface_combinations[] = {
...@@ -52,7 +59,13 @@ static const struct ieee80211_iface_combination iwl_mvm_iface_combinations[] = { ...@@ -52,7 +59,13 @@ static const struct ieee80211_iface_combination iwl_mvm_iface_combinations[] = {
.num_different_channels = 2, .num_different_channels = 2,
.max_interfaces = 3, .max_interfaces = 3,
.limits = iwl_mvm_limits, .limits = iwl_mvm_limits,
.n_limits = ARRAY_SIZE(iwl_mvm_limits), .n_limits = ARRAY_SIZE(iwl_mvm_limits) - 1,
},
{
.num_different_channels = 1,
.max_interfaces = 3,
.limits = iwl_mvm_limits_ap,
.n_limits = ARRAY_SIZE(iwl_mvm_limits_ap) - 1,
}, },
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment