OSDN Git Service

android-x86/system-bt.git
7 years agoAllocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401...
Pavlin Radoslavov [Thu, 13 Jul 2017 21:02:49 +0000 (21:02 +0000)]
Allocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401f62 am: 6a44d1821b am: 4e8db0e0b4 am: 8a6b2b86ba  -s ours am: b3639fc6d3  -s ours
am: 71915a09a7  -s ours

Change-Id: I3d91e1b51fc69d35e969f69c9a33de6fc29cffe5

7 years agoMerge "Add missing continuation offset check for SDP continuation requests" into...
Pavlin Radoslavov [Thu, 13 Jul 2017 21:02:35 +0000 (21:02 +0000)]
Merge "Add missing continuation offset check for SDP continuation requests" into oc-dev am: 8109294976
am: 74efc1091e

Change-Id: Ifd14feff2ad2c14f8f2a083184f31c9799262468

7 years agoMerge "Disable PAN Reverse Tethering when connection originated by the Remote" into...
Pavlin Radoslavov [Thu, 13 Jul 2017 21:02:22 +0000 (21:02 +0000)]
Merge "Disable PAN Reverse Tethering when connection originated by the Remote" into oc-dev am: 5dbe611a15
am: c5aa3c795c

Change-Id: I513c751abc6eddad3f46590961e8e2c1a1c97d9a

7 years agoAllocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401...
Pavlin Radoslavov [Thu, 13 Jul 2017 20:55:52 +0000 (20:55 +0000)]
Allocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401f62 am: 6a44d1821b am: 4e8db0e0b4 am: 8a6b2b86ba  -s ours
am: b3639fc6d3  -s ours

Change-Id: Ie3219423afceddbb0cbc32e33c8c50d2060a7330

7 years agoMerge "Add missing continuation offset check for SDP continuation requests" into...
Pavlin Radoslavov [Thu, 13 Jul 2017 20:55:17 +0000 (20:55 +0000)]
Merge "Add missing continuation offset check for SDP continuation requests" into oc-dev
am: 8109294976

Change-Id: I43121a744aede2a65efa8dd3995fdd1bb3dc8a2d

7 years agoMerge "Merge "resolve merge conflicts of 7d0ad232f to oc-dr1-dev" into oc-dr1-dev...
Android Build Merger (Role) [Thu, 13 Jul 2017 20:55:11 +0000 (20:55 +0000)]
Merge "Merge "resolve merge conflicts of 7d0ad232f to oc-dr1-dev" into oc-dr1-dev am: 79bc6a57df" into oc-dr1-dev-plus-aosp

7 years agoMerge "resolve merge conflicts of 7d0ad232f to oc-dr1-dev" into oc-dr1-dev
Pavlin Radoslavov [Thu, 13 Jul 2017 20:54:59 +0000 (20:54 +0000)]
Merge "resolve merge conflicts of 7d0ad232f to oc-dr1-dev" into oc-dr1-dev
am: 79bc6a57df

Change-Id: I5b8023cb9647735fdeda288f4543450e26a640e1

7 years agoMerge "Disable PAN Reverse Tethering when connection originated by the Remote" into...
Pavlin Radoslavov [Thu, 13 Jul 2017 20:54:58 +0000 (20:54 +0000)]
Merge "Disable PAN Reverse Tethering when connection originated by the Remote" into oc-dev
am: 5dbe611a15

Change-Id: Ie12b30c5fa2a871bad9f74986d0e7cf67368e226

7 years agoresolve merge conflicts of 7d0ad232f to oc-dev-plus-aosp
Pavlin Radoslavov [Thu, 13 Jul 2017 20:54:51 +0000 (20:54 +0000)]
resolve merge conflicts of 7d0ad232f to oc-dev-plus-aosp
am: aa7f7079f7

Change-Id: Ica0e8327a1eb5ffcd5a60aa3cdd842943f508d15

7 years agoMerge "resolve merge conflicts of 7d0ad232f to oc-dr1-dev" into oc-dr1-dev
TreeHugger Robot [Thu, 13 Jul 2017 20:51:10 +0000 (20:51 +0000)]
Merge "resolve merge conflicts of 7d0ad232f to oc-dr1-dev" into oc-dr1-dev

7 years agobt: fix sdp service name by removing NULL char
Timm Korte [Thu, 13 Jul 2017 19:34:40 +0000 (19:34 +0000)]
bt: fix sdp service name by removing NULL char
am: 557d20fd26

Change-Id: I908826e02207f13affe62a33ea17093c50578d56

7 years agoresolve merge conflicts of 7d0ad232f to oc-dev-plus-aosp
Pavlin Radoslavov [Thu, 13 Jul 2017 18:48:43 +0000 (11:48 -0700)]
resolve merge conflicts of 7d0ad232f to oc-dev-plus-aosp

Test: Code inspection.
Change-Id: I13a192920f58d8cea622a6acb2fb46fd07fdd195

7 years agobt: fix sdp service name by removing NULL char
Timm Korte [Mon, 15 May 2017 06:30:00 +0000 (08:30 +0200)]
bt: fix sdp service name by removing NULL char

