[PATCH] hostapd: output BSS Color (he_bss_color) when using STATUS

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>From b68f1f04819236d8135d0ac5897bb4b413ebdec2 Mon Sep 17 00:00:00 2001
From: Antonio Prcela <antonio.prcela@xxxxxxxxx>
Date: Tue, 13 Jun 2023 16:20:29 +0200
Subject: [PATCH] hostapd: output BSS Color (he_bss_color) when using STATUS

WNM event only reports BSS color if a stations is associated with access-point.
This prints it always if BSS color set and if AX radio standard.

Signed-off-by: Antonio Prcela <antonio.prcela@xxxxxxxxx>
Signed-off-by: Antonio Prcela <antonio.prcela@xxxxxxxxxx>
---
 src/ap/ctrl_iface_ap.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/src/ap/ctrl_iface_ap.c b/src/ap/ctrl_iface_ap.c
index 6934a732a..630f00919 100644
--- a/src/ap/ctrl_iface_ap.c
+++ b/src/ap/ctrl_iface_ap.c
@@ -845,6 +845,15 @@ int hostapd_ctrl_iface_status(struct hostapd_data *hapd, char *buf,
 		if (os_snprintf_error(buflen - len, ret))
 			return len;
 		len += ret;
+
+		if (!iconf->he_op.he_bss_color_disabled && iconf->he_op.he_bss_color) {
+			ret = os_snprintf(buf + len, buflen - len,
+					"he_bss_color=%d\n",
+					iconf->he_op.he_bss_color);
+			if (os_snprintf_error(buflen - len, ret))
+				return len;
+			len += ret;
+		}
 	}
 #endif /* CONFIG_IEEE80211AX */
 
-- 
2.41.0
From b68f1f04819236d8135d0ac5897bb4b413ebdec2 Mon Sep 17 00:00:00 2001
From: Antonio Prcela <antonio.prcela@xxxxxxxxx>
Date: Tue, 13 Jun 2023 16:20:29 +0200
Subject: [PATCH] hostapd: output BSS Color (he_bss_color) when using STATUS

WNM event only reports BSS color if a stations is associated with access-point.
This prints it always if BSS color set and if AX radio standard.

Signed-off-by: Antonio Prcela <antonio.prcela@xxxxxxxxx>
Signed-off-by: Antonio Prcela <antonio.prcela@xxxxxxxxxx>
---
 src/ap/ctrl_iface_ap.c | 9 +++++++++
 1 file changed, 9 insertions(+)

diff --git a/src/ap/ctrl_iface_ap.c b/src/ap/ctrl_iface_ap.c
index 6934a732a..630f00919 100644
--- a/src/ap/ctrl_iface_ap.c
+++ b/src/ap/ctrl_iface_ap.c
@@ -845,6 +845,15 @@ int hostapd_ctrl_iface_status(struct hostapd_data *hapd, char *buf,
 		if (os_snprintf_error(buflen - len, ret))
 			return len;
 		len += ret;
+
+		if (!iconf->he_op.he_bss_color_disabled && iconf->he_op.he_bss_color) {
+			ret = os_snprintf(buf + len, buflen - len,
+					"he_bss_color=%d\n",
+					iconf->he_op.he_bss_color);
+			if (os_snprintf_error(buflen - len, ret))
+				return len;
+			len += ret;
+		}
 	}
 #endif /* CONFIG_IEEE80211AX */
 
-- 
2.41.0

_______________________________________________
Hostap mailing list
Hostap@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/hostap

[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux