Linux bluetooth development
 help / color / mirror / Atom feed
From: Kevin Dewald <kevin@simpleble.org>
To: linux-bluetooth@vger.kernel.org
Cc: Luiz Augusto von Dentz <luiz.dentz@gmail.com>,
	Kevin Dewald <kevin@simpleble.org>
Subject: [PATCH BlueZ 0/5] Add LE connection parameters to org.bluez.Bearer.LE1
Date: Mon,  2 Nov 2026 23:27:44 -0800	[thread overview]
Message-ID: <20261103072749.50979-1-kevin@simpleble.org> (raw)

Applications have no way to know the parameters of an LE connection:
the interval, peripheral latency and supervision timeout. They decide
how fast data can move and how quickly a lost link is noticed, so
applications that need them end up reading them from HCI traffic.

This adds Interval, Latency, SupervisionTimeout and Subrate properties
to org.bluez.Bearer.LE1, filled from the MGMT Connection Subrate event,
which bluetoothd already registers but only logs. With "Bluetooth: MGMT:
Send Connection Subrate on LE connection and update", now in
bluetooth-next, the kernel sends that event when an LE connection is
established and after each LE Connection Update, not only on LE
Connection Rate Change.

The properties are only present while connected over LE. Interval is in
microseconds, as with Shorter Connection Intervals it is no longer a
multiple of 1.25 ms, and SupervisionTimeout is in milliseconds. They are
not marked experimental, since the tests come with them, but I can mark
them so if you prefer. There is no command to read the parameters, so
when bluetoothd starts while a device is already connected over LE, the
properties only appear once the parameters change.

The two new functional tests check that both hosts report the
parameters once connected, follow a connection update the peripheral
asks for, and drop them on disconnection. On bluetooth-next the bearer
tests pass in 3 of 3 runs; without the kernel patch the new tests fail.
make check and the functional tests using HoG, btmgmt, bluetoothctl or
the agent pass.

Kevin Dewald (5):
  doc/mgmt: Document Connection Subrate for LE connections and updates
  org.bluez.Bearer: Add connection parameter properties
  bearer: Add connection parameter properties
  client: Print LE connection parameters in info
  test: functional: add bearer connection parameter tests

 client/main.c                  |   5 ++
 doc/functional-bearer.rst      |  43 ++++++++++++
 doc/mgmt-protocol.rst          |   8 ++-
 doc/org.bluez.Bearer.LE.rst    |  38 ++++++++++
 src/adapter.c                  |  12 ++++
 src/bearer.c                   | 122 +++++++++++++++++++++++++++++++++
 src/bearer.h                   |   3 +
 src/device.c                   |   8 +++
 src/device.h                   |   3 +
 test/functional/test_bearer.py |  78 +++++++++++++++++++++
 10 files changed, 319 insertions(+), 1 deletion(-)


base-commit: 14bd6ab65f4a647302edbd6df27f6faa91bee8a8
-- 
2.54.0 (Apple Git-157)


             reply	other threads:[~2026-11-03  7:27 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-03  7:27 Kevin Dewald [this message]
2026-11-03  7:27 ` [PATCH BlueZ 1/5] doc/mgmt: Document Connection Subrate for LE connections and updates Kevin Dewald
2026-11-03  8:56   ` Add LE connection parameters to org.bluez.Bearer.LE1 bluez.test.bot
2026-11-03  7:27 ` [PATCH BlueZ 2/5] org.bluez.Bearer: Add connection parameter properties Kevin Dewald
2026-11-03  7:27 ` [PATCH BlueZ 3/5] bearer: " Kevin Dewald
2026-11-03  7:27 ` [PATCH BlueZ 4/5] client: Print LE connection parameters in info Kevin Dewald
2026-11-03  7:27 ` [PATCH BlueZ 5/5] test: functional: add bearer connection parameter tests Kevin Dewald
2026-11-03 16:30 ` [PATCH BlueZ 0/5] Add LE connection parameters to org.bluez.Bearer.LE1 patchwork-bot+bluetooth

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261103072749.50979-1-kevin@simpleble.org \
    --to=kevin@simpleble.org \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=luiz.dentz@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox