summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2015-09-05 20:40:44 +0300
committerJouni Malinen <j@w1.fi>2015-09-05 20:40:44 +0300
commitdcc8bc82e088b1253f16c2e302b767fb33525db3 (patch)
tree66f29628369bdc77edb5b7ea59d2023447d7bfdb
parent5c92d474e67729d58c35bcfd9f2b3f6b3b211d7d (diff)
downloadhostap-dcc8bc82e088b1253f16c2e302b767fb33525db3.tar.gz
Add BSS operating frequency to more debug messages
This makes it easier to analyze debug logs when figuring out channel related issues. Signed-off-by: Jouni Malinen <j@w1.fi>
-rw-r--r--wpa_supplicant/bss.c8
-rw-r--r--wpa_supplicant/events.c4
2 files changed, 8 insertions, 4 deletions
diff --git a/wpa_supplicant/bss.c b/wpa_supplicant/bss.c
index 6727c86e9..1051ee3a4 100644
--- a/wpa_supplicant/bss.c
+++ b/wpa_supplicant/bss.c
@@ -393,8 +393,9 @@ static struct wpa_bss * wpa_bss_add(struct wpa_supplicant *wpa_s,
dl_list_add_tail(&wpa_s->bss_id, &bss->list_id);
wpa_s->num_bss++;
wpa_dbg(wpa_s, MSG_DEBUG, "BSS: Add new id %u BSSID " MACSTR
- " SSID '%s'",
- bss->id, MAC2STR(bss->bssid), wpa_ssid_txt(ssid, ssid_len));
+ " SSID '%s' freq %d",
+ bss->id, MAC2STR(bss->bssid), wpa_ssid_txt(ssid, ssid_len),
+ bss->freq);
wpas_notify_bss_added(wpa_s, bss->bssid, bss->id);
return bss;
}
@@ -537,6 +538,9 @@ wpa_bss_update(struct wpa_supplicant *wpa_s, struct wpa_bss *bss,
u32 changes;
changes = wpa_bss_compare_res(bss, res);
+ if (changes & WPA_BSS_FREQ_CHANGED_FLAG)
+ wpa_printf(MSG_DEBUG, "BSS: " MACSTR " changed freq %d --> %d",
+ MAC2STR(bss->bssid), bss->freq, res->freq);
bss->scan_miss_count = 0;
bss->last_update_idx = wpa_s->bss_update_idx;
wpa_bss_copy_res(bss, res, fetch_time);
diff --git a/wpa_supplicant/events.c b/wpa_supplicant/events.c
index 4f082d2a9..0777a5628 100644
--- a/wpa_supplicant/events.c
+++ b/wpa_supplicant/events.c
@@ -828,9 +828,9 @@ static struct wpa_ssid * wpa_scan_res_match(struct wpa_supplicant *wpa_s,
osen = ie != NULL;
wpa_dbg(wpa_s, MSG_DEBUG, "%d: " MACSTR " ssid='%s' "
- "wpa_ie_len=%u rsn_ie_len=%u caps=0x%x level=%d%s%s%s",
+ "wpa_ie_len=%u rsn_ie_len=%u caps=0x%x level=%d freq=%d %s%s%s",
i, MAC2STR(bss->bssid), wpa_ssid_txt(bss->ssid, bss->ssid_len),
- wpa_ie_len, rsn_ie_len, bss->caps, bss->level,
+ wpa_ie_len, rsn_ie_len, bss->caps, bss->level, bss->freq,
wpa_bss_get_vendor_ie(bss, WPS_IE_VENDOR_TYPE) ? " wps" : "",
(wpa_bss_get_vendor_ie(bss, P2P_IE_VENDOR_TYPE) ||
wpa_bss_get_vendor_ie_beacon(bss, P2P_IE_VENDOR_TYPE)) ?