Commit: 46a5d2beccb2ea73f28502950f52032cf4811d37
Parent: 1106b28be85ac9586d1758839226e163e9030ee2
Author: Pauli Virtanen <pav@iki.fi>
Committer: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Date: 2023-02-23 22:50:36
Tree: 1ef45e88987182233ef9f63a35d6a51fb26ad305

device: wait GATT client ready before service accept() if no cache On device ATT attach, do not immediately call accept() for profiles, if there is no cached data in GATT database. Instead, wait for service resolution to complete, as likely accept() cannot succeed before that. Several profiles (bap, vcp, midi, deviceinfo) assume that GATT attributes are available when their accept() is called, returning success even if not. In this case, the services never find the remote attributes and are not operable. Other profiles (hog, batt, ...) fail their accept which prompts core to retry after discovery, and work correctly also in this case. Fix the failing services by waiting for service resolution as necessary, so profiles can assume the GATT DB has some content.

Diffstat

M src/device.c | 7 ++++- - -

1 files changed, 4 insertions(+), 3 deletions(-)

View Full Diff | Patch