OSDN Git Service

android-x86/system-bt.git
3 years agoSimplify max data length request am: f3e8d7619c
Hansong Zhang [Wed, 13 Jan 2021 20:41:35 +0000 (20:41 +0000)]
Simplify max data length request am: f3e8d7619c

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1549415

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iea053ae8ff2f030287d8b67f1d1e1baf6fe96e78

3 years agoBLE_LLT_INCLUDED is always true am: 5a82d95306
Hansong Zhang [Wed, 13 Jan 2021 20:40:31 +0000 (20:40 +0000)]
BLE_LLT_INCLUDED is always true am: 5a82d95306

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1549414

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2d99978a2fbd3bb5f9c0fcdea117451709fe46b6

3 years agoClean up L2CA_UpdateBleConnParams am: ff27ce5036
Hansong Zhang [Wed, 13 Jan 2021 20:36:59 +0000 (20:36 +0000)]
Clean up L2CA_UpdateBleConnParams am: ff27ce5036

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1548874

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I446ebe2cddad31a4630f1797628d78bb66086965

3 years agoSimplify max data length request
Hansong Zhang [Wed, 13 Jan 2021 00:11:26 +0000 (16:11 -0800)]
Simplify max data length request

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I422f6bd0c3a246fb9395b116fdf53f7f56a4bc69

3 years agoBLE_LLT_INCLUDED is always true
Hansong Zhang [Tue, 12 Jan 2021 22:33:30 +0000 (14:33 -0800)]
BLE_LLT_INCLUDED is always true

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: If5daa3237ad771eb4f96d0f34d31a94b63433185

3 years agoClean up L2CA_UpdateBleConnParams
Hansong Zhang [Tue, 12 Jan 2021 21:03:29 +0000 (13:03 -0800)]
Clean up L2CA_UpdateBleConnParams

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: Ia5e9921eb14d6303b96ffbc85f31aa3f7d654eba

3 years agoMerge "gd: Set scan response data based on AdvertisingType" am: 71e7b10ff9
Treehugger Robot [Wed, 13 Jan 2021 07:00:13 +0000 (07:00 +0000)]
Merge "gd: Set scan response data based on AdvertisingType" am: 71e7b10ff9

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545233

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2826efcd1d18266c9b00045faa8b146f90d7d172

3 years agoMerge "gd: Set scan response data based on AdvertisingType"
Treehugger Robot [Wed, 13 Jan 2021 06:22:34 +0000 (06:22 +0000)]
Merge "gd: Set scan response data based on AdvertisingType"

3 years agoMerge changes I442176d1,Ib147e50a,I9f4de837,Ib9cd95d0 am: d86e699c22
Zach Johnson [Wed, 13 Jan 2021 05:13:24 +0000 (05:13 +0000)]
Merge changes I442176d1,Ib147e50a,I9f4de837,Ib9cd95d0 am: d86e699c22

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1534499

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I0e96d08dee704c0b4dddb0bf7a843036614e9387

3 years agoMerge changes I442176d1,Ib147e50a,I9f4de837,Ib9cd95d0
Zach Johnson [Wed, 13 Jan 2021 04:45:23 +0000 (04:45 +0000)]
Merge changes I442176d1,Ib147e50a,I9f4de837,Ib9cd95d0

* changes:
  rusty-gd: most of the HCI shim layer
  move le_advertising_manager_test over to PyHci
  Emit checker for command status opcodes, remove unnecessary overloads
  HciLayerFacade -> HciFacade

3 years agoClean up BTA_GATTC_Open am: 4f0b512c78
Hansong Zhang [Wed, 13 Jan 2021 01:40:41 +0000 (01:40 +0000)]
Clean up BTA_GATTC_Open am: 4f0b512c78

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1548875

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1379735b380e17a35412c138ceb1d804fdb3a17c

3 years agorusty-gd: most of the HCI shim layer
Zach Johnson [Mon, 21 Dec 2020 18:01:45 +0000 (10:01 -0800)]
rusty-gd: most of the HCI shim layer

(command sending not connected yet)

Bug: 171749953
Tag: #gd-refactor
Test: gd/cert/run --rhost SimpleHalTest
Change-Id: I442176d1e29485dab56dcaba53f0975de144a1fb

3 years agomove le_advertising_manager_test over to PyHci
Zach Johnson [Sat, 19 Dec 2020 03:29:07 +0000 (19:29 -0800)]
move le_advertising_manager_test over to PyHci

Bug: 171749953
Tag: #gd-refactor
Test: gd/cert/run
Change-Id: Ib147e50a91dd0c9d31905317028e267ff2b71070

