OSDN Git Service

android-x86/system-bt.git
8 years agoSet disable timer in case of any active ACL connection
Srinu Jella [Wed, 8 Jun 2016 19:13:14 +0000 (19:13 +0000)]
Set disable timer in case of any active ACL connection
am: 3e4f01ada8

Change-Id: Ia22d37db6f47cf634a6c38a3f169140054b95ee8

8 years agoSet disable timer in case of any active ACL connection
Srinu Jella [Wed, 8 Jun 2016 10:20:53 +0000 (15:50 +0530)]
Set disable timer in case of any active ACL connection

Use Case: Disable time out when atleast one active ACL connections

Steps:
1. Turn ON Bluetooth
2. Connect to any Headset
3. Turn OFF bluetooth.

Failure: Turn OFF bluetooth is failed when atleast one active ACL connections

Root Cause:i If we have one or more active ACL links, so it is not notitying
BTA_DM_DISABLE_EVT to upper layer.

Fix: Set disable timer in case of any active ACL connection

Change-Id: Ica47717119f1ab9fa9f4f5244e8483c408276a2a

8 years agoMerge \"Reject L2CAP INFO RSP and ECHO RSP on the LE signaling channel\"
Venkata Jagadeesh [Wed, 8 Jun 2016 00:57:05 +0000 (00:57 +0000)]
Merge \"Reject L2CAP INFO RSP and ECHO RSP on the LE signaling channel\"
am: fe7f53d6b3

Change-Id: Ida2dd0bff8210d63e3aa02f8261a9633352f0204

8 years agoMerge \"Fix payload size for GATT Read by type request\"
Subramanian Srinivasan [Wed, 8 Jun 2016 00:57:04 +0000 (00:57 +0000)]
Merge \"Fix payload size for GATT Read by type request\"
am: 89b997468c

Change-Id: I26c3889d95d5e7d0b1b94cbabdbbe91404fd6530

8 years agoMerge "Reject L2CAP INFO RSP and ECHO RSP on the LE signaling channel"
Treehugger Robot [Wed, 8 Jun 2016 00:45:46 +0000 (00:45 +0000)]
Merge "Reject L2CAP INFO RSP and ECHO RSP on the LE signaling channel"

8 years agoMerge "Fix payload size for GATT Read by type request"
Treehugger Robot [Wed, 8 Jun 2016 00:45:21 +0000 (00:45 +0000)]
Merge "Fix payload size for GATT Read by type request"

8 years agobtm: Restrict EXTENDED_INQUIRY_RESULT to 1 result
Myles Watson [Wed, 8 Jun 2016 00:25:33 +0000 (00:25 +0000)]
btm: Restrict EXTENDED_INQUIRY_RESULT to 1 result
am: 1a011544dc

Change-Id: Ibd967e028594f6cbb64b4040016012fb53bb047d

8 years agoFix payload size for GATT Read by type request
Subramanian Srinivasan [Fri, 27 May 2016 23:32:55 +0000 (16:32 -0700)]
Fix payload size for GATT Read by type request

Payload size for GATT Read by type request for UUID32 and UUID128
are incorrectly allocated. This leads to memory overflow when
Read by type request is sent for them and eventually results
in crash during free. This change makes sure that the payload
can accomodate upto 128 bit UUID.

This crash is observed while running TC_GAR_CL_BV_03_C Qual test
case.

Bug: 29011042
Change-Id: Ib2b41b769b394670099f4549f204e2972f7df876

8 years agoReject L2CAP INFO RSP and ECHO RSP on the LE signaling channel
Venkata Jagadeesh [Fri, 27 May 2016 10:06:20 +0000 (15:36 +0530)]
Reject L2CAP INFO RSP and ECHO RSP on the LE signaling channel

Steps:
Execute TC_LE_REJ_BI_02_C

Failure:
PTS stuck after sending INFO RSP, ECHO RSP on the LE signaling channel

Root Cause:
The Bluetooth stack is not rejecting INFO RSP, ECHO RSP even though
these commands are invalid for the LE signaling Channel.

Fix:
Reject the INFO RSP, ECHO RSP with error L2CAP_CMD_REJ_NOT_UNDERSTOOD.

Bug: 27852645
Change-Id: Ie09f658d606206cbdbea928e8cb6d10332743cf4

8 years agobtm: Restrict EXTENDED_INQUIRY_RESULT to 1 result
Myles Watson [Tue, 7 Jun 2016 23:14:18 +0000 (16:14 -0700)]
btm: Restrict EXTENDED_INQUIRY_RESULT to 1 result

The spec only allows one result per event.
Abort processing and return if the spec is not followed.

Bug: 29141745
Change-Id: Ic414b28adadec274779b0d953d12d499a619aff6
Signed-off-by: Myles Watson <mylesgw@google.com>
8 years agoFix invalid BDA parameter passing for connection parameter updates
Jakub Pawlowski [Tue, 7 Jun 2016 01:50:33 +0000 (01:50 +0000)]
Fix invalid BDA parameter passing for connection parameter updates
am: 3021c5a5aa

* commit '3021c5a5aac9760e8c4885cbf9c220d1b04dbdb3':
  Fix invalid BDA parameter passing for connection parameter updates

Change-Id: I649b1b08ad84056dbdd44ca4258280bc57639215

8 years agoFix invalid BDA parameter passing for connection parameter updates
Jakub Pawlowski [Fri, 3 Jun 2016 22:42:32 +0000 (15:42 -0700)]
Fix invalid BDA parameter passing for connection parameter updates

The BD_ADDR type is not a struct, just an array of bytes. Therefore,
Bind does not know how to store it for later execution, and just stores
the pointer to the first element, which is not valid at time of
execution.

