From: Pavel Roskin Date: Mon, 28 May 2007 16:38:47 +0000 (-0700) Subject: [PATCH] hostap: Suppress broadcast if no stations are associated X-Git-Tag: v2.6.23-rc1~1201^2~63 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b918099030fe6cc093a7d60a88039bd98f16538e;p=linux-2.6 [PATCH] hostap: Suppress broadcast if no stations are associated This may be useful in mesh setups when most stations act as repeaters only. Signed-off-by: Pavel Roskin Signed-off-by: Jouni Malinen Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/hostap/hostap_ap.c b/drivers/net/wireless/hostap/hostap_ap.c index 5b3abd54d0..d169529b90 100644 --- a/drivers/net/wireless/hostap/hostap_ap.c +++ b/drivers/net/wireless/hostap/hostap_ap.c @@ -2704,6 +2704,8 @@ ap_tx_ret hostap_handle_sta_tx(local_info_t *local, struct hostap_tx_data *tx) if (hdr->addr1[0] & 0x01) { /* broadcast/multicast frame - no AP related processing */ + if (local->ap->num_sta <= 0) + ret = AP_TX_DROP; goto out; }