The Bluedroid stack uses a C string with terminating NULL char as a
service name. Since in BT, strings are TLV encoded (type, length,
value), this doesn't make sense.

Simple fix is to copy the string without the trailing NULL by
removing the "+1" after the strlen call when passing the string as
uint8_t array to the lower level functions.
The current behaviour keeps some older devices from being able to
connect to an Android providing a Serial Port profile due to having
the wrong service name (that is, including a NULL at the end instead
of the correct string).

Test: Checked against Linux BlueZ, which does not include this extra
null character.

Bug: 63665003
Change-Id: I6a43024ff89ac09e4b2d2e5cfb407b6e9323f0bd
Signed-off-by: Timm Korte <timm.korte@gmail.com>
(cherry picked from commit 625f798c696229b0cc58e5f85409fd029f987473)

7 years agoresolve merge conflicts of 7d0ad232f to oc-dr1-dev
Pavlin Radoslavov [Thu, 13 Jul 2017 18:37:19 +0000 (11:37 -0700)]
resolve merge conflicts of 7d0ad232f to oc-dr1-dev

Test: Code inspection.
Change-Id: I5406558028da5a52647dec7f4f691c6c68a5591e

7 years agoAllocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401...
Pavlin Radoslavov [Thu, 13 Jul 2017 18:16:07 +0000 (18:16 +0000)]
Allocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401f62 am: 6a44d1821b am: 4e8db0e0b4
am: 8a6b2b86ba  -s ours

Change-Id: I15e24d3ee6db3a03facf05df6a4b59c0bbd10e0f

7 years agoAllocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401...
Pavlin Radoslavov [Thu, 13 Jul 2017 18:13:38 +0000 (18:13 +0000)]
Allocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401f62 am: 6a44d1821b
am: 4e8db0e0b4

Change-Id: I4b45cfe89d4460520eca795858309a83886e6c70

7 years agoAllocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401f62
Pavlin Radoslavov [Thu, 13 Jul 2017 18:11:07 +0000 (18:11 +0000)]
Allocate buffers of the right size when BT_HDR is included am: 510697a0d7 am: 5da7401f62
am: 6a44d1821b

Change-Id: Idfaeec3e29c40905e50e69df944134e403d41a1b

7 years agoAllocate buffers of the right size when BT_HDR is included am: 510697a0d7
Pavlin Radoslavov [Thu, 13 Jul 2017 18:08:37 +0000 (18:08 +0000)]
Allocate buffers of the right size when BT_HDR is included am: 510697a0d7
am: 5da7401f62

Change-Id: I551622b60e882a85a9c739ec22d08a5af55cb1c9

7 years agoAllocate buffers of the right size when BT_HDR is included
Pavlin Radoslavov [Thu, 13 Jul 2017 18:06:36 +0000 (18:06 +0000)]
Allocate buffers of the right size when BT_HDR is included
am: 510697a0d7

Change-Id: I5ca796fc392413dbf7f89332d1172904f980fab5

7 years agoMerge "Add missing continuation offset check for SDP continuation requests" into...
TreeHugger Robot [Thu, 13 Jul 2017 17:53:39 +0000 (17:53 +0000)]
Merge "Add missing continuation offset check for SDP continuation requests" into oc-dev

7 years agoMerge "Disable PAN Reverse Tethering when connection originated by the Remote" into...
TreeHugger Robot [Thu, 13 Jul 2017 17:52:13 +0000 (17:52 +0000)]
Merge "Disable PAN Reverse Tethering when connection originated by the Remote" into oc-dev

7 years agoMerge "Merge "Add a missing check for PAN buffer size before copying data" into oc...
Android Build Merger (Role) [Thu, 13 Jul 2017 17:31:48 +0000 (17:31 +0000)]
Merge "Merge "Add a missing check for PAN buffer size before copying data" into oc-dev am: ff7bd36bb7 am: c1265822c8" into oc-dr1-dev-plus-aosp

7 years agoMerge "Add a missing check for PAN buffer size before copying data" into oc-dev am...
Pavlin Radoslavov [Thu, 13 Jul 2017 17:31:38 +0000 (17:31 +0000)]
Merge "Add a missing check for PAN buffer size before copying data" into oc-dev am: ff7bd36bb7
am: c1265822c8

Change-Id: Id9bbe63658f8697f130ab59e0fd8c03a7c0f6a9c

7 years agoMerge "Add a missing check for PAN buffer size before copying data" into oc-dev am...
Pavlin Radoslavov [Thu, 13 Jul 2017 17:31:37 +0000 (17:31 +0000)]
Merge "Add a missing check for PAN buffer size before copying data" into oc-dev am: ff7bd36bb7
am: 1a55b43f5c

Change-Id: Id3ca741665434246e0bf667949d65b576ff9fdc6

7 years agoMerge "Add a missing check for PAN buffer size before copying data" into oc-dev
Pavlin Radoslavov [Thu, 13 Jul 2017 17:29:07 +0000 (17:29 +0000)]
Merge "Add a missing check for PAN buffer size before copying data" into oc-dev
am: ff7bd36bb7