Instead use bt_bdaddr_t, which is a struct. Bind will copy it's content
properly.

Change-Id: I4875aae4d7cbb809821d91a13554b8fdf310a7fe

8 years agoRemote device changes for SMP certification
Nitin Arora [Mon, 6 Jun 2016 21:22:04 +0000 (21:22 +0000)]
Remote device changes for SMP certification
am: 0bd0c8fc88

* commit '0bd0c8fc88a7141691a7ca839b11cb711945ee33':
  Remote device changes for SMP certification

Change-Id: Id8e7028ae84257b6831bb6ae058c1495e63ea10a

8 years agoRemote device changes for SMP certification
Nitin Arora [Tue, 15 Mar 2016 22:00:36 +0000 (15:00 -0700)]
Remote device changes for SMP certification

Use Case:
Certification test cases for SMP require various scenarios
where the remote device needs to show a specific behavior
where it fails the pairing in a certain way, and the DUT is
required to abort the pairing properly.
In abcense of a proper PTS suite to execute these test cases,
we can use another device running the same host by configuring
certain run time property.

Test Cases:
TP/SCJW/BI-02-C
TP/SCJW/BV-02-C
TP/SCPK/BI-03-C
TP/SCPK/BI-04-C
TP/SCPK/BV-02-C
TP/SCPK/BV-03-C
TP/SCJW/BI-01-C
TP/SCCT/BV-01-C
TP/SCCT/BV-02-C
TP/SCPK/BI-01-C
TP/SCPK/BI-02-C
TP/SCPK/BV-04-C
TP/SCPK/BV-01-C

Fix:
Added a property in the bt_stack.conf file. The property name
is "SmpFailureCase". The values 2 to 6(inclusive), are forcausing SMP
failures with various failure reasons.
Failure case 1 and 9 are for producing error "Confirm value failure".
Cases 7 and 8 are for generating specific errors at pair cancel.

Note:
The default use of this feature is controlled using a compile
time flag BTM_BLE_SMP_CERTIFICATION.
The BTM_BLE_SMP_CERTIFICATION = TRUE is needed only while we
wait for the PTS support for the LE Secure connections.

Bug: 27852645
Change-Id: I1f7a8ff2659d85b5978b75870c57162a34d394d0

8 years agoClear BLE block from device records at unpair
Nitin Arora [Mon, 6 Jun 2016 17:44:36 +0000 (17:44 +0000)]
Clear BLE block from device records at unpair
am: 266ff1d759

* commit '266ff1d759e7713b957cb73c8d0c7a0c0b70c7dd':
  Clear BLE block from device records at unpair

Change-Id: I5cf9341cae1887226d7947a69b985d1d43f52254

8 years agoClear BLE block from device records at unpair
Nitin Arora [Mon, 25 Apr 2016 21:47:51 +0000 (14:47 -0700)]
Clear BLE block from device records at unpair

Use Case:
Pair and unpair LE remote device repeatedly. The repair
intermittently fails with the error "DHKey Check Failure"

Failure:
Pairing failure is observed when pairing is performed
after unpairing, without performing a BT reset.
Further analysis of the SMP logs indicate that DUT uses the
static address of the remote device for calculation of the
MacKey value. At the time of pairing, the remote RPA should
be used (and the static address has not yet been distributed either).
The problem is caused by the previous dev record which is left in
the stack, and at the time of repair, stack picks the old device
record and reuses it.

Fix:
This change removes the entire BLE block from the device record,
after the unpairing is performed, so that a new device record
is allocated, after the repairing is done.

Bug: 27852645
Change-Id: I8d605d1bb3b1c32061a8d8a7a7fe0fe200030abc

8 years agoReset max_interval to BTM_BLE_CONN_INT_MIN_LIMIT
Eri Kasamatsu [Fri, 3 Jun 2016 21:53:38 +0000 (21:53 +0000)]
Reset max_interval to BTM_BLE_CONN_INT_MIN_LIMIT
am: 3bd286a411

* commit '3bd286a4112de2c68e7188c0001d884454686992':
  Reset max_interval to BTM_BLE_CONN_INT_MIN_LIMIT

Change-Id: I688b68898a107ad28678a096739a6dde5e074c24

8 years agoReset max_interval to BTM_BLE_CONN_INT_MIN_LIMIT
Eri Kasamatsu [Mon, 9 Nov 2015 05:40:02 +0000 (14:40 +0900)]
Reset max_interval to BTM_BLE_CONN_INT_MIN_LIMIT

In case of min_interval < BTM_BLE_CONN_INT_MIN_LIMIT
and max_interval < BTM_BLE_CONN_INT_MIN_LIMIT,
min_interval is reset to BTM_BLE_CONN_INT_MIN_LIMIT
but max_interval is not reset.
Then valid connection parameter updates can be rejected.

To avoid this, reset max_interval to BTM_BLE_CONN_INT_MIN_LIMIT
when max_interval is smaller than BTM_BLE_INT_MIN_LIMIT.

Change-Id: I5f54ddc0276f40d667ff433557b74ea4b100058d

8 years agoMerge "bt: Update libchrome APIs to r395517"
Luis Hector Chavez [Wed, 1 Jun 2016 21:57:38 +0000 (21:57 +0000)]
Merge "bt: Update libchrome APIs to r395517"
am: cb3c6f3cd0

* commit 'cb3c6f3cd0b908e36443d41c2d736b88d742ee1a':
  bt: Update libchrome APIs to r395517

Change-Id: I579baf27f8e777b16c559ba30bf649fc3958b94e

8 years agonet_test_bluetooth: RFCOMM test refactor
Ajay Panicker [Wed, 1 Jun 2016 21:57:35 +0000 (21:57 +0000)]
net_test_bluetooth: RFCOMM test refactor
am: fa717c0b47

* commit 'fa717c0b47bb1fed04da295eaa580a92bc08c622':
  net_test_bluetooth: RFCOMM test refactor

Change-Id: I4f5d85e43462e666ead4714b92b77cf95db3bdff

8 years agoMerge "bt: Update libchrome APIs to r395517"
Luis Hector Chavez [Wed, 1 Jun 2016 21:50:00 +0000 (21:50 +0000)]
Merge "bt: Update libchrome APIs to r395517"

8 years agonet_test_bluetooth: RFCOMM test refactor
Ajay Panicker [Mon, 7 Dec 2015 22:18:16 +0000 (14:18 -0800)]
net_test_bluetooth: RFCOMM test refactor

Properly implement RFCOMM tests into net_test_rfcomm using GUnit.
Contains all the RFCOMM tests and the base class that the tests use.
This test currently requires the DUT to be paired with an HFP capable
device.

Bug: 25793348
Change-Id: I683db7c5f2779373b2e343c7ad21268e4969d014

8 years agoRemove currently unused peer device module and tests
Jakub Pawlowski [Wed, 1 Jun 2016 01:20:13 +0000 (01:20 +0000)]
Remove currently unused peer device module and tests
am: bc472821fe

* commit 'bc472821fe8aac8fca089082496f5b7d067ffae8':
  Remove currently unused peer device module and tests

Change-Id: I6f9893bbb49f077b250b17c6ab73ead56ab8b60f

8 years agoRemove currently unused peer device module and tests
Jakub Pawlowski [Sat, 28 May 2016 00:06:39 +0000 (17:06 -0700)]
Remove currently unused peer device module and tests

The module is currently not used and it is currently not obvious if this
should be a module in the first place.

Filed separate bug (#29057391) to re-visit the concept in a future
refactor, but removing unused code for now.

Bug: 29000421
Change-Id: Ie369574e62281fa1d7c3284c86c4509de558fa15

8 years agoBump HDP version to 1.1
Andre Eisenbach [Wed, 1 Jun 2016 00:09:40 +0000 (00:09 +0000)]
Bump HDP version to 1.1
am: bb838444c3

* commit 'bb838444c37642b7272e3ae4acaaa7a06a568cdb':
  Bump HDP version to 1.1

Change-Id: I7e39e0c6caace2077133c8cf6dd1ae9aa6b82673

8 years agoBump HDP version to 1.1
Andre Eisenbach [Tue, 31 May 2016 21:18:36 +0000 (14:18 -0700)]
Bump HDP version to 1.1

Change-Id: I0bdec6fffa097dc919ee495216a2f272cc0dcf1e

8 years agoLimit number of SBC frames to fit into single MTU
Ayan Ghosh [Mon, 30 May 2016 23:09:24 +0000 (23:09 +0000)]
Limit number of SBC frames to fit into single MTU
am: e9a52af36d

* commit 'e9a52af36d087ea68ec7ba5ed3f25c24fb3cdf64':
  Limit number of SBC frames to fit into single MTU

Change-Id: Ia96d418dfa7968981e1585f7d4f078035c5a317b

8 years agoLimit number of SBC frames to fit into single MTU
Ayan Ghosh [Mon, 11 Nov 2013 13:55:16 +0000 (19:25 +0530)]
Limit number of SBC frames to fit into single MTU

- Calculate number of SBC frames to fit into single MTU for EDR capable
  remote devices. This makes sure the maximum utilization of the
  available bandwidth, keeping the bitrate at high quality.
- This change helps to address the discrepancy seen with a few available
  2 Mbps headsets which set the AVDTP media MTU size greater than the
  2DH5 packet payload size which eventually forces AVDTP packets to get
  fragmented in the controller. This change ensures packing of the SBC
  frames in a way that AVDTP packet size fits within the 2DH5 payload
  size.
- As packet size is restricted to meet the required bit rate more than
  one AVDTP packet can be sent to the controller in a given iteration
  based on the bit rate requirement.

Bug: 24875861
Change-Id: Icae7656ad563bbbdef65ecbfa15a89b26cf9edb2

8 years agoMerge "Update the HCI unit test if BT_CLEAN_TURN_ON_DISABLED is TRUE"
Pavlin Radoslavov [Fri, 27 May 2016 20:12:40 +0000 (20:12 +0000)]
Merge "Update the HCI unit test if BT_CLEAN_TURN_ON_DISABLED is TRUE"
am: 692c63af2e

* commit '692c63af2e1a8adc5bb98084b16e26ba8445ecfe':
  Update the HCI unit test if BT_CLEAN_TURN_ON_DISABLED is TRUE

Change-Id: Id962d5c6fac28fd352ca0f4b191a86c42460cba2

8 years agoMerge "Update the HCI unit test if BT_CLEAN_TURN_ON_DISABLED is TRUE"
Treehugger Robot [Fri, 27 May 2016 20:01:16 +0000 (20:01 +0000)]
Merge "Update the HCI unit test if BT_CLEAN_TURN_ON_DISABLED is TRUE"

8 years agoFix misc-macro-parentheses warnings in embdrv/sbc.
Chih-Hung Hsieh [Fri, 27 May 2016 19:26:25 +0000 (19:26 +0000)]
Fix misc-macro-parentheses warnings in embdrv/sbc.
am: 7b7b057828

* commit '7b7b0578285281c762bd52255072cb34800ec7ea':
  Fix misc-macro-parentheses warnings in embdrv/sbc.

Change-Id: Ifd3ad6cfb1b0f12230d8367f9cf2a8b84c1b7fd9

8 years agoUpdate the HCI unit test if BT_CLEAN_TURN_ON_DISABLED is TRUE
Pavlin Radoslavov [Fri, 27 May 2016 19:07:06 +0000 (12:07 -0700)]
Update the HCI unit test if BT_CLEAN_TURN_ON_DISABLED is TRUE

Bug: 28614494
Change-Id: I3f4a923f9e14faef57b2d694bfc253fd10749414

8 years agoFix misc-macro-parentheses warnings in embdrv/sbc.
Chih-Hung Hsieh [Fri, 20 May 2016 17:22:12 +0000 (10:22 -0700)]
Fix misc-macro-parentheses warnings in embdrv/sbc.

When compiled with WITH_TIDY=1, clang-tidy warns about
missing parameters around macro parameters.

Bug: 28705665
Change-Id: I79d234b88e090137412936b80303d21f0c59b0ae

8 years agoFix misc-macro-parentheses warnings
Chih-Hung Hsieh [Fri, 27 May 2016 18:23:45 +0000 (18:23 +0000)]
Fix misc-macro-parentheses warnings
am: 63b0519c3f

* commit '63b0519c3f0d1c0cc523e0e9553c60fc68651acc':
  Fix misc-macro-parentheses warnings

Change-Id: If0986131e3e16f67f2de535db7825b12101c05a1

8 years agoFix misc-macro-parentheses warnings
Chih-Hung Hsieh [Fri, 20 May 2016 17:29:31 +0000 (10:29 -0700)]
Fix misc-macro-parentheses warnings

When compiled with WITH_TIDY=1, clang-tidy warns about
missing parameters around macro parameters.

Bug: 28705665
Change-Id: I89c23cfe6eaefae5ef3c648a7c123c0501662c13

8 years agoDO NOT MERGE Randomize allocation canary
Marie Janssen [Fri, 27 May 2016 03:27:38 +0000 (03:27 +0000)]
DO NOT MERGE Randomize allocation canary
am: 3387396e16  -s ours

* commit '3387396e167819510c499b5a5486b499b3f4868f':
  DO NOT MERGE Randomize allocation canary

Change-Id: I87d650f2da46121e7b436a92f21d302f9870e5ee

8 years agoDO NOT MERGE Randomize allocation canary
Marie Janssen [Fri, 4 Mar 2016 01:50:26 +0000 (17:50 -0800)]
DO NOT MERGE Randomize allocation canary

A static allocation canary can be susceptible to buffer overflow
exploit code bypassing, so this randomizes it on every run.

Bug: 27411268
Change-Id: I81b06f89951a012c08d846042653ec957f3e9127
(cherry picked from commit 7c054350fb7da9da1fdb86e7f7b9a801cf1c39e4)

8 years agoFix GATT attribute value allocation
Andre Eisenbach [Fri, 27 May 2016 00:32:12 +0000 (00:32 +0000)]
Fix GATT attribute value allocation
am: e509caac6c

* commit 'e509caac6cc2bcecccac4e9d75f9df31ccd51a84':
  Fix GATT attribute value allocation

Change-Id: I4829af8c54e925fa21f6fb150237d4c92fc2711e

8 years agoFix GATT attribute value allocation
Andre Eisenbach [Fri, 27 May 2016 00:13:42 +0000 (17:13 -0700)]
Fix GATT attribute value allocation

new type(arg) != new type[arg].... :'(

Bug: 28888632
Change-Id: I5adb2d21b8c77f9edf6ff22f56341358bfec817e

8 years agobt: Update libchrome APIs to r395517
Luis Hector Chavez [Sat, 21 May 2016 06:10:00 +0000 (23:10 -0700)]
bt: Update libchrome APIs to r395517

The new libchrome has been ported from Chromium and some APIs have
changed. Make necessary changes at call sites.

Change-Id: Idb7365dd5b0b66c3926fc07b2264c9bc3477ae20

8 years agoMerge "test_vendor_lib: Add initial support for BLE"
Myles Watson [Thu, 26 May 2016 23:27:40 +0000 (23:27 +0000)]
Merge "test_vendor_lib: Add initial support for BLE"
am: 89467754b2

* commit '89467754b296a0907c4fd481e2a2a8d90fd874da':
  test_vendor_lib: Add initial support for BLE

Change-Id: I38ff03ba36f67f7b76f2fa2b5378022d1e8b3321

8 years agoMerge "test_vendor_lib: Add initial support for BLE"
Treehugger Robot [Thu, 26 May 2016 23:10:11 +0000 (23:10 +0000)]
Merge "test_vendor_lib: Add initial support for BLE"

8 years agoDo not allow LE connection timeout smaller than 1s for HID devices
Jakub Pawlowski [Thu, 26 May 2016 22:41:07 +0000 (22:41 +0000)]
Do not allow LE connection timeout smaller than 1s for HID devices
am: cbeed50f71

* commit 'cbeed50f714a3b15a7be86ba484a3c89a4b6e9d7':
  Do not allow LE connection timeout smaller than 1s for HID devices

Change-Id: I6174d66fef858f74daa609ab1d54ef5867083f5f

8 years agoDo not allow LE connection timeout smaller than 1s for HID devices
Jakub Pawlowski [Thu, 26 May 2016 22:13:04 +0000 (15:13 -0700)]
Do not allow LE connection timeout smaller than 1s for HID devices

Bug: 28979841
Change-Id: I520608a13224601fb9101d00c08b34cdb0f8d374

8 years agoLinux build fix
Jakub Pawlowski [Thu, 26 May 2016 22:06:33 +0000 (22:06 +0000)]
Linux build fix
am: 0a0a7e96e7

* commit '0a0a7e96e7092f03a6dc568eb6358c6f4499e56a':
  Linux build fix

Change-Id: I5b3ce85c972beb144238e26912fa20c733df433d

8 years agoLinux build fix
Jakub Pawlowski [Thu, 26 May 2016 22:03:57 +0000 (15:03 -0700)]
Linux build fix

Change-Id: Iae3d7d77dda70a288022d81a5f3c8f156b95adc9

8 years agoConvert GATT related BTA code to C++
Jakub Pawlowski [Thu, 26 May 2016 22:01:46 +0000 (22:01 +0000)]
Convert GATT related BTA code to C++
am: 1911770165

* commit '19117701657073f3b8ba03620c081a8976b318a6':
  Convert GATT related BTA code to C++

Change-Id: Icafa738fd8aaf822b9fb4de9b7a922c7e11e59cc

8 years agoRemove all mentions of hashmap
Jakub Pawlowski [Thu, 26 May 2016 22:01:45 +0000 (22:01 +0000)]
Remove all mentions of hashmap
am: 01a3a24f1e

* commit '01a3a24f1e166e4b7328c7bfee3360601d1e1c26':
  Remove all mentions of hashmap

Change-Id: I3245496328ced23907bdda7b76917fb77768efef

8 years agoReplace hash_map in data_dispatcher with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 22:01:44 +0000 (22:01 +0000)]
Replace hash_map in data_dispatcher with C++ unordered_map
am: 2b56e01a2d

