Commit: 25dc0c5026442edee1ef0b987aca723ea3b593fb
Parent: 778e182c6438962ff641e66b1a867aa16bd27414
Author: Johan Hedberg <johan.hedberg@intel.com>
Committer: Johan Hedberg <johan.hedberg@intel.com>
Date: 2014-11-03 22:05:50
Tree: 3d9201c6cfd722fdbfde2696ed80c0b77c644757

core: Remove unnecessary LE connect for kernels that don't need it From mgmt version 1.4 onward the ATT server socket gets appropriate notifications also for outgoing connections triggered by mgmt_pair_device. This patch adds a check for the mgmt version to not unnecessarily create the LE client socket first. For now this also fixes a potential race condition in the kernel where the socket connect LE scan disabling will fail because of a preceding mgmt_stop_discovery trying to do the same thing. Since mgmt commands (unlike the socket connect) are serialized the race cannot happen with the mgmt_stop_discover + mgmt_pair_device combination.

Diffstat

M src/adapter.c | 13 +++++++++++++
M src/adapter.h | 2 ++
M src/device.c | 2 +-

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

View Full Diff | Patch