3 years agoEmit checker for command status opcodes, remove unnecessary overloads
Zach Johnson [Fri, 18 Dec 2020 22:00:37 +0000 (14:00 -0800)]
Emit checker for command status opcodes, remove unnecessary overloads

simplifies python, facades, etc

Bug: 171749953
Tag: #gd-refactor
Test: gd/cert/run
Change-Id: I9f4de8373efb9bf07c55bcab9a7bc31a473d9c25

3 years agoHciLayerFacade -> HciFacade
Zach Johnson [Fri, 18 Dec 2020 21:08:26 +0000 (13:08 -0800)]
HciLayerFacade -> HciFacade

Layer is redundant

Bug: 171749953
Tag: #gd-refactor
Test: cert/run
Change-Id: Ib9cd95d069a57e590fa2b4c8b438ab01951d4ec6

3 years agoClean up BTA_GATTC_Open
Hansong Zhang [Tue, 12 Jan 2021 21:24:38 +0000 (13:24 -0800)]
Clean up BTA_GATTC_Open

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I12263c05acd4ba04e09544b95388a13461dc4e93

3 years agoBTM_Sec: AUTHENTICATE should imply MITM am: 665ffb324f
Hansong Zhang [Tue, 12 Jan 2021 22:10:20 +0000 (22:10 +0000)]
BTM_Sec: AUTHENTICATE should imply MITM am: 665ffb324f

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1548414

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7167e350faea351dc4e6dc5ce93e353f65d3eb8f

3 years agoL2cap: Pass remote features to btm_sec am: 1353c47328
Hansong Zhang [Tue, 12 Jan 2021 22:10:17 +0000 (22:10 +0000)]
L2cap: Pass remote features to btm_sec am: 1353c47328

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1547335

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2bb4bc94e41344c07ca465d15a53eb4bed398ac8

3 years agoShim hack: Add SCO disconnect callback am: 5505296196
Hansong Zhang [Tue, 12 Jan 2021 22:10:14 +0000 (22:10 +0000)]
Shim hack: Add SCO disconnect callback am: 5505296196

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1547314

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I49ab009e6a68adcfb7fc65c74fa7d35f5daeb730

3 years agoL2cap LE shim: Use link property listener am: 1c169999ba
Hansong Zhang [Tue, 12 Jan 2021 22:10:12 +0000 (22:10 +0000)]
L2cap LE shim: Use link property listener am: 1c169999ba

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1546977

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If201488adfbe463b7116e015cf380733b875af7f

3 years agoLE: Add link property listener and phy update am: 219133bde2
Hansong Zhang [Tue, 12 Jan 2021 22:09:14 +0000 (22:09 +0000)]
LE: Add link property listener and phy update am: 219133bde2

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1546413

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I5278b1926d56bdbdf5fa0676d342c3353860f222

3 years agoMerge changes I48f17bc8,I46294bbf,I74d0b45a,I749eb082,I71224efc, ... am: bad953edd5
Treehugger Robot [Tue, 12 Jan 2021 21:05:51 +0000 (21:05 +0000)]
Merge changes I48f17bc8,I46294bbf,I74d0b45a,I749eb082,I71224efc, ... am: bad953edd5

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545123

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I159b8092e7ee124441ba725d2be8aecd276267e7

3 years agoIncrease RFC_MCB_RELEASE_INACT_TIMER to 20 seconds am: b4a0c85f26
Hansong Zhang [Tue, 12 Jan 2021 21:04:40 +0000 (21:04 +0000)]
Increase RFC_MCB_RELEASE_INACT_TIMER to 20 seconds am: b4a0c85f26

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1547336

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I31612d6695fd87a7e0f846c5fd26c1b62e259ddc

3 years agoBTM_Sec: AUTHENTICATE should imply MITM
Hansong Zhang [Tue, 12 Jan 2021 07:48:47 +0000 (23:48 -0800)]
BTM_Sec: AUTHENTICATE should imply MITM

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: If492a5bfe2a3945ebf3f1d1a55c0a0f395b5f83b

3 years agoL2cap: Pass remote features to btm_sec
Hansong Zhang [Tue, 12 Jan 2021 05:49:01 +0000 (21:49 -0800)]
L2cap: Pass remote features to btm_sec

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I0b8de4ce270caf18b1b07930f04e9905adebf622

3 years agoShim hack: Add SCO disconnect callback
Hansong Zhang [Tue, 12 Jan 2021 01:30:34 +0000 (17:30 -0800)]
Shim hack: Add SCO disconnect callback

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I3f2ba43702542db6e07b1f6f61b9687ef178310c

3 years agoL2cap LE shim: Use link property listener
Hansong Zhang [Mon, 11 Jan 2021 23:00:21 +0000 (15:00 -0800)]
L2cap LE shim: Use link property listener

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I171e0c21a83f9f5e6eca8aba5dc9861737c60c8b

