public inbox for linux-bluetooth@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH BlueZ v2 0/6] Nintendo Switch 2 support
@ 2026-03-08 12:47 Martin BTS
  2026-03-08 12:47 ` [PATCH BlueZ v2 1/6] shared/gatt: make secondary discovery optional Martin BTS
                   ` (6 more replies)
  0 siblings, 7 replies; 11+ messages in thread
From: Martin BTS @ 2026-03-08 12:47 UTC (permalink / raw)
  To: linux-bluetooth; +Cc: hadess, luiz.dentz, vi, Martin BTS

Changes v2:
* Drop original patches 1 and 2 (tollerate ATT timeout)
* New patches 1, 2, 3 introduce a device property skip_secondary,
  that makes secondary device discovery optional
* set_alias() is now public btd_device_set_alias() as suggested
* Fix assigned numbers reference comment
* Link to v1: https://lore.kernel.org/all/20260301152930.221472-1-martinbts@gmx.net/

v2 blurb:

The problem is the secondary service discovery. It will time out on the
Procon2 which is essentially an unrecoverable error and we cannot
connect the controller as a result.

This patchset proposes making the secondary service discovery optional,
so that we can prevent dealing with the Procon2's behaviour.
It now is a property of the device, if it wants/needs a secondary
discovery, or not. This allows device specific plugins to make the
correct configuration in time, bevor a gatt-client is created. The
default is the original behaviour: do a secondary services discovery.

I marked patch 1 as a breaking change, because of how it changes the
gatt-client interface. It appears this gatt-client is only used
internally and never exposed so it technically isn't a breaking change
for BlueZ, but I cannot be sure.

For the record: The Procon2 reports appearance 0x0A82 Portable handheld console

Martin BTS (6):
  shared/gatt: make secondary discovery optional
  device: allow skip secondary discovery
  fixup: propagate new gatt interface through codebase
  device: Rename set_alias to  btd_device_set_alias()
  dbus-common: Add Gaming appearance class (0x2a)
  plugins/switch2: Add Nintendo Switch 2 Controller plugin

 Makefile.plugins         |    3 +
 peripheral/gatt.c        |    5 +-
 plugins/switch2.c        | 1070 ++++++++++++++++++++++++++++++++++++++
 src/dbus-common.c        |    2 +
 src/device.c             |   33 +-
 src/device.h             |    2 +
 src/shared/gatt-client.c |   22 +-
 src/shared/gatt-client.h |    4 +-
 tools/btgatt-client.c    |    5 +-
 unit/test-bap.c          |    3 +-
 unit/test-gatt.c         |    3 +-
 unit/test-gmap.c         |    3 +-
 unit/test-mcp.c          |    3 +-
 unit/test-micp.c         |    3 +-
 unit/test-tmap.c         |    3 +-
 15 files changed, 1133 insertions(+), 31 deletions(-)
 create mode 100644 plugins/switch2.c

-- 
2.47.3


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

end of thread, other threads:[~2026-03-10  3:38 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-08 12:47 [PATCH BlueZ v2 0/6] Nintendo Switch 2 support Martin BTS
2026-03-08 12:47 ` [PATCH BlueZ v2 1/6] shared/gatt: make secondary discovery optional Martin BTS
2026-03-08 14:18   ` Nintendo Switch 2 support bluez.test.bot
2026-03-09 13:58   ` [PATCH BlueZ v2 1/6] shared/gatt: make secondary discovery optional Luiz Augusto von Dentz
2026-03-09 15:40     ` Martin BTS
2026-03-08 12:47 ` [PATCH BlueZ v2 2/6] device: allow skip secondary discovery Martin BTS
2026-03-08 12:47 ` [PATCH BlueZ v2 3/6] fixup: propagate new gatt interface through codebase Martin BTS
2026-03-08 12:47 ` [PATCH BlueZ v2 4/6] device: Rename set_alias to btd_device_set_alias() Martin BTS
2026-03-08 12:47 ` [PATCH BlueZ v2 5/6] dbus-common: Add Gaming appearance class (0x2a) Martin BTS
2026-03-08 12:47 ` [PATCH BlueZ v2 6/6] plugins/switch2: Add Nintendo Switch 2 Controller plugin Martin BTS
2026-03-10  3:30 ` [PATCH BlueZ v2 0/6] Nintendo Switch 2 support Vicki Pfau

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