* commit '2b56e01a2d0ccf9eff58b24fb66c18280f95a680':
  Replace hash_map in data_dispatcher with C++ unordered_map

Change-Id: Ifb681cc337b80b805d3c73878184e4eb5b0224f1

8 years agoReplace hash_map in audio_a2dp_hw with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 22:01:42 +0000 (22:01 +0000)]
Replace hash_map in audio_a2dp_hw with C++ unordered_map
am: 6a059517c7

* commit '6a059517c75400615dd26268d9bf81024091a85d':
  Replace hash_map in audio_a2dp_hw with C++ unordered_map

Change-Id: I40b3928ad16f4107c05ada971561dfcc594afaf4

8 years agoReplace hash_map in btm_ble_bgconn with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 22:01:41 +0000 (22:01 +0000)]
Replace hash_map in btm_ble_bgconn with C++ unordered_map
am: 488005b16b

* commit '488005b16bd2552ce7e5f9c1e1b3d4072397fc26':
  Replace hash_map in btm_ble_bgconn with C++ unordered_map

Change-Id: I1fc198dc6bcfe238d61b0eb30376459110b74b79

8 years agoReplace hash_map in peer with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 22:01:12 +0000 (22:01 +0000)]
Replace hash_map in peer with C++ unordered_map
am: 0cafedaffc

* commit '0cafedaffc0a189877b64d065571bec4ac6d804a':
  Replace hash_map in peer with C++ unordered_map

Change-Id: Id2145094e305843420775202e3d9bb6ecf448dd1

8 years agoReplace hash_map in module_manager with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 22:01:10 +0000 (22:01 +0000)]
Replace hash_map in module_manager with C++ unordered_map
am: 5c2c303953

* commit '5c2c3039539023d7946021d49a985f6655a1aeda':
  Replace hash_map in module_manager with C++ unordered_map

Change-Id: I9d2b7503af5991daaa0af2bbc362cc2f82bb088b

8 years agoReplace hash_map in packet_fragmenter with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 22:01:09 +0000 (22:01 +0000)]
Replace hash_map in packet_fragmenter with C++ unordered_map
am: dd5e3e9e3f

* commit 'dd5e3e9e3ffd2fe2b7d520c09acd98f79c3d9a38':
  Replace hash_map in packet_fragmenter with C++ unordered_map

Change-Id: I7173996eb57753ceed8b0f334d2a1c8c9620f41c

8 years agoRemove unnecesarry hash_map includes
Jakub Pawlowski [Thu, 26 May 2016 22:01:07 +0000 (22:01 +0000)]
Remove unnecesarry hash_map includes
am: 9b99e998a1

* commit '9b99e998a112a447144fec13387003598220602b':
  Remove unnecesarry hash_map includes

Change-Id: I561827d7942e0b7848edf60a1add0cc45e7a2b1c

8 years agoFix allocation_tracker crashes
Jakub Pawlowski [Thu, 26 May 2016 22:01:06 +0000 (22:01 +0000)]
Fix allocation_tracker crashes
am: 0d55d66da2

* commit '0d55d66da26c079669975becfc29675f6492a155':
  Fix allocation_tracker crashes

Change-Id: Ia6e0256f83f82ed49620030ef8955ccb3fd3bde8

8 years agoConvert GATT related BTA code to C++
Jakub Pawlowski [Thu, 26 May 2016 18:08:21 +0000 (11:08 -0700)]
Convert GATT related BTA code to C++

Change-Id: I9c36d0ebeb1143395b3b38b3d179d12a9503d28a

8 years agoRemove all mentions of hashmap
Jakub Pawlowski [Thu, 26 May 2016 17:20:59 +0000 (10:20 -0700)]
Remove all mentions of hashmap

Change-Id: I4594c401d91c6d5e2626ca92593f0f29833844ab

8 years agoReplace hash_map in data_dispatcher with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 17:13:40 +0000 (10:13 -0700)]
Replace hash_map in data_dispatcher with C++ unordered_map

Change-Id: Ic8d99108fd557a1d994dcea5a2bf92aef98a0cac

8 years agoReplace hash_map in audio_a2dp_hw with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 00:49:32 +0000 (17:49 -0700)]
Replace hash_map in audio_a2dp_hw with C++ unordered_map

Change-Id: I64c7f72c91558bbbd2e31967d10733e0b98faa7e