3 years agoLE: Add link property listener and phy update
Hansong Zhang [Mon, 11 Jan 2021 21:15:15 +0000 (13:15 -0800)]
LE: Add link property listener and phy update

Add L2cap LE LinkPropertyListener.
Add PHY update listener for ACL and L2cap.

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I691dbcd86d63998a7ff7f8cb5889bba53ad4aaca

3 years agoMerge changes I48f17bc8,I46294bbf,I74d0b45a,I749eb082,I71224efc, ...
Treehugger Robot [Tue, 12 Jan 2021 20:38:12 +0000 (20:38 +0000)]
Merge changes I48f17bc8,I46294bbf,I74d0b45a,I749eb082,I71224efc, ...

* changes:
  gd_acl: Add ACL connection history
  Add gd/common/strings::StringFormatTimeWithMilliseconds
  bt_headless: Add connect/disconnect timeouts
  Include BTM_PmRegister::callback
  Use main/shim/dumpsys::supervision_timeout_to_seconds
  Add main/shim/dumpsys::supervision_timeout_to_seconds
  bt_headless: Add connect test

3 years agogd_acl: Add ACL connection history
Chris Manton [Fri, 8 Jan 2021 17:59:25 +0000 (09:59 -0800)]
gd_acl: Add ACL connection history

Towards discoverable code

Bug: 176960731
Tag: #refactor
Test: gd/cert/run

Change-Id: I48f17bc8826530a998e4f11d1eecf32574e6ad88

3 years agoAdd gd/common/strings::StringFormatTimeWithMilliseconds
Chris Manton [Sat, 9 Jan 2021 00:52:30 +0000 (16:52 -0800)]
Add gd/common/strings::StringFormatTimeWithMilliseconds

Also fix local/gm timezone test issue

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: compile & verify basic functions working

Change-Id: I46294bbf69754be3bf4749fa1bb31320606659cf

3 years agobt_headless: Add connect/disconnect timeouts
Chris Manton [Fri, 8 Jan 2021 18:16:21 +0000 (10:16 -0800)]
bt_headless: Add connect/disconnect timeouts

Towards testable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I74d0b45a737efcbe1f855346d08a07e085e56107

3 years agoInclude BTM_PmRegister::callback
Chris Manton [Fri, 8 Jan 2021 18:15:45 +0000 (10:15 -0800)]
Include BTM_PmRegister::callback

Condition using tBTM_PM_REGISTER::

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I749eb082092adebdd441784db6f829c912839000

3 years agoUse main/shim/dumpsys::supervision_timeout_to_seconds
Chris Manton [Thu, 7 Jan 2021 22:51:59 +0000 (14:51 -0800)]
Use main/shim/dumpsys::supervision_timeout_to_seconds

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I71224efcf0026f69e83d19b711590f2222b80f92

3 years agoAdd main/shim/dumpsys::supervision_timeout_to_seconds
Chris Manton [Thu, 7 Jan 2021 22:50:02 +0000 (14:50 -0800)]
Add main/shim/dumpsys::supervision_timeout_to_seconds

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: Icd73d874a7143efdf33383ad3b096305c21d98b8

3 years agobt_headless: Add connect test
Chris Manton [Thu, 7 Jan 2021 22:37:00 +0000 (14:37 -0800)]
bt_headless: Add connect test

Towards testable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I91eafe7e8047638581dcda75f60527572d842ec6

3 years agoIncrease RFC_MCB_RELEASE_INACT_TIMER to 20 seconds
Hansong Zhang [Tue, 12 Jan 2021 07:22:33 +0000 (23:22 -0800)]
Increase RFC_MCB_RELEASE_INACT_TIMER to 20 seconds

Say we first connect to a remote device using RFCOMM.  The remote
decides to bond with us before we establish a channel.  This could take
longer than 2 seconds.

In the past we handle this before we create L2cap channel.  However,
re-bond can happen during RFCOMM session, because security requirement
might have changed.

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I7d5618b37d5414b10abe7497c3ea6819fb802db7

3 years agoMerge changes from topic "Refactor StartScan/StopScan for GD" am: 5842e796da
Treehugger Robot [Tue, 12 Jan 2021 02:14:53 +0000 (02:14 +0000)]
Merge changes from topic "Refactor StartScan/StopScan for GD" am: 5842e796da

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1542610

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ia3df1167919bc8ff58cf303cc6adcf54f8ac07cf