Change-Id: I8da8cfc4703923afd2bb8311a95250c39447f9bd

7 years agoMerge "Add a missing check for PAN buffer size before copying data" into oc-dev
Pavlin Radoslavov [Thu, 13 Jul 2017 17:29:05 +0000 (17:29 +0000)]
Merge "Add a missing check for PAN buffer size before copying data" into oc-dev
am: ff7bd36bb7

Change-Id: I1f4eda1132635ad3ee7016f7ad423cea20e293c9

7 years agoMerge "Add missing packet length checks while parsing BNEP control packets" into...
TreeHugger Robot [Thu, 13 Jul 2017 17:25:27 +0000 (17:25 +0000)]
Merge "Add missing packet length checks while parsing BNEP control packets" into oc-dev

7 years agoMerge "Add a missing check for PAN buffer size before copying data" into oc-dev
TreeHugger Robot [Thu, 13 Jul 2017 17:24:30 +0000 (17:24 +0000)]
Merge "Add a missing check for PAN buffer size before copying data" into oc-dev

7 years agoAllocate buffers of the right size when BT_HDR is included am: 8810ffba99
Pavlin Radoslavov [Thu, 13 Jul 2017 17:24:18 +0000 (17:24 +0000)]
Allocate buffers of the right size when BT_HDR is included am: 8810ffba99
am: 0e590923e4  -s ours

Change-Id: I9b8d1a55ce8933d8e7d3c9e8f7aee595878f1f00

7 years agoAllocate buffers of the right size when BT_HDR is included am: 8810ffba99
Pavlin Radoslavov [Thu, 13 Jul 2017 17:22:04 +0000 (17:22 +0000)]
Allocate buffers of the right size when BT_HDR is included am: 8810ffba99
am: c4d897fae0

Change-Id: I7d1d3df1901886b58fda82667ad9a34e86a12dee

7 years agoAllocate buffers of the right size when BT_HDR is included
Pavlin Radoslavov [Thu, 13 Jul 2017 17:19:10 +0000 (17:19 +0000)]
Allocate buffers of the right size when BT_HDR is included
am: 8810ffba99

Change-Id: I963e06b87ad133b661482df6e1b0fa8b8b15cbc4

7 years agoAllocate buffers of the right size when BT_HDR is included
Pavlin Radoslavov [Thu, 13 Jul 2017 17:19:07 +0000 (17:19 +0000)]
Allocate buffers of the right size when BT_HDR is included
am: 8810ffba99

Change-Id: Iba43743c47ce1e0dc0221177b0d168692fa44bdf

7 years agoAllocate buffers of the right size when BT_HDR is included
Pavlin Radoslavov [Thu, 6 Jul 2017 20:39:02 +0000 (13:39 -0700)]
Allocate buffers of the right size when BT_HDR is included

Bug: 63146105
Test: External script
Change-Id: I1f2c871e3fcf57aabdad9d07905e6dae643bd496
Merged-In: I1f2c871e3fcf57aabdad9d07905e6dae643bd496
(cherry picked from commit d88838a7237cd672d87b6b9cc8d56fff625fd1d5)
(cherry picked from commit b648c7dfe45c57842d58576f558fdf8edff10bec)
(cherry picked from commit 338e0485940ab278e6a2dc12285ba0798b79cfa4)

7 years agoAllow collection of Bluetooth firmware dumps in bugreports (3/3)
Ajay Panicker [Thu, 13 Jul 2017 00:21:43 +0000 (00:21 +0000)]
Allow collection of Bluetooth firmware dumps in bugreports (3/3)
am: 0580dd639c

Change-Id: I0ee8952683ef818d0b67d8fc5127f499bf9360fb

7 years agoMerge "bt: fix sdp service name by removing NULL char" am: 2766da83df am: 8eff94efb9
Timm Korte [Thu, 13 Jul 2017 00:19:33 +0000 (00:19 +0000)]
Merge "bt: fix sdp service name by removing NULL char" am: 2766da83df am: 8eff94efb9
am: a54843d018

Change-Id: Ie541597466ef3e2e7b92c3dcd283bae5eea3649e

7 years agoMerge "bt: fix sdp service name by removing NULL char" am: 2766da83df
Timm Korte [Thu, 13 Jul 2017 00:17:34 +0000 (00:17 +0000)]
Merge "bt: fix sdp service name by removing NULL char" am: 2766da83df
am: 8eff94efb9

Change-Id: I13ea9e2e243efd14d6a3b43b9428996f24586e7e

7 years agoMerge "bt: fix sdp service name by removing NULL char"
Timm Korte [Thu, 13 Jul 2017 00:15:03 +0000 (00:15 +0000)]
Merge "bt: fix sdp service name by removing NULL char"
am: 2766da83df

Change-Id: I57de21a3a368cfc0312cce5498bb0beb70ae5cc2

7 years agoMerge "bt: fix sdp service name by removing NULL char"
Treehugger Robot [Thu, 13 Jul 2017 00:09:27 +0000 (00:09 +0000)]
Merge "bt: fix sdp service name by removing NULL char"

