Diff between cfb24cb6c34d1d43088fbe11d30ca48ecc6fba87 and ae722e690ffec917ffbfd026f3be0ead2b67f119

Changed Files

File Additions Deletions Status
tools/hcidump.1 +1 -4 modified
tools/hcidump.c +6 -19 modified
tools/parser/parser.h +1 -1 modified

Full Patch

diff --git a/tools/hcidump.1 b/tools/hcidump.1
index 062f8d4..9cc22c8 100644
--- a/tools/hcidump.1
+++ b/tools/hcidump.1
@@ -77,10 +77,7 @@ For every packet, not only is the packet type displayed, but also all data in he
 For every packet, not only is the packet type displayed, but also all data in hex and ASCII.
 .TP
 .BR -R ", " "\-\^\-raw"
-Raw mode: do not display packet type, only data.
-.TP
-.BR -B ", " "\-\^\-bpa"
-BPA mode: only display vendor specific data packets.
+For every packet, only the raw data is displayed.
 .TP
 .BR -C ", " "\-\^\-cmtp"
 Sets the PSM value for the CAPI Message Transport Protocol
diff --git a/tools/hcidump.c b/tools/hcidump.c
index 880c8f3..335d815 100644
--- a/tools/hcidump.c
+++ b/tools/hcidump.c
@@ -283,15 +283,8 @@ static int open_socket(int dev, unsigned long flags)
 
 	/* Setup filter */
 	hci_filter_clear(&flt);
-	if (flags & DUMP_BPA) {
-		hci_filter_set_ptype(HCI_VENDOR_PKT, &flt);
-		hci_filter_set_ptype(HCI_EVENT_PKT, &flt);
-		hci_filter_set_event(EVT_VENDOR, &flt);
-	} else {
-		hci_filter_all_ptypes(&flt);
-		hci_filter_all_events(&flt);
-		hci_filter_clear_ptype(HCI_VENDOR_PKT, &flt);
-	}
+	hci_filter_all_ptypes(&flt);
+	hci_filter_all_events(&flt);
 	if (setsockopt(sk, SOL_HCI, HCI_FILTER, &flt, sizeof(flt)) < 0) {
 		perror("Can't set HCI filter");
 		exit(1);
@@ -410,6 +403,8 @@ static struct {
 	{ "avdtp",	FILT_AVDTP	},
 	{ "obex",	FILT_OBEX	},
 	{ "capi",	FILT_CAPI	},
+	{ "csr",	FILT_CSR	},
+	{ "dga",	FILT_DGA	},
 	{ 0 }
 };
 
@@ -443,8 +438,7 @@ static void usage(void)
 	"  -a, --ascii                Dump data in ascii\n"
 	"  -x, --hex                  Dump data in hex\n"
 	"  -X, --ext                  Dump data in hex and ascii\n"
-	"  -R, --raw                  Raw mode\n"
-	"  -B, --bpa                  BPA mode\n"
+	"  -R, --raw                  Dump raw data\n"
 	"  -C, --cmtp=psm             PSM for CMTP\n"
 	"  -H, --hcrp=psm             PSM for HCRP\n"
 	"  -O, --obex=channel         Channel for OBEX\n"
@@ -468,7 +462,6 @@ static struct option main_options[] = {
 	{ "hex",		0, 0, 'x' },
 	{ "ext",		0, 0, 'X' },
 	{ "raw",		0, 0, 'R' },
-	{ "bpa",		0, 0, 'B' },
 	{ "cmtp",		1, 0, 'C' },
 	{ "hcrp",		1, 0, 'H' },
 	{ "obex",		1, 0, 'O' },
@@ -485,7 +478,7 @@ int main(int argc, char *argv[])
 
 	printf("HCI sniffer - Bluetooth packet analyzer ver %s\n", VERSION);
 
-	while ((opt=getopt_long(argc, argv, "i:l:p:m:w:r:s:n:taxXRBC:H:O:Vh", main_options, NULL)) != -1) {
+	while ((opt=getopt_long(argc, argv, "i:l:p:m:w:r:s:n:taxXRC:H:O:Vh", main_options, NULL)) != -1) {
 		switch(opt) {
 		case 'i':
 			device = atoi(optarg + 3);
@@ -559,12 +552,6 @@ int main(int argc, char *argv[])
 			flags |= DUMP_RAW;
 			break;
 
-		case 'B':
-			flags |= DUMP_BPA;
-			if (defcompid == DEFAULT_COMPID)
-				defcompid = 12;
-			break;
-
 		case 'C': 
 			set_proto(0, atoi(optarg), 0, SDP_UUID_CMTP);
 			break;
diff --git a/tools/parser/parser.h b/tools/parser/parser.h
index 6409e38..ef0cdb1 100644
--- a/tools/parser/parser.h
+++ b/tools/parser/parser.h
@@ -74,7 +74,7 @@ struct frame {
 #define FILT_OBEX	0x00010000
 #define FILT_CAPI	0x00020000
 #define FILT_CSR	0x1000000a
-#define FILT_BPA	0x1000000f
+#define FILT_DGA	0x1000000c
 
 #define STRUCT_OFFSET(type, member)  ((uint8_t *)&(((type *)NULL)->member) - \
                                      (uint8_t *)((type *)NULL))