3 years agoInclude stack/gatt/gatt_db::stack/btm/btm_ble_int am: 9a57f09d77
Chris Manton [Tue, 12 Jan 2021 02:14:13 +0000 (02:14 +0000)]
Include stack/gatt/gatt_db::stack/btm/btm_ble_int am: 9a57f09d77

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1546535

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I022c16ac6497550442cf6270e8d979829121e3a7

3 years agogd: Set scan response data based on AdvertisingType
Chienyuan [Mon, 11 Jan 2021 14:14:53 +0000 (22:14 +0800)]
gd: Set scan response data based on AdvertisingType

Tag: #gd-refactor
Bug: 169125803
Test: cert/run --host
Test: atest --host bluetooth_test_gd
Change-Id: Ib73a03398623fd99d6bf1234510048faef1ea60b

3 years agoMerge changes from topic "Refactor StartScan/StopScan for GD"
Treehugger Robot [Tue, 12 Jan 2021 01:59:25 +0000 (01:59 +0000)]
Merge changes from topic "Refactor StartScan/StopScan for GD"

* changes:
  gd: replace old scan APIs and refactor tests
  gd: Implement basic scan function

3 years agoMerge changes Ice686602,I577c366c am: b12757cc2e
Zach Johnson [Tue, 12 Jan 2021 00:33:26 +0000 (00:33 +0000)]
Merge changes Ice686602,I577c366c am: b12757cc2e

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1534023

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7028d4b7b1077f93cebc13fe5b0f309285c67e14

3 years agoInclude stack/gatt/gatt_db::stack/btm/btm_ble_int
Chris Manton [Mon, 11 Jan 2021 23:33:31 +0000 (15:33 -0800)]
Include stack/gatt/gatt_db::stack/btm/btm_ble_int

Broken yukawa build

Bug: 177256931
Test: Builds and compiles
Tag: #refactor
Change-Id: Icc5e6bf1a5c936b5de390abe719d84b2836b0169

3 years agoMerge changes Ice686602,I577c366c
Zach Johnson [Mon, 11 Jan 2021 23:46:29 +0000 (23:46 +0000)]
Merge changes Ice686602,I577c366c

* changes:
  rusty-gd: some facade cleanup
  rusty-gd: add le events to facade

3 years agobtm_process_clk_off_comp_evt is no-op am: 3cd1f890f8
Hansong Zhang [Mon, 11 Jan 2021 23:11:46 +0000 (23:11 +0000)]
btm_process_clk_off_comp_evt is no-op am: 3cd1f890f8

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1546465

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I9de706a02529e5252c68e5a51cfc41ea11ac75b6

3 years agoMerge "gatt: Extend Bluetooth GATT API with eatt support" am: d9ddc418cc
Jakub Pawlowski [Mon, 11 Jan 2021 23:08:28 +0000 (23:08 +0000)]
Merge "gatt: Extend Bluetooth GATT API with eatt support" am: d9ddc418cc

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1404767

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I8323324a0b416ff0e977f94b8375aa29c9743ad1

3 years agobtm_process_clk_off_comp_evt is no-op
Hansong Zhang [Sat, 9 Jan 2021 00:24:37 +0000 (16:24 -0800)]
btm_process_clk_off_comp_evt is no-op

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: Ice1653170425e7fb0b6f116ab7982f76f0b0c0b4

3 years agoMerge "gatt: Extend Bluetooth GATT API with eatt support"
Jakub Pawlowski [Mon, 11 Jan 2021 22:28:49 +0000 (22:28 +0000)]
Merge "gatt: Extend Bluetooth GATT API with eatt support"

3 years agoLE L2cap security enforcement interface minor fix am: 4aeef950e0
Hansong Zhang [Mon, 11 Jan 2021 21:39:03 +0000 (21:39 +0000)]
LE L2cap security enforcement interface minor fix am: 4aeef950e0

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1546464

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I5a2f1ac121428edc198727f6bac137339070dbf1

3 years agoImplement robust caching (client) am: 31a654a93f
HsingYuan Lo [Mon, 11 Jan 2021 21:38:58 +0000 (21:38 +0000)]
Implement robust caching (client) am: 31a654a93f

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1398285

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I5ff6d70dae7cdb337d76bcf030397fcebb172016

3 years agoL2cap: Reroute link callbacks to new listener am: a11a4a276c
Hansong Zhang [Mon, 11 Jan 2021 21:38:52 +0000 (21:38 +0000)]
L2cap: Reroute link callbacks to new listener am: a11a4a276c

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1544764

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1cfa2d7338409f832374c398cf397268cce7a887

3 years agoL2cap: Send link callbacks to listener am: 38d581efd3
Hansong Zhang [Mon, 11 Jan 2021 21:38:50 +0000 (21:38 +0000)]
L2cap: Send link callbacks to listener am: 38d581efd3

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1543603

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I98b34e4f4693ff01398394ac2dbc05f85697aa6e

