Linux bluetooth development
 help / color / mirror / Atom feed
* [PATCH BlueZ v2 0/6] monitor: Decode Periodic Advertising with Responses
@ 2026-11-19  7:13 Roland Schober
  2026-11-19  7:13 ` [PATCH BlueZ v2 1/6] monitor: Fix handle decoding of status_handle_rsp Roland Schober
                   ` (5 more replies)
  0 siblings, 6 replies; 8+ messages in thread
From: Roland Schober @ 2026-11-19  7:13 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: Roland Schober

This series teaches btmon the HCI commands and events of Periodic
Advertising with Responses (PAwR, Bluetooth 5.4). Until now they were
only listed by name in the opcode table and the events were printed as
unknown.

It is meant as the first step towards supporting the PAwR advertiser
role in the kernel and in BlueZ, which is what an access point of the
Electronic Shelf Label profile needs: being able to read the traces
comes before changing anything else.

Patches 1 to 3 fix existing decoders found on the way:
 - the Connection_Handle returned by the Periodic Advertising Sync
   Transfer commands and by LE Remove ISO Data Path was read as one
   octet,
 - LE Periodic Advertising Report trusted Data_Length and
   LE Extended Create Connection trusted the number of PHY parameter
   blocks, so truncated packets made them decode octets outside the
   packet.

Patch 4 splits the LE Periodic Advertising Report decoding into
helpers without changing its output, so that patch 6 can share it.

Patch 5 decodes the five commands and patch 6 the six events,
including the [v2] variants of existing events.

Testing: I have no controller with PAwR support at hand yet. The
commands were sent with hcitool to a controller which rejects them, so
that btmon decodes what the host sent, and the events and the
successful command responses were decoded from hand-made btsnoop
traces, well formed and truncated ones. The output for well formed
packets of the existing decoders was compared with the current tree.

v2:
 - Add patches 2 and 3. The two problems Copilot found in v1 were in
   the [v2] decoders, but they came from the [v1] decoders they reuse,
   so they are fixed there.
 - Patch 4 keeps the new Data_Length check in the shared helper.

Roland Schober (6):
  monitor: Fix handle decoding of status_handle_rsp
  monitor: Fix data length of LE PA Report decoding
  monitor: Fix PHY decoding of LE Ext Create Connection
  monitor: Split LE PA Report decoding into helpers
  monitor: Add PAwR HCI commands decoding
  monitor: Add PAwR HCI events decoding

 monitor/analyze.c |   1 +
 monitor/bt.h      | 174 ++++++++++++++++
 monitor/packet.c  | 510 ++++++++++++++++++++++++++++++++++++++++++----
 3 files changed, 646 insertions(+), 39 deletions(-)

-- 
2.47.3


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

end of thread, other threads:[~2026-11-19  9:41 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-19  7:13 [PATCH BlueZ v2 0/6] monitor: Decode Periodic Advertising with Responses Roland Schober
2026-11-19  7:13 ` [PATCH BlueZ v2 1/6] monitor: Fix handle decoding of status_handle_rsp Roland Schober
2026-11-19  9:41   ` monitor: Decode Periodic Advertising with Responses bluez.test.bot
2026-11-19  7:13 ` [PATCH BlueZ v2 2/6] monitor: Fix data length of LE PA Report decoding Roland Schober
2026-11-19  7:13 ` [PATCH BlueZ v2 3/6] monitor: Fix PHY decoding of LE Ext Create Connection Roland Schober
2026-11-19  7:13 ` [PATCH BlueZ v2 4/6] monitor: Split LE PA Report decoding into helpers Roland Schober
2026-11-19  7:13 ` [PATCH BlueZ v2 5/6] monitor: Add PAwR HCI commands decoding Roland Schober
2026-11-19  7:13 ` [PATCH BlueZ v2 6/6] monitor: Add PAwR HCI events decoding Roland Schober

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox