linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: greearb@gmail.com
To: linux-wireless@vger.kernel.org
Cc: Ben Greear <greearb@candelatech.com>
Subject: [mac80211] mac80211:  Support multiple VIFS per AP in debugfs.
Date: Mon, 20 Sep 2010 21:21:43 -0700	[thread overview]
Message-ID: <1285042903-19189-1-git-send-email-greearb@candelatech.com> (raw)

From: Ben Greear <greearb@candelatech.com>

MAC address of AP isn't unique..need to add the device
name as well.

Signed-off-by: Ben Greear <greearb@candelatech.com>
---
:100644 100644 76839d4... 4cf451c... M	net/mac80211/debugfs_sta.c
 net/mac80211/debugfs_sta.c |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/net/mac80211/debugfs_sta.c b/net/mac80211/debugfs_sta.c
index 76839d4..4cf451c 100644
--- a/net/mac80211/debugfs_sta.c
+++ b/net/mac80211/debugfs_sta.c
@@ -301,14 +301,18 @@ STA_OPS(ht_capa);
 void ieee80211_sta_debugfs_add(struct sta_info *sta)
 {
 	struct dentry *stations_dir = sta->local->debugfs.stations;
-	u8 mac[3*ETH_ALEN];
+	u8 mac[3*ETH_ALEN + IFNAMSIZ + 2];
 
 	sta->debugfs.add_has_run = true;
 
 	if (!stations_dir)
 		return;
 
-	snprintf(mac, sizeof(mac), "%pM", sta->sta.addr);
+	if (sta->sdata)
+		snprintf(mac, sizeof(mac), "%pM-%s",
+			 sta->sta.addr, sta->sdata->name);
+	else
+		snprintf(mac, sizeof(mac), "%pM-NULL", sta->sta.addr);
 
 	/*
 	 * This might fail due to a race condition:
-- 
1.7.2.2


             reply	other threads:[~2010-09-21  4:21 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-21  4:21 greearb [this message]
2010-09-21  6:48 ` [mac80211] mac80211: Support multiple VIFS per AP in debugfs Johannes Berg
2010-09-21 12:04   ` Ben Greear
  -- strict thread matches above, loose matches on Subject: below --
2010-09-21 12:15 greearb
2010-09-21 16:25 ` Ben Greear
2010-09-21 16:30   ` Johannes Berg
2010-09-21 16:42     ` Ben Greear
2010-09-21 17:03       ` Johannes Berg
2010-09-21 17:49         ` Johannes Berg
2010-09-21 18:02           ` Ben Greear
2010-09-22 16:59           ` Ben Greear
2010-09-22 17:01             ` Johannes Berg
2010-09-22 17:34               ` Ben Greear
2010-09-22 18:31                 ` Johannes Berg
2010-09-22 18:48                   ` John W. Linville
2010-09-22 19:45                     ` Ben Greear
2010-09-23  8:30                       ` Johannes Berg
2010-09-23 13:12                         ` Ben Greear
2010-09-23  3:29 greearb
2010-09-23  8:36 ` Johannes Berg
2010-10-16 19:00   ` Christian Lamparter
2010-10-18 20:05     ` Ben Greear
     [not found]     ` <4CDAF182.4030409@candelatech.com>
2010-11-10 20:01       ` Christian Lamparter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1285042903-19189-1-git-send-email-greearb@candelatech.com \
    --to=greearb@gmail.com \
    --cc=greearb@candelatech.com \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).