3 years agoIntroduce L2cap classic link property listener am: 0aad0bc42d
Hansong Zhang [Mon, 11 Jan 2021 21:38:47 +0000 (21:38 +0000)]
Introduce L2cap classic link property listener am: 0aad0bc42d

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1543871

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2a5ef3e73d11a403ff4b57514f7019370f414ba1

3 years agoRe-log stack/btm/btm_dev::btm_sec_alloc_dev am: acb8c8b47a
Chris Manton [Mon, 11 Jan 2021 21:38:32 +0000 (21:38 +0000)]
Re-log stack/btm/btm_dev::btm_sec_alloc_dev am: acb8c8b47a

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545116

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie42baf86e1553b17ee3cc214c998d480c660f8ab

3 years agoProperly include stack/btm/btm_sec::smp_int.h am: dd0ddc1482
Chris Manton [Mon, 11 Jan 2021 21:38:30 +0000 (21:38 +0000)]
Properly include stack/btm/btm_sec::smp_int.h am: dd0ddc1482

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545115

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I39ad4b10e48c266191f75744940adbc7ff9fbe65

3 years agoComplete stack/include/btm_client_interface::<BTM interface> am: e1ea9c96fc
Chris Manton [Mon, 11 Jan 2021 21:38:27 +0000 (21:38 +0000)]
Complete stack/include/btm_client_interface::<BTM interface> am: e1ea9c96fc

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545113

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1403320d8e874f568245dbf358073004d75c28fe

3 years agoAdd LOG_TAG stack/avct/avct_bcb_act::bluetooth am: 88a1d49bf9
Chris Manton [Mon, 11 Jan 2021 21:38:25 +0000 (21:38 +0000)]
Add LOG_TAG  stack/avct/avct_bcb_act::bluetooth am: 88a1d49bf9

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545112

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I6f8975c99b2bc3944de9fea7ac67850a4629be74

3 years agoAdd stack/btm/btm_sec::NotifyBondingCanceled am: 369a196cb4
Chris Manton [Mon, 11 Jan 2021 21:38:23 +0000 (21:38 +0000)]
Add stack/btm/btm_sec::NotifyBondingCanceled am: 369a196cb4

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545111

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iba190f0235ab7985d92b8243072d248b2d4f60a8

3 years agoUn-include stack/l2cap/l2c_link declare explictly am: ab6435b92a
Chris Manton [Mon, 11 Jan 2021 21:38:20 +0000 (21:38 +0000)]
Un-include stack/l2cap/l2c_link declare explictly am: ab6435b92a

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545110

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie500507ec338abea9c2b0c49af30f363e1305d07

3 years agoRe-log btif/src/btif_av::btif_av_handle_event am: f27987e5bb
Chris Manton [Mon, 11 Jan 2021 21:38:17 +0000 (21:38 +0000)]
Re-log btif/src/btif_av::btif_av_handle_event am: f27987e5bb

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545109

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7decdc01911a02dd6adbfccf5410e6f0a64e3d3e

3 years agoRe-log stack/gatt/gatt_api::GATTC_ConfigureMTU am: 85604c6e22
Chris Manton [Mon, 11 Jan 2021 21:38:14 +0000 (21:38 +0000)]
Re-log stack/gatt/gatt_api::GATTC_ConfigureMTU am: 85604c6e22

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545108

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I474cd4e1e144aec1c810a8a32c51499893da6fe4

3 years agoCanonicalize stack/gatt/gatt_attr::gatt_profile_cback am: db78d97a66
Chris Manton [Mon, 11 Jan 2021 21:38:11 +0000 (21:38 +0000)]
Canonicalize stack/gatt/gatt_attr::gatt_profile_cback am: db78d97a66

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545107

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I9928fcc0b5d03b16422a1e62df27a087f774877f

3 years agoUse proper API main/shim/acl::BTM_LogHistory am: 692bb420dd
Chris Manton [Mon, 11 Jan 2021 21:38:09 +0000 (21:38 +0000)]
Use proper API main/shim/acl::BTM_LogHistory am: 692bb420dd

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545106

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If4e7bf2200795babab6358e5d16da9a9f2c7e55b

3 years agoRe-log btif/src/btif_dm::btif_dm_proc_loc_oob am: 23392bcb23
Chris Manton [Mon, 11 Jan 2021 21:38:07 +0000 (21:38 +0000)]
Re-log btif/src/btif_dm::btif_dm_proc_loc_oob am: 23392bcb23

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545105

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ia2aabbfacffe5f67cb5ecc826f3ac1799943b8cc