7 years agoAdd missing packet length checks while parsing BNEP control packets
Pavlin Radoslavov [Thu, 6 Jul 2017 23:51:35 +0000 (16:51 -0700)]
Add missing packet length checks while parsing BNEP control packets

Bug: 63146237
Test: External script
Change-Id: Ie778f3c99df81c85ed988f3af89b4edbcc2eeb99
Merged-In: Ie778f3c99df81c85ed988f3af89b4edbcc2eeb99
(cherry picked from commit 7feaeb006941a1494d7cdc0a2ffc4bb1004b38b4)

7 years agoMake GATT server code more readable am: b4e4799154 am: dd80e5f674
Jakub Pawlowski [Wed, 12 Jul 2017 22:59:27 +0000 (22:59 +0000)]
Make GATT server code more readable am: b4e4799154 am: dd80e5f674
am: 3688cf9d05

Change-Id: I443b22384d9ed6093c082ac199026233cb09bffa

7 years agoMake GATT server code more readable am: b4e4799154
Jakub Pawlowski [Wed, 12 Jul 2017 22:57:32 +0000 (22:57 +0000)]
Make GATT server code more readable am: b4e4799154
am: dd80e5f674

Change-Id: I61be21b37d2d0ea825412ad7cfecf3d7e74c905c

7 years agoMake GATT server code more readable
Jakub Pawlowski [Wed, 12 Jul 2017 22:55:28 +0000 (22:55 +0000)]
Make GATT server code more readable
am: b4e4799154

Change-Id: I4ef576808d9f258a45f3158a94f285035944f1cc

7 years agobt: fix sdp service name by removing NULL char
Timm Korte [Mon, 15 May 2017 06:30:00 +0000 (08:30 +0200)]
bt: fix sdp service name by removing NULL char

The Bluedroid stack uses a C string with terminating NULL char as a
service name. Since in BT, strings are TLV encoded (type, length,
value), this doesn't make sense.

Simple fix is to copy the string without the trailing NULL by
removing the "+1" after the strlen call when passing the string as
uint8_t array to the lower level functions.
The current behaviour keeps some older devices from being able to
connect to an Android providing a Serial Port profile due to having
the wrong service name (that is, including a NULL at the end instead
of the correct string).

Test: Checked against Linux BlueZ, which does not include this extra
null character.

Change-Id: I6a43024ff89ac09e4b2d2e5cfb407b6e9323f0bd
Signed-off-by: Timm Korte <timm.korte@gmail.com>
7 years agoAdd missing continuation offset check for SDP continuation requests
Pavlin Radoslavov [Sat, 8 Jul 2017 00:17:31 +0000 (17:17 -0700)]
Add missing continuation offset check for SDP continuation requests

Bug: 63146698
Test: External script
Change-Id: Iea52f1689dc12bfe0d4b57996f17db4bc3bd5983
Merged-In: Iea52f1689dc12bfe0d4b57996f17db4bc3bd5983

7 years agoDisable PAN Reverse Tethering when connection originated by the Remote
Pavlin Radoslavov [Fri, 7 Jul 2017 08:48:40 +0000 (01:48 -0700)]
Disable PAN Reverse Tethering when connection originated by the Remote

* Check for valid interactions between the three PAN profile roles per
  Table 1 in PAN Profile v1.0 spec.
* Explicitly disable connections to the local PANU if the remote is
  not PANU.

Bug: 63145701
Test: External script
Change-Id: I29a7e404ba7e4453b6a7c59148a2b3eb7395303a
Merged-In: I29a7e404ba7e4453b6a7c59148a2b3eb7395303a

7 years agoAdd a missing check for PAN buffer size before copying data
Pavlin Radoslavov [Thu, 6 Jul 2017 23:58:24 +0000 (16:58 -0700)]
Add a missing check for PAN buffer size before copying data

Bug: 63146237
Test: External script
Change-Id: I3e9c8a767a8a2a80ff56ccb48c56ca0d4b8c3402
Merged-In: I3e9c8a767a8a2a80ff56ccb48c56ca0d4b8c3402

7 years agoAllocate buffers of the right size when BT_HDR is included
Pavlin Radoslavov [Thu, 6 Jul 2017 20:39:02 +0000 (13:39 -0700)]
Allocate buffers of the right size when BT_HDR is included

Bug: 63146105
Test: External script
Change-Id: I1f2c871e3fcf57aabdad9d07905e6dae643bd496
Merged-In: I1f2c871e3fcf57aabdad9d07905e6dae643bd496

7 years agoAllow collection of Bluetooth firmware dumps in bugreports (3/3)
Ajay Panicker [Wed, 12 Jul 2017 18:45:08 +0000 (11:45 -0700)]
Allow collection of Bluetooth firmware dumps in bugreports (3/3)

This patch is temporary and should be removed once the bug is resolved

Bug: 63390057
Test: Force a hci timeout and collect a bugreport on walleye
Change-Id: Idab6d87c1b0540ea325fa1019ea2c9e97f3218f2

