[PATCH] hostapd: mask out LDPC for STA's VHT capabilities

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

 



If we don't support RX LDPC, mask out LDPC for TX in the STA's VHT caps.

Signed-off-by: Sarada Prasanna Garnayak <sarada.prasanna.garnayak@xxxxxxxxx>
---
 src/ap/ieee802_11_ht.c  | 7 +++++++
 src/ap/ieee802_11_vht.c | 7 +++++++
 2 files changed, 14 insertions(+)

diff --git a/src/ap/ieee802_11_ht.c b/src/ap/ieee802_11_ht.c
index 214855dcc..34506145f 100644
--- a/src/ap/ieee802_11_ht.c
+++ b/src/ap/ieee802_11_ht.c
@@ -542,6 +542,13 @@ void hostapd_get_ht_capab(struct hostapd_data *hapd,
 	if (!(hapd->iconf->ht_capab & HT_CAP_INFO_TX_STBC))
 		cap &= ~HT_CAP_INFO_RX_STBC_MASK;
 
+	/*
+	 * if we don't support RX LDPC, mask out LDPC for TX in
+	 * the STA's HT caps
+	 */
+	if (!(hapd->iconf->ht_capab & HT_CAP_INFO_LDPC_CODING_CAP))
+		cap &= ~HT_CAP_INFO_LDPC_CODING_CAP;
+
 	neg_ht_cap->ht_capabilities_info = host_to_le16(cap);
 }
 
diff --git a/src/ap/ieee802_11_vht.c b/src/ap/ieee802_11_vht.c
index 54ee080a4..183833060 100644
--- a/src/ap/ieee802_11_vht.c
+++ b/src/ap/ieee802_11_vht.c
@@ -513,5 +513,12 @@ void hostapd_get_vht_capab(struct hostapd_data *hapd,
 	if (!(own_cap & VHT_CAP_TXSTBC))
 		cap &= ~VHT_CAP_RXSTBC_MASK;
 
+	/*
+	 * if we don't support RX LDPC, mask out LDPC for TX in
+	 * the STA's VHT caps
+	 */
+	if (!(own_cap & VHT_CAP_RXLDPC))
+		cap &= ~VHT_CAP_RXLDPC;
+
 	neg_vht_cap->vht_capabilities_info = host_to_le32(cap);
 }
-- 
2.11.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