8 years agoReplace hash_map in btm_ble_bgconn with C++ unordered_map
Jakub Pawlowski [Thu, 26 May 2016 00:10:56 +0000 (17:10 -0700)]
Replace hash_map in btm_ble_bgconn with C++ unordered_map

Change-Id: I19b99b88d6dbcf6d6425d102bf908038c09325cb

8 years agoReplace hash_map in peer with C++ unordered_map
Jakub Pawlowski [Wed, 25 May 2016 23:15:22 +0000 (16:15 -0700)]
Replace hash_map in peer with C++ unordered_map

Change-Id: Iae48d18cc370221c425b337fefb3a8255cda759a

8 years agoReplace hash_map in module_manager with C++ unordered_map
Jakub Pawlowski [Wed, 25 May 2016 22:53:45 +0000 (15:53 -0700)]
Replace hash_map in module_manager with C++ unordered_map

Change-Id: I9ee3c9349a5ea80f17f65a137d7fe7be5dc63e70

8 years agoReplace hash_map in packet_fragmenter with C++ unordered_map
Jakub Pawlowski [Wed, 25 May 2016 22:33:41 +0000 (15:33 -0700)]
Replace hash_map in packet_fragmenter with C++ unordered_map

Change-Id: I7707d21c44a5b8a18c925892d950155e3be72c30

8 years agoRemove unnecesarry hash_map includes
Jakub Pawlowski [Wed, 25 May 2016 21:46:19 +0000 (14:46 -0700)]
Remove unnecesarry hash_map includes

Change-Id: I929b2ec88e33643f128a3a72130bdb091e0b2143

8 years agoFix allocation_tracker crashes
Jakub Pawlowski [Wed, 25 May 2016 17:37:17 +0000 (10:37 -0700)]
Fix allocation_tracker crashes

Use C++ unordered_map in allocation_tracker.

Bug: 28888632
Change-Id: I15204b0bede5686af25fc6cdd05ce3097b436dd6

8 years agotest_vendor_lib: Add initial support for BLE
Myles Watson [Tue, 24 May 2016 16:52:51 +0000 (09:52 -0700)]
test_vendor_lib: Add initial support for BLE

Change-Id: If0d8e07ee0c76ed5f22c5f111b7e7be7f28c7bc3

8 years agoRemove the RFComm MCB from the ports when releasing it
Pavlin Radoslavov [Thu, 26 May 2016 02:30:32 +0000 (02:30 +0000)]
Remove the RFComm MCB from the ports when releasing it
am: 1f9eb3d62c

* commit '1f9eb3d62c78bae8b429a48f71629d6e53f9fc87':
  Remove the RFComm MCB from the ports when releasing it

Change-Id: Ibffff4e80a8eb190e43426273927f1391f5a2c9a

8 years agoRemove the RFComm MCB from the ports when releasing it
Pavlin Radoslavov [Thu, 26 May 2016 01:08:29 +0000 (18:08 -0700)]
Remove the RFComm MCB from the ports when releasing it

Bug: 28849621
Change-Id: I3ce1c857d0d0a2c00c59d8f71b40685ae602dc29

8 years agoMerge "Remove unused profile manager"
Jakub Pawlowski [Thu, 26 May 2016 01:14:26 +0000 (01:14 +0000)]
Merge "Remove unused profile manager"
am: 48f8113216

* commit '48f8113216935eed9374d50ab3ccc6704065e409':
  Remove unused profile manager

Change-Id: I1a7ac124f5204aa78d4e885707d4bbe62ad8d0cd

8 years agoMerge "Remove unused profile manager"
Jakub Pawlowski [Thu, 26 May 2016 01:03:33 +0000 (01:03 +0000)]
Merge "Remove unused profile manager"

8 years agoRemove unused profile manager
Jakub Pawlowski [Wed, 25 May 2016 23:30:29 +0000 (16:30 -0700)]
Remove unused profile manager

Change-Id: Ib718117b523030a4cf5a33672d5523c19fe79431

8 years agotest_vendor_lib: run clang-format with brillo opts
Myles Watson [Thu, 26 May 2016 00:04:09 +0000 (00:04 +0000)]
test_vendor_lib: run clang-format with brillo opts
am: e49120d722

* commit 'e49120d722142f593687856a71cbffadc3caa530':
  test_vendor_lib: run clang-format with brillo opts

Change-Id: I01dc545ca725404b5660ddf74b22d42ee9f7f87d

8 years agotest_vendor_lib: run clang-format with brillo opts
Myles Watson [Wed, 25 May 2016 21:44:57 +0000 (14:44 -0700)]
test_vendor_lib: run clang-format with brillo opts

Change-Id: Ie2ead0a020e2358696a2f0e26f3c76a9dd29e266
Signed-off-by: Myles Watson <mylesgw@google.com>
8 years agoImprove config file sync during configuration save.
Jacky Cheung [Tue, 24 May 2016 19:51:50 +0000 (19:51 +0000)]
Improve config file sync during configuration save.
am: 95dbe03a69

* commit '95dbe03a693f4a920204b8c6acbba5269915a59f':
  Improve config file sync during configuration save.

Change-Id: Ib337392e2bb6d0ee28c2400c92d62590faebeceb

8 years agoImprove config file sync during configuration save.
Jacky Cheung [Wed, 18 May 2016 22:41:09 +0000 (15:41 -0700)]
Improve config file sync during configuration save.

Add fsync() calls to force sync to disk while saving configuration
file.  It is necessary to do a sync on the temp file before rename,
and to sync again on its parent directory to ensure both the
file content and the directory are up-to-date.

Change-Id: I3a862ad59c8ae5beb8ea2c727eb5f275a2d5823e