7 years agoGATT: Expose opportunistic client API to Java
Jack He [Wed, 12 Jul 2017 02:53:44 +0000 (02:53 +0000)]
GATT: Expose opportunistic client API to Java
am: e6f40cd3d9  -s ours

Change-Id: Ibc12e12a8f2824b4324dae332dbf69d3624893e4

7 years agoMake GATT server code more readable
Jakub Pawlowski [Tue, 11 Jul 2017 22:36:48 +0000 (15:36 -0700)]
Make GATT server code more readable

Test: compilation test
Change-Id: Ia176d7a89ccb9590c80e5b6b8af5a3495bf2ab16

7 years agoGATT: Expose opportunistic client API to Java
Jack He [Thu, 29 Jun 2017 20:58:47 +0000 (13:58 -0700)]
GATT: Expose opportunistic client API to Java

* Opportunistic GATT connection allows system service to subscribe to
  characteristic notifications without holding the BLE connection
* Exposing this flag to Java allows Android applications to use it

Bug: 63347806
Test: make, test on Android App
Change-Id: Ic470acd63bf45d1c33696abed1e93b30746fb7a2
Merged-In: Ic470acd63bf45d1c33696abed1e93b30746fb7a2
(cherry picked from commit 5120fedf20eb29fa65cef561c475d18d51197b25)

7 years agoMerge "test_vendor: Implement packet assembly for SDUs" am: 2dd6b59d57 am: 9d153dd187
jruthe [Tue, 11 Jul 2017 21:29:43 +0000 (21:29 +0000)]
Merge "test_vendor: Implement packet assembly for SDUs" am: 2dd6b59d57 am: 9d153dd187
am: a6cb7ae553

Change-Id: Ic7c88720d7e137ddb7fb4626381b3099a7843593

7 years agoMerge "test_vendor: Implement packet assembly for SDUs" am: 2dd6b59d57
jruthe [Tue, 11 Jul 2017 21:26:23 +0000 (21:26 +0000)]
Merge "test_vendor: Implement packet assembly for SDUs" am: 2dd6b59d57
am: 9d153dd187

Change-Id: I3844e71bb8faa237e552b31e5f5369b0f9462c50

7 years agoMerge "test_vendor: Implement packet assembly for SDUs"
jruthe [Tue, 11 Jul 2017 21:22:51 +0000 (21:22 +0000)]
Merge "test_vendor: Implement packet assembly for SDUs"
am: 2dd6b59d57

Change-Id: If0995021d9201b91acaf49a891e2682e5a4f855e

7 years agoMerge "test_vendor: Implement packet assembly for SDUs"
Treehugger Robot [Tue, 11 Jul 2017 21:16:16 +0000 (21:16 +0000)]
Merge "test_vendor: Implement packet assembly for SDUs"

7 years agoGATT: Expose opportunistic client API to Java am: 5120fedf20 am: 27a9e1249d
Jack He [Tue, 11 Jul 2017 20:46:28 +0000 (20:46 +0000)]
GATT: Expose opportunistic client API to Java am: 5120fedf20 am: 27a9e1249d
am: ab98252aeb

Change-Id: If5d94a54390718d73f8d55aacbf1d7c78fc2db7b

7 years agoGATT: Expose opportunistic client API to Java am: 5120fedf20
Jack He [Tue, 11 Jul 2017 20:37:57 +0000 (20:37 +0000)]
GATT: Expose opportunistic client API to Java am: 5120fedf20
am: 27a9e1249d

Change-Id: I00f499f1851c2ab6459cbcca0c4d02380005a392

7 years agoGATT: Expose opportunistic client API to Java
Jack He [Tue, 11 Jul 2017 20:24:11 +0000 (20:24 +0000)]
GATT: Expose opportunistic client API to Java
am: 5120fedf20

Change-Id: I96347363962687799e5ca56feefc40eef56ae7e2

7 years agoFix crashes on stack shutdown
Jakub Pawlowski [Tue, 11 Jul 2017 20:03:33 +0000 (20:03 +0000)]
Fix crashes on stack shutdown
am: 864cb9d2db  -s ours

Change-Id: I5164357cda3907805cb48cf6fd3347c0ed1db41d

7 years agoFix crashes on stack shutdown
Jakub Pawlowski [Thu, 22 Jun 2017 19:45:30 +0000 (12:45 -0700)]
Fix crashes on stack shutdown

During stack shutdown, Unregister would sometimes get called after the
stack is already cleaned up, and the AdvertiseManager::Get would crash
on null check assertion. Ensure that stack is initialized before
Unregister call.

Bug: 37888261
Test: none
Change-Id: I7a4bbcd24ec7d24d21d04fe842985baaac899321
Merged-In: I7a4bbcd24ec7d24d21d04fe842985baaac899321

7 years agotest_vendor: Implement packet assembly for SDUs
jruthe [Thu, 8 Jun 2017 22:33:32 +0000 (15:33 -0700)]
test_vendor: Implement packet assembly for SDUs

Created l2cap.* and l2cap_sdu.* for assembling an L2CAP packet from a
stream of SDU packets.

Test: Passed all tests in l2cap_test.cc and l2cap_sdu_test.cc
Change-Id: I64487ee67170b1dd4eda9555321b1ecf7ed57040

