diff mbox series

[3/3] ath9k_htc: increase number of configurable virtual interfaces

Message ID 1535997033-16330-3-git-send-email-pozega.tomislav@gmail.com (mailing list archive)
State Changes Requested
Delegated to: Kalle Valo
Headers show
Series [1/3] debug: use common debug for ack timeout output | expand

Commit Message

Tom Psyborg Sept. 3, 2018, 5:50 p.m. UTC
Increase driver limit for various interface combinations.
I was able to start 8 virtual APs and connect 5 clients to
these. Frimware support is required too, see:
https://github.com/qca/open-ath9k-htc-firmware/pull/149

Signed-off-by: Tomislav Požega <pozega.tomislav@gmail.com>
---
 drivers/net/wireless/ath/ath9k/htc.h          |    8 ++++----
 drivers/net/wireless/ath/ath9k/htc_drv_init.c |    6 +++---
 2 files changed, 7 insertions(+), 7 deletions(-)

Comments

Kalle Valo Sept. 4, 2018, 4:31 a.m. UTC | #1
Tomislav Požega <pozega.tomislav@gmail.com> writes:

> Increase driver limit for various interface combinations.
> I was able to start 8 virtual APs and connect 5 clients to
> these. Frimware support is required too, see:
> https://github.com/qca/open-ath9k-htc-firmware/pull/149

So what is the exact firmware version which has this support? Is it
available from linux-firmware.git?

And what about people using older firmware? Now it's easy to use a
unsupported configuration with those firmware images. The best would be
that ath9k could somehow detect what features the firmware supports.
diff mbox series

Patch

diff --git a/drivers/net/wireless/ath/ath9k/htc.h b/drivers/net/wireless/ath/ath9k/htc.h
index 5490c5f..b6c577b 100644
--- a/drivers/net/wireless/ath/ath9k/htc.h
+++ b/drivers/net/wireless/ath/ath9k/htc.h
@@ -197,8 +197,8 @@  struct ath9k_htc_target_rx_stats {
 	__be32 host_done;
 } __packed;
 
-#define ATH9K_HTC_MAX_VIF 2
-#define ATH9K_HTC_MAX_BCN_VIF 2
+#define ATH9K_HTC_MAX_VIF 8
+#define ATH9K_HTC_MAX_BCN_VIF 8
 
 #define INC_VIF(_priv, _type) do {		\
 		switch (_type) {		\
@@ -251,8 +251,8 @@  struct ath9k_vif_iter_data {
 	u8 mask[ETH_ALEN];
 };
 
-#define ATH9K_HTC_MAX_STA 8
-#define ATH9K_HTC_MAX_TID 8
+#define ATH9K_HTC_MAX_STA 128
+#define ATH9K_HTC_MAX_TID 16
 
 enum tid_aggr_state {
 	AGGR_STOP = 0,
diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_init.c b/drivers/net/wireless/ath/ath9k/htc_drv_init.c
index 214c682..fa13ba9 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_init.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_init.c
@@ -697,9 +697,9 @@  static int ath9k_init_priv(struct ath9k_htc_priv *priv,
 }
 
 static const struct ieee80211_iface_limit if_limits[] = {
-	{ .max = 2,	.types = BIT(NL80211_IFTYPE_STATION) |
+	{ .max = 8,	.types = BIT(NL80211_IFTYPE_STATION) |
 				 BIT(NL80211_IFTYPE_P2P_CLIENT) },
-	{ .max = 2,	.types = BIT(NL80211_IFTYPE_AP) |
+	{ .max = 8,	.types = BIT(NL80211_IFTYPE_AP) |
 #ifdef CONFIG_MAC80211_MESH
 				 BIT(NL80211_IFTYPE_MESH_POINT) |
 #endif
@@ -709,7 +709,7 @@  static int ath9k_init_priv(struct ath9k_htc_priv *priv,
 static const struct ieee80211_iface_combination if_comb = {
 	.limits = if_limits,
 	.n_limits = ARRAY_SIZE(if_limits),
-	.max_interfaces = 2,
+	.max_interfaces = 8,
 	.num_different_channels = 1,
 };