3 years agoCanonicalize btif/src/btif_gatt::btgattInterface am: 90c0e1bd99
Chris Manton [Mon, 11 Jan 2021 21:38:05 +0000 (21:38 +0000)]
Canonicalize btif/src/btif_gatt::btgattInterface am: 90c0e1bd99

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1545104

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I075f0995836690a455eb7d55b64723d8ffc51435

3 years agoLE L2cap security enforcement interface minor fix
Hansong Zhang [Sat, 9 Jan 2021 00:23:44 +0000 (16:23 -0800)]
LE L2cap security enforcement interface minor fix

Move the code for default impl.

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I3faf430ac04fbb825595151b9ae5ca9cad233e55

3 years agoImplement robust caching (client)
HsingYuan Lo [Mon, 11 Jan 2021 10:14:48 +0000 (18:14 +0800)]
Implement robust caching (client)

Flag:
- Use flag to enable/disable robust caching on client side

When receiving service changed indication
- set read_db_hash flag to true

Read db hash function and response handler
- add bta_gattc_read_db_hash
- add bta_gattc_read_db_hash_cmpl
  - reset read_db_hash flag
  - If hash match, set states of all related clcb back to CONN_ST
  - If hash not match, start service discovery

When start service discovery is called
- read db hash first if read_db_hash flag is on
- start service discovery immediately if above request is rejected
- start service discovery immediately if read_db_hash flag is off

When receiving response during discover state
- call bta_gattc_read_db_hash_cmpl,
    if BTA_GATTC_DISCOVER_REQ_READ_DB_HASH is set
- call bta_gattc_read_ext_prop_desc_cmpl,
    if BTA_GATTC_DISCOVER_REQ_READ_EXT_PROP_DESC is set

When DATABASE OUT OF SYNC is received during connected state
- send the error(0x12) to application layer
- start service discovery immediately

When DATABASE OUT OF SYNC is received during discover state
- if the retry count exceeds the limit, do nothing
- otherwise restart service discovery again, and increase the retry count

When service discovery is completed (bta_gattc_explore_srvc_finished)
- if result is GATT_SUCCESS, reset the count to zero

Bug: 154056389
Test: compile & verify gatt client behavior
Tag: #feature
Change-Id: I8e3e03302c03f49bda40f0ec20ad5c607ef6dcdf

3 years agoL2cap: Reroute link callbacks to new listener
Hansong Zhang [Fri, 8 Jan 2021 23:53:03 +0000 (15:53 -0800)]
L2cap: Reroute link callbacks to new listener

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I67a567c90e3162eea82583d2ed91e2c031a26e96

3 years agoL2cap: Send link callbacks to listener
Hansong Zhang [Fri, 8 Jan 2021 23:19:16 +0000 (15:19 -0800)]
L2cap: Send link callbacks to listener

Send OnRoleChange, OnReadClockOffset, OnModeChange, OnModeChange to
listener.

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I2c5d0d2084a1064de620f4617a3b60ce11960ebe

3 years agoIntroduce L2cap classic link property listener
Hansong Zhang [Fri, 8 Jan 2021 20:53:29 +0000 (12:53 -0800)]
Introduce L2cap classic link property listener

For shim, and some other module in the future, to receive some link
callbacks, which are for non-security purposes.

Test: cert/run
Tag: #gd-refactor
Bug: 141555841
Change-Id: I8842ac63b98d8233f7af00a8d2e85a4ff166d828

3 years agoMerge "Updateability: Remove IBluetoothHeadsetPhone aidl" am: a5d67bd570
Chen Chen [Mon, 11 Jan 2021 19:54:12 +0000 (19:54 +0000)]
Merge "Updateability: Remove IBluetoothHeadsetPhone aidl" am: a5d67bd570

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1543728

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iafb4dc315be19a2c461f17f0f78d63cf5949411e

3 years agoRe-log stack/btm/btm_dev::btm_sec_alloc_dev
Chris Manton [Thu, 7 Jan 2021 22:31:44 +0000 (14:31 -0800)]
Re-log stack/btm/btm_dev::btm_sec_alloc_dev

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I63bd3eb1a9fca3e2df3257bc4c3d899f1bb07380

3 years agoProperly include stack/btm/btm_sec::smp_int.h
Chris Manton [Thu, 7 Jan 2021 21:52:27 +0000 (13:52 -0800)]
Properly include stack/btm/btm_sec::smp_int.h

Towards readable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I305c6e994fa4400ca3418f27b3af6aa20f38927b

3 years agoComplete stack/include/btm_client_interface::<BTM interface>
Chris Manton [Thu, 7 Jan 2021 21:11:11 +0000 (13:11 -0800)]
Complete stack/include/btm_client_interface::<BTM interface>