7 years agoGATT: Expose opportunistic client API to Java
Jack He [Thu, 29 Jun 2017 20:58:47 +0000 (13:58 -0700)]
GATT: Expose opportunistic client API to Java

* Opportunistic GATT connection allows system service to subscribe to
  characteristic notifications without holding the BLE connection
* Exposing this flag to Java allows Android applications to use it

Bug: 35874078
Test: make, test on Android App
Change-Id: Ic470acd63bf45d1c33696abed1e93b30746fb7a2

7 years agoMerge "Revert "Blacklist Kinivo BTC350 for Absolute Volume"" into oc-dr1-dev
Tom Turney [Fri, 7 Jul 2017 21:27:42 +0000 (21:27 +0000)]
Merge "Revert "Blacklist Kinivo BTC350 for Absolute Volume"" into oc-dr1-dev
am: 7e30dce07c

Change-Id: Ic44edb9e7a70144572f1a8866f39bc41b34e56ba

7 years agoMerge "Revert "Blacklist Kinivo BTC350 for Absolute Volume"" into oc-dr1-dev
TreeHugger Robot [Fri, 7 Jul 2017 21:22:41 +0000 (21:22 +0000)]
Merge "Revert "Blacklist Kinivo BTC350 for Absolute Volume"" into oc-dr1-dev

7 years agoDo not delete device record on HCI_ERR_KEY_MISSING
Jinguang Dong [Fri, 7 Jul 2017 19:56:42 +0000 (19:56 +0000)]
Do not delete device record on HCI_ERR_KEY_MISSING
am: 8a836291dc

Change-Id: Ia26ee3594d1e608308b23e498caa5f47850de94c

7 years agoRevert "Blacklist Kinivo BTC350 for Absolute Volume"
Tom Turney [Fri, 7 Jul 2017 18:11:46 +0000 (18:11 +0000)]
Revert "Blacklist Kinivo BTC350 for Absolute Volume"

This reverts commit 84e8fa9b0873c31b6ee5dce53405db9e9ff77a31.

This is actually due to b/63073544 not an issue with the device.

Change-Id: I8433adcfc7ff8f3bf8a16eccb72f0522fa896fef

7 years agoDo not delete device record on HCI_ERR_KEY_MISSING
Jinguang Dong [Wed, 28 Jun 2017 01:50:37 +0000 (09:50 +0800)]
Do not delete device record on HCI_ERR_KEY_MISSING

If an auth_complete event is received with HCI_ERR_KEY_MISSING, the
p_dev_rec->sm4 flag will be set to "BTM_SM4_UNKNOWN" in the
BTM_SecClearSecurityFlags() function. This will prevent the
BTM_SM4_RETRY procedure from being executed, which can cause
pairing failures.

To reproduce:
 1. Two Phones, A: Android O, B: Android N.
 2. Enable B in Bluetooth visable mode
 3. A start discovery and create pairing with B successfully
 4. B cancel pairing with A by remove A from pairing device
    list of B.
 5. A create paring with B again by touch paired device in A,
    this first step will be failed.

Bug: 62615213
Test: manual
Change-Id: I514ba2f4d0fd2621c11bd83aeec24b8c6c6d2d5a
Signed-off-by: Yequan Song <songyequan@huawei.com>
(cherry picked from commit 549ec693c2a3a240a5b688a1311cc7c55daa59fc)

7 years agoMerge "Merge "Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a...
Android Build Merger (Role) [Fri, 7 Jul 2017 06:41:17 +0000 (06:41 +0000)]
Merge "Merge "Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d02c" into oc-dev-plus-aosp am: 5562865e69" into oc-dr1-dev-plus-aosp

7 years agoMerge "Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d...
Jiyong Park [Fri, 7 Jul 2017 06:41:08 +0000 (06:41 +0000)]
Merge "Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d02c" into oc-dev-plus-aosp
am: 5562865e69

Change-Id: I8248c9bdb3967f41927766cd658fa35eef8f4dbb

7 years agoMerge "Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d...
Jiyong Park [Fri, 7 Jul 2017 06:41:04 +0000 (06:41 +0000)]
Merge "Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d02c" into oc-dev-plus-aosp
am: 5562865e69

Change-Id: Ic65b0b4a8fe2e47cec599c24c1dfe3cb42814e3d

7 years agoMerge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d02c
Jiyong Park [Fri, 7 Jul 2017 06:40:47 +0000 (06:40 +0000)]
Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d02c
am: a081b71033

Change-Id: Ib7882ffb5f0fd9e186a5127edfa3932a67450bfb

7 years agoMerge "Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d...
Android Build Merger (Role) [Fri, 7 Jul 2017 06:37:24 +0000 (06:37 +0000)]
Merge "Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a am: 9ae297d02c" into oc-dev-plus-aosp

7 years agoMerge "Mark libbluetooth-types as vendor_available" am: 29f359181a
Jiyong Park [Fri, 7 Jul 2017 06:37:15 +0000 (06:37 +0000)]
Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a
am: 9ae297d02c

