[PATCH 08/15] dfs: Add extra debugging messages.

greearb at candelatech.com greearb at candelatech.com
Wed Mar 5 19:19:53 EST 2014


From: Ben Greear <greearb at candelatech.com>

Might help someone realize why their hostapd config isn't
working properly.

Signed-off-by: Ben Greear <greearb at candelatech.com>
---
 src/ap/dfs.c |   18 ++++++++++++++++--
 1 files changed, 16 insertions(+), 2 deletions(-)

diff --git a/src/ap/dfs.c b/src/ap/dfs.c
index 2b8b90f..1fa9618 100644
--- a/src/ap/dfs.c
+++ b/src/ap/dfs.c
@@ -267,8 +267,22 @@ static int dfs_get_start_chan_idx(struct hostapd_iface *iface)
 		}
 	}
 
-	if (res == -1)
-		wpa_printf(MSG_DEBUG, "DFS chan_idx seems wrong: -1");
+	if (res == -1) {
+		wpa_printf(MSG_DEBUG,
+			   "DFS chan_idx seems wrong: -1 num-ch: %d ch-no: %d conf-ch-no: %d"
+			   " 11n: %d  sec-ch: %d vht-oper-width: %i",
+			   mode->num_channels, channel_no, iface->conf->channel,
+			   iface->conf->ieee80211n, iface->conf->secondary_channel,
+			   iface->conf->vht_oper_chwidth);
+
+		for (i = 0; i < mode->num_channels; i++) {
+			chan = &mode->channels[i];
+			wpa_printf(MSG_DEBUG,
+				   "Available channel: %d\n",
+				   chan->chan);
+		}
+	}
+
 
 	return res;
 }
-- 
1.7.3.4



More information about the HostAP mailing list