8 years agoDon\'t disconnect on failure to register for service changed notification
Jakub Pawlowski [Tue, 24 May 2016 16:11:34 +0000 (16:11 +0000)]
Don\'t disconnect on failure to register for service changed notification
am: 634c2e6f23

* commit '634c2e6f23ccb25696d814161e8a2db686b16728':
  Don't disconnect on failure to register for service changed notification

Change-Id: Iff7c70233be57c67565b2c6d5ef16b238c6b3ac0

8 years agoDon't disconnect on failure to register for service changed notification
Jakub Pawlowski [Mon, 23 May 2016 21:47:48 +0000 (14:47 -0700)]
Don't disconnect on failure to register for service changed notification

Bug: 28721625
Change-Id: I2214fb2576f0f0794922ed9b47d8805839d69bfd

8 years agoFix the timestamp in btsnoop format
Ben YoungTae Kim [Tue, 24 May 2016 02:55:09 +0000 (02:55 +0000)]
Fix the timestamp in btsnoop format
am: 7dc4051b58

* commit '7dc4051b584bb056940afebda9d8ad3a48c046c3':
  Fix the timestamp in btsnoop format

Change-Id: I138f704e1e6bc0df3eeb89a22f21d4623c848b4a

8 years agoFix the timestamp in btsnoop format
Ben YoungTae Kim [Mon, 23 May 2016 23:15:07 +0000 (16:15 -0700)]
Fix the timestamp in btsnoop format

Due to overflow, timestamp does not have correct value.
Make sure it should be saved in long long type as 64bit.

Change-Id: Iaf1b1dd746dd52ab7e50b870efacde2b8dd0bed6
Signed-off-by: Ben YoungTae Kim <ytkim@qca.qualcomm.com>
8 years agoAdd L2CAP signaling headers and more ACL data to btsnooz
Andre Eisenbach [Mon, 23 May 2016 21:42:28 +0000 (21:42 +0000)]
Add L2CAP signaling headers and more ACL data to btsnooz
am: d4e1a93a6f

* commit 'd4e1a93a6f5ba7bdba7948363ce08e3af70e47d2':
  Add L2CAP signaling headers and more ACL data to btsnooz

Change-Id: I8a4f7cb866457a900f31a3777c017f69fdf2ee7a

8 years agoAdd L2CAP signaling headers and more ACL data to btsnooz
Andre Eisenbach [Tue, 17 May 2016 04:49:23 +0000 (21:49 -0700)]
Add L2CAP signaling headers and more ACL data to btsnooz

Increase the BTSNOOZ log buffer to 256kb and adds complete L2CAP
signaling headers as well as more data per ACL data packet. This will
allow additional RFCOMM debugging.

Fixes: 28845518
Change-Id: I19e1a4a40bb1c8d332a25283fb50635d791bc275

8 years agoAdd a missing OSI_NO_INTR() wrapper around socket read()
Pavlin Radoslavov [Thu, 19 May 2016 21:02:02 +0000 (21:02 +0000)]
Add a missing OSI_NO_INTR() wrapper around socket read()
am: a5c0f15960

* commit 'a5c0f1596095ec9017bb50c035f327f708a5d8e8':
  Add a missing OSI_NO_INTR() wrapper around socket read()

Change-Id: Id4a498a729436aa5432bd485ca9ff193edb08f54

8 years agoImprove poll(2) handling and log messages
Pavlin Radoslavov [Thu, 19 May 2016 21:02:01 +0000 (21:02 +0000)]
Improve poll(2) handling and log messages
am: 9f20f3cff9

* commit '9f20f3cff9ead8efbbcab19b2841362a0e3789ab':
  Improve poll(2) handling and log messages

Change-Id: Id7dc7f25c214fbcd61bac1d3647a85d5ae941b83

8 years agoAdd error log messages for A2DP commands
Pavlin Radoslavov [Thu, 19 May 2016 21:01:59 +0000 (21:01 +0000)]
Add error log messages for A2DP commands
am: a7373c8f03

* commit 'a7373c8f031a68a52ce1f876457d1c5c74aaa87f':
  Add error log messages for A2DP commands

Change-Id: Ia545e12e6ab63977916725ea7b5514c26c23254e

8 years agoAdd a missing OSI_NO_INTR() wrapper around socket read()
Pavlin Radoslavov [Wed, 18 May 2016 22:22:55 +0000 (15:22 -0700)]
Add a missing OSI_NO_INTR() wrapper around socket read()

Also, print a better error message.

Change-Id: I22da05fd5e9b10a5122705105ea7a45855eb144d

8 years agoImprove poll(2) handling and log messages
Pavlin Radoslavov [Wed, 18 May 2016 21:34:31 +0000 (14:34 -0700)]
Improve poll(2) handling and log messages

 * Better error handling and log messages inside
   uipc_flush_ch_locked()
 * Add missing error check inside UIPC_Read()
 * Add missing OSI_NO_INTR() wrapper around poll()
   inside function btu_exec_tap_fd_read()

Bug: 28823662
Change-Id: I5f1c720861bea594d53ed6465a5ff327ba352598

8 years agoAdd error log messages for A2DP commands
Pavlin Radoslavov [Wed, 18 May 2016 21:30:53 +0000 (14:30 -0700)]
Add error log messages for A2DP commands

Bug: 28823662
Change-Id: Ifa9950dd2277b444bedd5108beff2db029a5ed93

8 years agoAdd a log message to capture NULL pointer in l2c_link_hci_disc_comp()
Pavlin Radoslavov [Wed, 18 May 2016 00:27:10 +0000 (00:27 +0000)]
Add a log message to capture NULL pointer in l2c_link_hci_disc_comp()
am: e34b0eb111