Towards modular code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I3c5e80a2b0745d847e09be0390176d2d8337f777

3 years agoAdd LOG_TAG stack/avct/avct_bcb_act::bluetooth
Chris Manton [Wed, 6 Jan 2021 22:11:45 +0000 (14:11 -0800)]
Add LOG_TAG  stack/avct/avct_bcb_act::bluetooth

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I0d885ccead7b0ef814d33bf6d0961a0376c10e10

3 years agoAdd stack/btm/btm_sec::NotifyBondingCanceled
Chris Manton [Tue, 5 Jan 2021 01:24:22 +0000 (17:24 -0800)]
Add stack/btm/btm_sec::NotifyBondingCanceled

Towards encapsulated code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I5a582d71c9637caf4985790aef32aafd71c21e3e

3 years agoUn-include stack/l2cap/l2c_link declare explictly
Chris Manton [Fri, 4 Dec 2020 16:42:44 +0000 (08:42 -0800)]
Un-include stack/l2cap/l2c_link declare explictly

Towards modular code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I81e882d6c9b8941390b985b017c74a3d0f31bd21

3 years agoRe-log btif/src/btif_av::btif_av_handle_event
Chris Manton [Fri, 4 Dec 2020 16:40:59 +0000 (08:40 -0800)]
Re-log btif/src/btif_av::btif_av_handle_event

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run
No-Typo-Check: Legacy terminology

Change-Id: I42597fc1d95fd47358433ec18ced3f41b08b06c8

3 years agoRe-log stack/gatt/gatt_api::GATTC_ConfigureMTU
Chris Manton [Sat, 2 Jan 2021 19:11:27 +0000 (11:11 -0800)]
Re-log stack/gatt/gatt_api::GATTC_ConfigureMTU

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I30f1d93eea21c74f8e8b59c66787f0e4d56de12a

3 years agoCanonicalize stack/gatt/gatt_attr::gatt_profile_cback
Chris Manton [Sat, 21 Nov 2020 01:34:39 +0000 (17:34 -0800)]
Canonicalize stack/gatt/gatt_attr::gatt_profile_cback

Towards readable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I7dafaa0c6e624ada14f0f0beabc6ee2a123a2e0c

3 years agoUse proper API main/shim/acl::BTM_LogHistory
Chris Manton [Mon, 21 Dec 2020 18:44:20 +0000 (10:44 -0800)]
Use proper API main/shim/acl::BTM_LogHistory

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: Iab4c4278a02e2d0dff4f4e40a18911dee2620c5b

3 years agoRe-log btif/src/btif_dm::btif_dm_proc_loc_oob
Chris Manton [Sat, 7 Nov 2020 02:39:32 +0000 (18:39 -0800)]
Re-log btif/src/btif_dm::btif_dm_proc_loc_oob

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I4024f1e1e5c572e51073021502079bc97199157c

3 years agoCanonicalize btif/src/btif_gatt::btgattInterface
Chris Manton [Thu, 19 Nov 2020 21:55:48 +0000 (13:55 -0800)]
Canonicalize btif/src/btif_gatt::btgattInterface

Towards readable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I23c55595082991614ce445405fa46514cbbda5c5

3 years agoMerge "Updateability: Remove IBluetoothHeadsetPhone aidl"
Chen Chen [Mon, 11 Jan 2021 19:00:45 +0000 (19:00 +0000)]
Merge "Updateability: Remove IBluetoothHeadsetPhone aidl"

3 years agogatt: Extend Bluetooth GATT API with eatt support
Łukasz Rymanowski [Wed, 19 Aug 2020 12:51:19 +0000 (14:51 +0200)]
gatt: Extend Bluetooth GATT API with eatt support

Tag: #feature
Test: manually verified against device supporting EATT
Bug: 159786353
Sponsor: jpawlowski@
Change-Id: Ib128308b08fcb047b123480434009b45a65f8e1f

3 years agogd: replace old scan APIs and refactor tests
Chienyuan [Fri, 8 Jan 2021 09:45:35 +0000 (17:45 +0800)]
gd: replace old scan APIs and refactor tests

Tag: #gd-refactor
Bug: 177044452
Test: gd/cert/run --host
Change-Id: Ic54f0eba9e4783ea8c34e28f11f07b3b94a46fcb

3 years agogd: Implement basic scan function
Chienyuan [Thu, 7 Jan 2021 13:22:03 +0000 (21:22 +0800)]
gd: Implement basic scan function

Tag: #refactor
Bug: 169390539
Test: gd/cert/run --host
Change-Id: Ifb4ea21a4cdab2d3587a9d5d4cf1255be536b231

