diff options
author | Joe Perches <joe@perches.com> | 2007-10-03 20:59:30 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-10-10 19:51:42 -0400 |
commit | 0795af5729b18218767fab27c44b1384f72dc9ad (patch) | |
tree | 67c16df84aa6ec219340b8ea1b5cfb0e8150a216 /net/mac80211/event.c | |
parent | 95ea36275f3c9a1d3d04c217b4b576c657c4e70e (diff) |
[NET]: Introduce and use print_mac() and DECLARE_MAC_BUF()
This is nicer than the MAC_FMT stuff.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/mac80211/event.c')
-rw-r--r-- | net/mac80211/event.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/net/mac80211/event.c b/net/mac80211/event.c index 68a526cb7623..2280f40b4560 100644 --- a/net/mac80211/event.c +++ b/net/mac80211/event.c | |||
@@ -22,13 +22,14 @@ void mac80211_ev_michael_mic_failure(struct net_device *dev, int keyidx, | |||
22 | { | 22 | { |
23 | union iwreq_data wrqu; | 23 | union iwreq_data wrqu; |
24 | char *buf = kmalloc(128, GFP_ATOMIC); | 24 | char *buf = kmalloc(128, GFP_ATOMIC); |
25 | DECLARE_MAC_BUF(mac); | ||
25 | 26 | ||
26 | if (buf) { | 27 | if (buf) { |
27 | /* TODO: needed parameters: count, key type, TSC */ | 28 | /* TODO: needed parameters: count, key type, TSC */ |
28 | sprintf(buf, "MLME-MICHAELMICFAILURE.indication(" | 29 | sprintf(buf, "MLME-MICHAELMICFAILURE.indication(" |
29 | "keyid=%d %scast addr=" MAC_FMT ")", | 30 | "keyid=%d %scast addr=%s)", |
30 | keyidx, hdr->addr1[0] & 0x01 ? "broad" : "uni", | 31 | keyidx, hdr->addr1[0] & 0x01 ? "broad" : "uni", |
31 | MAC_ARG(hdr->addr2)); | 32 | print_mac(mac, hdr->addr2)); |
32 | memset(&wrqu, 0, sizeof(wrqu)); | 33 | memset(&wrqu, 0, sizeof(wrqu)); |
33 | wrqu.data.length = strlen(buf); | 34 | wrqu.data.length = strlen(buf); |
34 | wireless_send_event(dev, IWEVCUSTOM, &wrqu, buf); | 35 | wireless_send_event(dev, IWEVCUSTOM, &wrqu, buf); |