linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/6] add support for parsing ERP information element
@ 2009-05-04  8:48 Marcel Holtmann
  2009-05-04  8:48 ` [PATCH 2/6] add basic support for parsing country " Marcel Holtmann
  0 siblings, 1 reply; 6+ messages in thread
From: Marcel Holtmann @ 2009-05-04  8:48 UTC (permalink / raw)
  To: Johannes Berg; +Cc: linux-wireless, Marcel Holtmann

---
 scan.c |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/scan.c b/scan.c
index 91e94ed..d4a4832 100644
--- a/scan.c
+++ b/scan.c
@@ -80,11 +80,27 @@ static void print_ign(unsigned char type, unsigned char len, unsigned char *data
 	/* ignore for now, not too useful */
 }
 
+static void print_erp(unsigned char type, unsigned char len, unsigned char *data)
+{
+	if (data[0] == 0x00)
+		return;
+
+	printf("\tERP:");
+	if (data[0] & 0x01)
+		printf(" NonERP_Present");
+	if (data[0] & 0x02)
+		printf(" Use_Protection");
+	if (data[0] & 0x04)
+		printf(" Barker_Preamble_Mode");
+	printf("\n");
+}
+
 static const printfn ieprinters[] = {
 	[0] = print_ssid,
 	[1] = print_supprates,
 	[3] = print_ds,
 	[5] = print_ign,
+	[42] = print_erp,
 	[50] = print_supprates,
 };
 
-- 
1.6.0.6


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2009-05-04  8:49 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-05-04  8:48 [PATCH 1/6] add support for parsing ERP information element Marcel Holtmann
2009-05-04  8:48 ` [PATCH 2/6] add basic support for parsing country " Marcel Holtmann
2009-05-04  8:48   ` [PATCH 3/6] add support for showing extended capabilities IE Marcel Holtmann
2009-05-04  8:48     ` [PATCH 4/6] add human readable decoding for capability information field Marcel Holtmann
2009-05-04  8:48       ` [PATCH 5/6] add basic support for parsing WMM information element Marcel Holtmann
2009-05-04  8:48         ` [PATCH 6/6] add support for parsing WPA and RSN/WPA2 information elements Marcel Holtmann

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).