3 years agoMerge changes from topic "dip1.3" am: 8b5c14ce44
Treehugger Robot [Fri, 8 Jan 2021 21:59:32 +0000 (21:59 +0000)]
Merge changes from topic "dip1.3" am: 8b5c14ce44

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1471603

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I39f2484467352c5fe04a09a8215fbdb31b9b1f89

3 years agoDIP: Implement API to get device identification information am: 07777023f3
Fei Zheng [Fri, 8 Jan 2021 21:58:48 +0000 (21:58 +0000)]
DIP: Implement API to get device identification information am: 07777023f3

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1212762

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I9dbf69ce86eb4aaa5c2b07b473a3e74f153dcd6a

3 years agoMerge changes from topic "dip1.3"
Treehugger Robot [Fri, 8 Jan 2021 21:42:32 +0000 (21:42 +0000)]
Merge changes from topic "dip1.3"

* changes:
  Use Bluetooth UUID definitions of header file
  DIP: Implement API to get device identification information

3 years agoMerge "rusty-gd: Fill in new and parse methods for *Data structs" am: ba275c4024
Qasim Javed [Fri, 8 Jan 2021 20:51:26 +0000 (20:51 +0000)]
Merge "rusty-gd: Fill in new and parse methods for *Data structs" am: ba275c4024

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1543144

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I33d3f01d5bd99486b4c57af89a31508284296c10

3 years agorusty-gd: some facade cleanup
Zach Johnson [Fri, 18 Dec 2020 20:47:50 +0000 (12:47 -0800)]
rusty-gd: some facade cleanup

Bug: 171749953
Tag: #gd-refactor
Test: gd/cert/run --rhost SimpleHalTest
Change-Id: Ice6866028f9ea6e1b94d7aa6a240258731d7aa32

3 years agorusty-gd: add le events to facade
Zach Johnson [Wed, 16 Dec 2020 23:14:47 +0000 (15:14 -0800)]
rusty-gd: add le events to facade

Bug: 171749953
Tag: #gd-refactor
Test: gd/cert/run --rhost SimpleHalTest
Change-Id: I577c366cbeebb22492eea3bdc5ebcab9ebd27fa9

3 years agoMerge "rusty-gd: Fill in new and parse methods for *Data structs"
Qasim Javed [Fri, 8 Jan 2021 20:11:04 +0000 (20:11 +0000)]
Merge "rusty-gd: Fill in new and parse methods for *Data structs"

3 years agoL2cap LE shim improvements am: 13dfe2f04c
Hansong Zhang [Fri, 8 Jan 2021 19:40:53 +0000 (19:40 +0000)]
L2cap LE shim improvements am: 13dfe2f04c

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1537164

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Id4d715f7cd53b9cd9342245e079ce1fb82fb8d8c

3 years agoL2cap LE shim improvements
Hansong Zhang [Wed, 6 Jan 2021 21:13:39 +0000 (13:13 -0800)]
L2cap LE shim improvements

Implement connection updates

Test: CtsVerifier
Tag: #gd-refactor
Bug: 141555841
Change-Id: I52891feb017020d9d557e8dac209f0474a18524d

3 years agoFix crash when removing bond to HID device am: 473dc4657b
Jakub Pawlowski [Fri, 8 Jan 2021 18:30:09 +0000 (18:30 +0000)]
Fix crash when removing bond to HID device am: 473dc4657b

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1543151

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I5923c66912ae7b99cc1d46cca1c9d63e80f27eb0

3 years agoFix crash when removing bond to HID device
Jakub Pawlowski [Fri, 8 Jan 2021 13:05:58 +0000 (14:05 +0100)]
Fix crash when removing bond to HID device

This fixes:
JNI DETECTED ERROR IN APPLICATION: a thread (tid 4760 is making JNI calls
without being attached in call to ExceptionCheck

Bug: none
Test: manually connect and unbond HID device
Tag: #feature
Change-Id: I2f8bd0be6229c84ef34bd236962f00a69e630c5c

3 years agogd_acl: Assert with handle value am: 498b1601e2
Chris Manton [Fri, 8 Jan 2021 09:37:28 +0000 (09:37 +0000)]
gd_acl: Assert with handle value am: 498b1601e2

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1543730

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3b2b2698febb2bc587ecc0a1dd86946a9bc4b5bd

3 years agogd_acl: Assert with handle value
Chris Manton [Fri, 8 Jan 2021 01:45:07 +0000 (17:45 -0800)]
gd_acl: Assert with handle value

Toward stable code

Bug: 163134718
Tag: #refactor
Test: compile & verify basic functions working
Change-Id: I7480ab4d560f92638e09e474ac44f38f923f528e