diff options
author | Andrei Emeltchenko <andrei.emeltchenko@intel.com> | 2012-08-31 10:37:20 +0300 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2012-12-17 23:53:08 +0100 |
commit | 7c2544bd8426b32aae63f285216b45933e8d9ebc (patch) | |
tree | 475fdbf97aeb9e59ab79619557f44a912999f2f3 | |
parent | d94ff6e9e3493f46a28909ddc1d144150d9df7e0 (diff) |
hcidump: Decode Num Completed Data Blocks
Adds decoding Number Of Completed Data Blocks Event
> HCI Event: Number Of Completed Data Blocks (0x48) plen 9
Total num blocks 4 Num handles 1
Handle 0x0001: Num complt pkts 1 Num complt blks 1
-rw-r--r-- | tools/parser/hci.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/tools/parser/hci.c b/tools/parser/hci.c index 704e80e90..9a4d15fb8 100644 --- a/tools/parser/hci.c +++ b/tools/parser/hci.c @@ -3721,6 +3721,25 @@ static inline void flow_spec_modify_dump(int level, struct frame *frm) } } +static inline void num_completed_blocks_dump(int level, struct frame *frm) +{ + evt_num_completed_blocks *evt = frm->ptr; + int i; + + p_indent(level, frm); + printf("Total num blocks %d Num handles %d\n", + btohs(evt->total_num_blocks), evt->num_handles); + + for (i = 0; i < evt->num_handles; i++) { + cmplt_handle *h = &evt->handles[i]; + + p_indent(level + 1, frm); + printf("Handle 0x%4.4x: Num complt pkts %d Num complt blks %d\n", + btohs(h->handle), btohs(h->num_cmplt_pkts), + btohs(h->num_cmplt_blks)); + } +} + static inline void event_dump(int level, struct frame *frm) { hci_event_hdr *hdr = frm->ptr; @@ -3947,6 +3966,9 @@ static inline void event_dump(int level, struct frame *frm) case EVT_FLOW_SPEC_MODIFY_COMPLETE: flow_spec_modify_dump(level + 1, frm); break; + case EVT_NUMBER_COMPLETED_BLOCKS: + num_completed_blocks_dump(level + 1, frm); + break; default: raw_dump(level, frm); break; |