Change-Id: Id9d7b0469261cde673a9d3206eb789f089967fd3

7 years agoMerge "Mark libbluetooth-types as vendor_available" am: 29f359181a
Jiyong Park [Fri, 7 Jul 2017 06:37:05 +0000 (06:37 +0000)]
Merge "Mark libbluetooth-types as vendor_available" am: 29f359181a
am: 9ae297d02c

Change-Id: I9257d4773e2e5b69ae21370e3b5b362967b9f123

7 years agoMerge "Mark libbluetooth-types as vendor_available"
Jiyong Park [Fri, 7 Jul 2017 06:33:15 +0000 (06:33 +0000)]
Merge "Mark libbluetooth-types as vendor_available"
am: 29f359181a

Change-Id: Ic63d5ccafceb91f2eddf3a41c8a3b8be6d200b0c

7 years agoMerge "Mark libbluetooth-types as vendor_available"
Treehugger Robot [Fri, 7 Jul 2017 06:27:41 +0000 (06:27 +0000)]
Merge "Mark libbluetooth-types as vendor_available"

7 years agoDo not delete device record on HCI_ERR_KEY_MISSING am: 549ec693c2 am: b415ac8648
Jinguang Dong [Fri, 7 Jul 2017 06:10:44 +0000 (06:10 +0000)]
Do not delete device record on HCI_ERR_KEY_MISSING am: 549ec693c2 am: b415ac8648
am: 009ffa8c7e

Change-Id: I4e2e1e191c85f2bdb6ed559a6eec39ebed4be08f

7 years agoDo not delete device record on HCI_ERR_KEY_MISSING am: 549ec693c2
Jinguang Dong [Fri, 7 Jul 2017 06:06:43 +0000 (06:06 +0000)]
Do not delete device record on HCI_ERR_KEY_MISSING am: 549ec693c2
am: b415ac8648

Change-Id: I571bc39274f4f99663948789b323eba6c598b5f6

7 years agoDo not delete device record on HCI_ERR_KEY_MISSING
Jinguang Dong [Fri, 7 Jul 2017 06:02:43 +0000 (06:02 +0000)]
Do not delete device record on HCI_ERR_KEY_MISSING
am: 549ec693c2

Change-Id: I8c9ea5fad01fbb68b9f7067f7682cc9cd870daa2

7 years agoDo not delete device record on HCI_ERR_KEY_MISSING
Jinguang Dong [Wed, 28 Jun 2017 01:50:37 +0000 (09:50 +0800)]
Do not delete device record on HCI_ERR_KEY_MISSING

If an auth_complete event is received with HCI_ERR_KEY_MISSING, the
p_dev_rec->sm4 flag will be set to "BTM_SM4_UNKNOWN" in the
BTM_SecClearSecurityFlags() function. This will prevent the
BTM_SM4_RETRY procedure from being executed, which can cause
pairing failures.

To reproduce:
 1. Two Phones, A: Android O, B: Android N.
 2. Enable B in Bluetooth visable mode
 3. A start discovery and create pairing with B successfully
 4. B cancel pairing with A by remove A from pairing device
    list of B.
 5. A create paring with B again by touch paired device in A,
    this first step will be failed.

Bug: 62615213
Test: manual
Change-Id: I514ba2f4d0fd2621c11bd83aeec24b8c6c6d2d5a
Signed-off-by: Yequan Song <songyequan@huawei.com>
7 years agoMark libbluetooth-types as vendor_available
Jiyong Park [Fri, 7 Jul 2017 04:29:16 +0000 (13:29 +0900)]
Mark libbluetooth-types as vendor_available

libbluetooty-types is used by a vendor module
android.hardware.bluetooth@1.0-service.sim, thus marking it as
vendor_available so that the lib is allowed for the HAL service when
building with BOARD_VNDK_VERSION.

Bug: 37342627
Test: BOARD_VNDK_VERSION=current m -j
android.hardware.bluetooth@1.0-service.sim

Change-Id: I39d071fc249ce6842e7175751abd6249b9367231

7 years agoMerge "Merge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into...
Android Build Merger (Role) [Fri, 7 Jul 2017 01:45:55 +0000 (01:45 +0000)]
Merge "Merge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master am: 4669be25d5  -s ours" into oc-dev-plus-aosp am: e2dedfe267  -s ours" into oc-dr1-dev-plus-aosp

7 years agoMerge "Merge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into...
Android Build Merger (Role) [Fri, 7 Jul 2017 01:45:53 +0000 (01:45 +0000)]
Merge "Merge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master am: 4669be25d5  -s ours" into oc-dev-plus-aosp am: e2dedfe267  -s ours" into oc-dr1-dev-plus-aosp

7 years agoMerge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage...
Jakub Pawlowski [Fri, 7 Jul 2017 01:45:46 +0000 (01:45 +0000)]
Merge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master am: 4669be25d5  -s ours" into oc-dev-plus-aosp
am: e2dedfe267  -s ours

Change-Id: I57e407e09cf016d3e1c80b8ff23c906cd2f804d5

