* [PATCH] mac80211: rate limit WEP bad keyidx message
@ 2007-08-13 18:32 John W. Linville
0 siblings, 0 replies; only message in thread
From: John W. Linville @ 2007-08-13 18:32 UTC (permalink / raw)
To: linux-wireless; +Cc: jbenc, flamingice
Signed-off-by: John W. Linville <linville@tuxdriver.com>
---
net/mac80211/rx.c | 16 +++++++++-------
1 file changed, 9 insertions(+), 7 deletions(-)
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
index 0a10720..d74b6cb 100644
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -343,13 +343,15 @@ ieee80211_rx_h_load_key(struct ieee80211_txrx_data *rx)
if (!rx->key) {
if (!rx->u.rx.ra_match)
return TXRX_DROP;
- printk(KERN_DEBUG "%s: RX WEP frame with "
- "unknown keyidx %d (A1=" MAC_FMT " A2="
- MAC_FMT " A3=" MAC_FMT ")\n",
- rx->dev->name, keyidx,
- MAC_ARG(hdr->addr1),
- MAC_ARG(hdr->addr2),
- MAC_ARG(hdr->addr3));
+ if (net_ratelimit())
+ printk(KERN_DEBUG "%s: RX WEP frame "
+ "with unknown keyidx %d "
+ "(A1=" MAC_FMT " A2=" MAC_FMT
+ " A3=" MAC_FMT ")\n",
+ rx->dev->name, keyidx,
+ MAC_ARG(hdr->addr1),
+ MAC_ARG(hdr->addr2),
+ MAC_ARG(hdr->addr3));
if (!rx->local->apdev)
return TXRX_DROP;
ieee80211_rx_mgmt(
--
John W. Linville
linville@tuxdriver.com
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2007-08-13 19:07 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-13 18:32 [PATCH] mac80211: rate limit WEP bad keyidx message John W. Linville
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).