mirror of
https://git.kernel.org/pub/scm/bluetooth/bluez.git
synced 2024-12-13 14:04:12 +08:00
hcidump: Add parsing for ATT Prepare Write
This commit is contained in:
parent
87420ada41
commit
245bb41fd5
@ -507,6 +507,22 @@ static void att_signed_write_dump(int level, struct frame *frm)
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
static void att_prep_write_dump(int level, struct frame *frm)
|
||||
{
|
||||
uint16_t handle = btohs(htons(get_u16(frm)));
|
||||
uint16_t val_offset = btohs(htons(get_u16(frm)));
|
||||
|
||||
p_indent(level, frm);
|
||||
printf("attr handle 0x%4.4x, value offset 0x%4.4x\n", handle,
|
||||
val_offset);
|
||||
|
||||
p_indent(level, frm);
|
||||
printf("part attr value ");
|
||||
while (frm->len > 0)
|
||||
printf(" 0x%2.2x", get_u8(frm));
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
static void att_handle_notify_dump(int level, struct frame *frm)
|
||||
{
|
||||
uint16_t handle = btohs(htons(get_u16(frm)));
|
||||
@ -587,6 +603,10 @@ void att_dump(int level, struct frame *frm)
|
||||
case ATT_OP_SIGNED_WRITE_CMD:
|
||||
att_signed_write_dump(level + 1, frm);
|
||||
break;
|
||||
case ATT_OP_PREP_WRITE_REQ:
|
||||
case ATT_OP_PREP_WRITE_RESP:
|
||||
att_prep_write_dump(level + 1, frm);
|
||||
break;
|
||||
case ATT_OP_HANDLE_NOTIFY:
|
||||
att_handle_notify_dump(level + 1, frm);
|
||||
break;
|
||||
|
Loading…
Reference in New Issue
Block a user