OSDN Git Service

BLE HID device connection failure due to security error.
authorZhihai Xu <zhihaixu@google.com>
Wed, 13 Nov 2013 04:18:37 +0000 (20:18 -0800)
committerZhihai Xu <zhihaixu@google.com>
Wed, 11 Dec 2013 18:52:51 +0000 (10:52 -0800)
commit7051db3a486aae771d9b5a81c3546790f86ede34
tree1eb3038698966f43c261c828f5becd727a1bb07a
parentcaf8deb58af8a5480d325ab443d5c49649222456
BLE HID device connection failure due to security error.

When HID BLE device start encryption, if some other GATT application
already start encryption(but not finished yet) by calling
gatt_security_check_start. The HID BLE device will be failed to start
encryption, which will cause it to disconnect the BLE HID connection.
The solution is to check whether we already started the encryption
, If the encryption is already started, wait until the encryption
finished, then continue to start security check for BLE HID device.
add encrytion complete event to notify all GATT client encryption done.
filter the event just for BTA HH LE GATT client.

bug:11636246
Change-Id: If58e57c623cc8cfa05208587b010bec68c71306c
14 files changed:
bta/gatt/bta_gattc_act.c
bta/gatt/bta_gattc_int.h
bta/gatt/bta_gattc_main.c
bta/gatt/bta_gatts_act.c
bta/hh/bta_hh_int.h
bta/hh/bta_hh_le.c
bta/hh/bta_hh_main.c
bta/include/bta_gatt_api.h
btif/src/btif_gatt_test.c
stack/gap/gap_ble.c
stack/gatt/gatt_attr.c
stack/gatt/gatt_auth.c
stack/include/gatt_api.h
stack/srvc/srvc_eng.c