aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant/mesh_mpm.c
diff options
context:
space:
mode:
authorMasashi Honma <masashi.honma@gmail.com>2014-12-20 23:57:15 (GMT)
committerJouni Malinen <j@w1.fi>2014-12-21 21:55:44 (GMT)
commit46e8d90f6a8ba29ccd1ef2b9b951f9ca3aaa93b2 (patch)
tree7220128d2ba3bf6b625b695a92948a803ca32935 /wpa_supplicant/mesh_mpm.c
parent4b4093686bf0e2ce198e0d66cdae000f6e581013 (diff)
downloadhostap-46e8d90f6a8ba29ccd1ef2b9b951f9ca3aaa93b2.zip
hostap-46e8d90f6a8ba29ccd1ef2b9b951f9ca3aaa93b2.tar.gz
hostap-46e8d90f6a8ba29ccd1ef2b9b951f9ca3aaa93b2.tar.bz2
mesh: Add debug message when peering limit is reached
Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
Diffstat (limited to 'wpa_supplicant/mesh_mpm.c')
-rw-r--r--wpa_supplicant/mesh_mpm.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/wpa_supplicant/mesh_mpm.c b/wpa_supplicant/mesh_mpm.c
index 3b931f8..6d08f48 100644
--- a/wpa_supplicant/mesh_mpm.c
+++ b/wpa_supplicant/mesh_mpm.c
@@ -938,8 +938,12 @@ void mesh_mpm_action_rx(struct wpa_supplicant *wpa_s,
/* Now we will figure out the appropriate event... */
switch (action_field) {
case PLINK_OPEN:
- if (!plink_free_count(hapd) ||
- (sta->peer_lid && sta->peer_lid != plid)) {
+ if (plink_free_count(hapd) == 0) {
+ event = OPN_IGNR;
+ wpa_printf(MSG_INFO,
+ "MPM: Peer link num over quota(%d)",
+ hapd->max_plinks);
+ } else if (sta->peer_lid && sta->peer_lid != plid) {
event = OPN_IGNR;
} else {
sta->peer_lid = plid;
@@ -947,9 +951,13 @@ void mesh_mpm_action_rx(struct wpa_supplicant *wpa_s,
}
break;
case PLINK_CONFIRM:
- if (!plink_free_count(hapd) ||
- sta->my_lid != llid ||
- (sta->peer_lid && sta->peer_lid != plid)) {
+ if (plink_free_count(hapd) == 0) {
+ event = CNF_IGNR;
+ wpa_printf(MSG_INFO,
+ "MPM: Peer link num over quota(%d)",
+ hapd->max_plinks);
+ } else if (sta->my_lid != llid ||
+ (sta->peer_lid && sta->peer_lid != plid)) {
event = CNF_IGNR;
} else {
if (!sta->peer_lid)