* commit 'e34b0eb1110d47832a38180c1b1f8c08205aa0e2':
  Add a log message to capture NULL pointer in l2c_link_hci_disc_comp()

Change-Id: I82b2aa69655d0b2bef076f270d284cc2dfe35dbd

8 years agoAdd a log message to capture NULL pointer in l2c_link_hci_disc_comp()
Pavlin Radoslavov [Tue, 17 May 2016 00:14:03 +0000 (17:14 -0700)]
Add a log message to capture NULL pointer in l2c_link_hci_disc_comp()

Added a log message inside l2c_link_hci_disc_comp() to help capture
a NULL pointer p_lcb->p_fixed_ccbs[xx] that triggers SIGSEGV crash.
Also, updated the typedef of bdstr_t and moved it to
file "btcore/include/bdaddr.h"

Bug: 28765514
Change-Id: Iacd9376cfb9e18b58e18865581da8edad9f68821

8 years agoMerge "HID: Prevent incoming and outgoing SDP collision"
Hemant Gupta [Tue, 17 May 2016 19:28:28 +0000 (19:28 +0000)]
Merge "HID: Prevent incoming and outgoing SDP collision"
am: d1e432ee05

* commit 'd1e432ee05d847f85380521a9d0a225c57fbc8f9':
  HID: Prevent incoming and outgoing SDP collision

Change-Id: Icb1c82876f4bf5f408b74e97ca5daf65c9e8651d

8 years agoMerge "HID: Prevent incoming and outgoing SDP collision"
Treehugger Robot [Tue, 17 May 2016 19:21:54 +0000 (19:21 +0000)]
Merge "HID: Prevent incoming and outgoing SDP collision"

8 years agoMerge "Fix pairing state change in collision scenario"
venkata Jagadeesh [Tue, 17 May 2016 18:49:14 +0000 (18:49 +0000)]
Merge "Fix pairing state change in collision scenario"
am: 8fdbd954e0

* commit '8fdbd954e07f9ee9cf3b7cb3d9f8c9fee4adf1ca':
  Fix pairing state change in collision scenario

Change-Id: I5363494e95e9e37d4ee8caefa4ec11e103334e4c

8 years agoMerge "Fix pairing state change in collision scenario"
Treehugger Robot [Tue, 17 May 2016 18:38:56 +0000 (18:38 +0000)]
Merge "Fix pairing state change in collision scenario"

8 years agoHID: Prevent incoming and outgoing SDP collision
Hemant Gupta [Wed, 7 Oct 2015 06:38:10 +0000 (12:08 +0530)]
HID: Prevent incoming and outgoing SDP collision

SDP is performed 2 times as part of HID connection in BD stack,
one after successful authentication, and one in HID stack layer
as SDP data is not stored currently in stack. When there is outgoing and
incoming connections, SDP failed message was posted which was resulting
in SDP failure for HID host resulting in improper disconnection of
HID interrupt channel.

Change-Id: I5b4813dc916696e2c0f76be27a85c1a89c2d8be0

8 years agoMerge "Check CCB state before executing channel state machine events"
Gurpreet Ghai [Tue, 17 May 2016 18:11:07 +0000 (18:11 +0000)]
Merge "Check CCB state before executing channel state machine events"
am: 671e726537

* commit '671e726537ed02791d4ae242e879c405a8ced165':
  Check CCB state before executing channel state machine events

Change-Id: Ie0a16cff81205346f08101b79866a71ac0e1fac2

8 years agoMerge "Check CCB state before executing channel state machine events"
Treehugger Robot [Tue, 17 May 2016 18:09:14 +0000 (18:09 +0000)]
Merge "Check CCB state before executing channel state machine events"

8 years agoFix pairing state change in collision scenario
venkata Jagadeesh [Thu, 1 Oct 2015 06:25:03 +0000 (11:55 +0530)]
Fix pairing state change in collision scenario

Symptom:
DUT Stuck in pairing state forever with selfy stick
during repair.

Steps:
1. Pair and connect remote devices with DUT.
2. Now un pair selfy stick from DUT.
3. Keep remote in discoverable mode.
4. Start inquiry and try to pair with device.

Failure:
Pairing with selfy stick always fails after collision.

Root Cause:
As we return from btm_sec_dd_create_conn with out
moving pairing state in connection collision scenario. Pairing
state will remains idle and pairing won't proceed further.

Fix:
Move the pairing state in collision scenario so that pairing
can proceed further.

Change-Id: Ic5c446ad3902b0ce16c7223ec2d8e4a625831446

8 years agoIncreasing LE Properties to broadcast.
Balraj Selvaraj [Tue, 17 May 2016 17:40:46 +0000 (17:40 +0000)]
Increasing LE Properties to broadcast.
am: 234af83f69

* commit '234af83f69d70dc89a2c7ae6557b8c63f737437b':
  Increasing LE Properties to broadcast.

Change-Id: Iecc129b8dd7863fb6e27c7194b87a371ec3547a2

8 years agoIncreasing LE Properties to broadcast.
Balraj Selvaraj [Wed, 6 Jan 2016 05:48:32 +0000 (11:18 +0530)]
Increasing LE Properties to broadcast.

Use case: Remote BD_NAME is not broadcasted when BLE device
pairing is done by using NFC where we broadcasted only UUID.

steps:
Connect with BLE device by using NFC and check the remote name.

Failure: Remote device name is not available.

Root cause: BD_NAME is not broadcasted when BLE device pairing
is done.

Fix: Added property to broadcast remote BD_NAME also as part
BLE device pairing using NFC.

Change-Id: Ie6cda489aabff15a0ebbc692a16f9428729a7dba