7 years agoMerge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage...
Jakub Pawlowski [Fri, 7 Jul 2017 01:45:45 +0000 (01:45 +0000)]
Merge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master am: 4669be25d5  -s ours" into oc-dev-plus-aosp
am: e2dedfe267  -s ours

Change-Id: Ifc43f0dd2d2be6fd811d2e07ed78c2543b454d3f

7 years agoMerge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage...
Android Build Merger (Role) [Fri, 7 Jul 2017 01:45:39 +0000 (01:45 +0000)]
Merge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master am: 4669be25d5  -s ours am: 819ea67f58  -s ours" into oc-dr1-dev-plus-aosp

7 years agoMerge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp...
Jakub Pawlowski [Fri, 7 Jul 2017 01:45:31 +0000 (01:45 +0000)]
Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master am: 4669be25d5  -s ours
am: 819ea67f58  -s ours

Change-Id: I105d3635878c632c6f74e856cdd8191676e148a5

7 years agoMerge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp...
Jakub Pawlowski [Fri, 7 Jul 2017 01:45:30 +0000 (01:45 +0000)]
Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master am: 4669be25d5  -s ours
am: 819ea67f58  -s ours

Change-Id: I0a474b7c088dd21e5d4d48cdca036350c0bde000

7 years agoMerge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744 am: 56978c211d ...
Android Build Merger (Role) [Fri, 7 Jul 2017 01:44:28 +0000 (01:44 +0000)]
Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744 am: 56978c211d  -s ours am: 8a5238a97a  -s ours" into oc-dr1-dev-plus-aosp

7 years agoMerge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage...
Android Build Merger (Role) [Fri, 7 Jul 2017 01:43:38 +0000 (01:43 +0000)]
Merge "Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master am: 4669be25d5  -s ours" into oc-dev-plus-aosp

7 years agoMerge "Make RawAddress into a class (1/3)" am: 4a1fc85744 am: 56978c211d -s ours
Jakub Pawlowski [Fri, 7 Jul 2017 01:43:30 +0000 (01:43 +0000)]
Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744 am: 56978c211d  -s ours
am: 8a5238a97a  -s ours

Change-Id: I91ce9a209d77e13aef59d087a5e4910499f9e45a

7 years agoMerge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp...
Jakub Pawlowski [Fri, 7 Jul 2017 01:43:27 +0000 (01:43 +0000)]
Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master
am: 4669be25d5  -s ours

Change-Id: Ida9eb27eab54f87d9791dcb7108cb7351aec4fa2

7 years agoMerge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp...
Jakub Pawlowski [Fri, 7 Jul 2017 01:43:19 +0000 (01:43 +0000)]
Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master
am: 4669be25d5  -s ours

Change-Id: Id8d611928dc23949ec94cf24ce5ec818e0df48b8

7 years agoMerge "Make RawAddress into a class (1/3)" am: 4a1fc85744 am: 56978c211d -s ours
Jakub Pawlowski [Fri, 7 Jul 2017 01:43:19 +0000 (01:43 +0000)]
Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744 am: 56978c211d  -s ours
am: 8a5238a97a  -s ours

Change-Id: Ib448b233562470db184826e5136e4d9dfde367c3

7 years agoMerge "Make RawAddress into a class (1/3)" am: 4a1fc85744 am: 6ad7d19e69
Jakub Pawlowski [Fri, 7 Jul 2017 01:41:18 +0000 (01:41 +0000)]
Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744 am: 6ad7d19e69
am: 96481ffe75

Change-Id: I2d8c1d2040f29c47e144a46d9f3ccc6ceb11edb0

7 years agoMerge "Make RawAddress into a class (1/3)" am: 4a1fc85744
Jakub Pawlowski [Fri, 7 Jul 2017 01:40:14 +0000 (01:40 +0000)]
Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744
am: 56978c211d  -s ours

Change-Id: Ib77fc61181d7e8ee035a706e149868699a9decc1

7 years agoMerge "Make RawAddress into a class (1/3)" am: 4a1fc85744
Jakub Pawlowski [Fri, 7 Jul 2017 01:38:05 +0000 (01:38 +0000)]
Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744
am: 6ad7d19e69

Change-Id: I56c4b867de829c86dd4f742ac1fce01ce2951f4b

7 years agoMerge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp...
Android Build Merger (Role) [Fri, 7 Jul 2017 01:37:41 +0000 (01:37 +0000)]
Merge "Merge "Make RawAddress into a class (1/3)" am: 4a1fc85744" into stage-aosp-master

7 years agoMerge "Make RawAddress into a class (1/3)"
Jakub Pawlowski [Fri, 7 Jul 2017 01:36:41 +0000 (01:36 +0000)]
Merge "Make RawAddress into a class (1/3)"
am: 4a1fc85744

Change-Id: I61d249aa17044cd55b6834bc9563f648362621b6

7 years agoMerge "Make RawAddress into a class (1/3)"
Jakub Pawlowski [Fri, 7 Jul 2017 01:35:36 +0000 (01:35 +0000)]
Merge "Make RawAddress into a class (1/3)"
am: 4a1fc85744

Change-Id: I05b23ab3aff4d61dd8b04a3f011e832305203ce5