OSDN Git Service

android-x86/system-bt.git
6 years agoMerge "Fix callback type mismatches in Bluetooth" am: f527f08e4f
Vishwath Mohan [Wed, 13 Dec 2017 21:08:28 +0000 (21:08 +0000)]
Merge "Fix callback type mismatches in Bluetooth" am: f527f08e4f
am: 531cb7585c

Change-Id: Ib8f36cdb248fe94d1467be0207419d4084170e57

6 years agoAdded check to know the status of any ongoing pairing status. am: 6cc4234169
Matadeen Mishra [Wed, 13 Dec 2017 21:08:01 +0000 (21:08 +0000)]
Added check to know the status of any ongoing pairing status. am: 6cc4234169
am: 56f9b89cbd

Change-Id: I74683ee03a9c2fc129e9db25100961bfe960b279

6 years agoMerge "Fix callback type mismatches in Bluetooth"
Vishwath Mohan [Wed, 13 Dec 2017 21:05:02 +0000 (21:05 +0000)]
Merge "Fix callback type mismatches in Bluetooth"
am: f527f08e4f

Change-Id: I8963109fe921b84fcfa31f096a26ffd420af182a

6 years agoAdded check to know the status of any ongoing pairing status.
Matadeen Mishra [Wed, 13 Dec 2017 21:04:37 +0000 (21:04 +0000)]
Added check to know the status of any ongoing pairing status.
am: 6cc4234169

Change-Id: If0868cfe6d496027199f040ba72175a603353776

6 years agoMerge "Fix callback type mismatches in Bluetooth"
Vishwath Mohan [Wed, 13 Dec 2017 21:00:31 +0000 (21:00 +0000)]
Merge "Fix callback type mismatches in Bluetooth"

6 years agoAdded check to know the status of any ongoing pairing status.
Matadeen Mishra [Tue, 21 Jun 2016 12:27:31 +0000 (17:57 +0530)]
Added check to know the status of any ongoing pairing status.

Use Case: Host allows incoming pairing even though outgoing pairing
is in process.

Steps:
1. Initiate bonding from Mecapp and provide pin key at Mecapp pairing
pop-up.
2. Start pairing for Logitech mouse from DUT and click on accept
pairing at mecapp pairing pop-up.
3. Give the same pin key for mecapp pairing pop-up at DUT side and
observe the behavior.

Failure: Incoming request is getting from remote and got a pop-up
for PIN request.

Root Cause: Pairing was auto accepted for remote device while
pairing was in progress with another remote device leading to
inconsistent behavior.

Fix: Rejects incoming pairing request from remote device
if already in pairing state.

Test: Tested with HID Logitech Mouse

Fixes: 35417665

Change-Id: I19a2a98e4ceb51cabaef279a2e3f8224fbed9ea1

6 years agoFix callback type mismatches in Bluetooth
Vishwath Mohan [Mon, 4 Dec 2017 21:28:06 +0000 (13:28 -0800)]
Fix callback type mismatches in Bluetooth

This CL fixes some mismatches between defined callback signatures and
the signatures of the functions that are actually passed in as that
type.

Bug: 67507323
Test: lunch walleye_cfi && m -j50

Change-Id: Ia5c22ac614c34cc8bd8a370861d988bb9f8034a6

6 years agoMerge "BLE: Don't set SC bit in AuthReq for Legacy Devices" am: 9d4686bd2f
Hemant Gupta [Wed, 13 Dec 2017 02:55:15 +0000 (02:55 +0000)]
Merge "BLE: Don't set SC bit in AuthReq for Legacy Devices" am: 9d4686bd2f
am: ccdba8bdb5

Change-Id: I84b8fb11dbd5f82bc11405f0d4d5a9d78b7ab0da

6 years agoMerge "Check MT call setup state before starting ring timer" am: 964542b8e6
Satish Kodishala [Wed, 13 Dec 2017 02:54:46 +0000 (02:54 +0000)]
Merge "Check MT call setup state before starting ring timer" am: 964542b8e6
am: 2fa8382fac

Change-Id: I22bc5f0fa848f125cc34fe353aa8e24d65f20108

6 years agoMerge "BLE: Don't set SC bit in AuthReq for Legacy Devices"
Hemant Gupta [Wed, 13 Dec 2017 01:58:11 +0000 (01:58 +0000)]
Merge "BLE: Don't set SC bit in AuthReq for Legacy Devices"
am: 9d4686bd2f

Change-Id: I8613157bff638cef511af4b29cf0adc5902a7911

6 years agoMerge "Check MT call setup state before starting ring timer"
Satish Kodishala [Wed, 13 Dec 2017 01:57:44 +0000 (01:57 +0000)]
Merge "Check MT call setup state before starting ring timer"
am: 964542b8e6

Change-Id: I9e2be9fba8c802e933ea853dc0130d8271ba252f

6 years agoMerge "BLE: Don't set SC bit in AuthReq for Legacy Devices"
Treehugger Robot [Wed, 13 Dec 2017 01:21:23 +0000 (01:21 +0000)]
Merge "BLE: Don't set SC bit in AuthReq for Legacy Devices"

6 years agoMerge "Check MT call setup state before starting ring timer"
Treehugger Robot [Wed, 13 Dec 2017 00:31:35 +0000 (00:31 +0000)]
Merge "Check MT call setup state before starting ring timer"

6 years agoBLE: Don't set SC bit in AuthReq for Legacy Devices
Hemant Gupta [Wed, 6 Dec 2017 10:05:20 +0000 (15:35 +0530)]
BLE: Don't set SC bit in AuthReq for Legacy Devices

Disable SC bit for legacy LE devices (< 4.2) since as per earlier
spec, this BIT should be 0 and ignored by remote device. Some remote
legacy devices which don't follow the approach of ignoring these bits
(if set) go in bad state and result in SMP pairing failure.

Test: Pairing succeeds with remote device after resettings SC bit.

Fixes: 70259025
Change-Id: I35838c60fb08916a141f764b3e1922d277b99f28

6 years agoAVRCP: Flush the command queue in AVRC_Close am: a701c777af
Myles Watson [Tue, 12 Dec 2017 19:50:24 +0000 (19:50 +0000)]
AVRCP: Flush the command queue in AVRC_Close am: a701c777af
am: 1355755aa0

Change-Id: Ic7432a2c90a66d6498bac4994a75b1628c3c27ac

6 years agoAVRCP: Flush the command queue in AVRC_Close
Myles Watson [Tue, 12 Dec 2017 19:46:49 +0000 (19:46 +0000)]
AVRCP: Flush the command queue in AVRC_Close
am: a701c777af

Change-Id: I1fdbe972e912ca1a06e6b83e336080733a0b5cf1

6 years agoAVRCP: Flush the command queue in AVRC_Close
Myles Watson [Tue, 12 Dec 2017 00:23:21 +0000 (16:23 -0800)]
AVRCP: Flush the command queue in AVRC_Close

Test: toggle BR/EDR, manually inspect open files using lsof
Change-Id: I7bdc3a3840e7cc31894a9050dd5b7c29f863bb30

6 years agoMerge "Make BluetoothPbap implement BluetoothProfile (3/3)" am: eb9d2cff70
Hansong Zhang [Tue, 12 Dec 2017 19:22:24 +0000 (19:22 +0000)]
Merge "Make BluetoothPbap implement BluetoothProfile (3/3)" am: eb9d2cff70
am: f6eef672cd

Change-Id: I4dbc0ed7c1a6fc97eedafa5a637c53dac8f6d878

6 years agoMerge "Make BluetoothPbap implement BluetoothProfile (3/3)"
Hansong Zhang [Tue, 12 Dec 2017 19:12:15 +0000 (19:12 +0000)]
Merge "Make BluetoothPbap implement BluetoothProfile (3/3)"
am: eb9d2cff70

Change-Id: I3e129b74d7cb224754d35e0be01c1f73be361ea4

6 years agoMerge "Make BluetoothPbap implement BluetoothProfile (3/3)"
Treehugger Robot [Tue, 12 Dec 2017 19:02:26 +0000 (19:02 +0000)]
Merge "Make BluetoothPbap implement BluetoothProfile (3/3)"

6 years agobinder: Call writeParcelFileDescriptor() am: be797989f1
Myles Watson [Sat, 9 Dec 2017 03:07:11 +0000 (03:07 +0000)]
binder: Call writeParcelFileDescriptor() am: be797989f1
am: f75c993b8e

Change-Id: Ic000e817698ceb2caaaad78f3c746977c9a244b2

6 years agobinder: Call writeParcelFileDescriptor()
Myles Watson [Sat, 9 Dec 2017 03:02:04 +0000 (03:02 +0000)]
binder: Call writeParcelFileDescriptor()
am: be797989f1

Change-Id: I642871e90d7c3350a21f2b2641b6a1575c68a326

6 years agobinder: Call writeParcelFileDescriptor()
Myles Watson [Fri, 8 Dec 2017 23:50:49 +0000 (15:50 -0800)]
binder: Call writeParcelFileDescriptor()

Fixes: 69678755
Test: manual inspection using lsof
Change-Id: Ifcb5af2d5797e667c20d4c41ad836cf7626e9909

6 years agoMake BluetoothPbap implement BluetoothProfile (3/3)
Hansong Zhang [Sat, 9 Dec 2017 00:08:34 +0000 (16:08 -0800)]
Make BluetoothPbap implement BluetoothProfile (3/3)

Change AIDL method signatures:
* Removed connect()
* Add BluetoothDevice parameter for disconnect()
* Rename other method names to be consistent with BluetoothProfile
methods

Test: test with PBAP carkits
Bug: 69417672
Change-Id: Ide81254d71128b9d204b63aa60bc39752add6edd

6 years agoMerge "HFP: Remove dead code in native interface" am: 2fbb2e982e
Jack He [Fri, 8 Dec 2017 01:48:37 +0000 (01:48 +0000)]
Merge "HFP: Remove dead code in native interface" am: 2fbb2e982e
am: 02e8c84a46

Change-Id: Iae1ea2008cb74d9a51ea872f87ffcc495e3baf6d

6 years agoMerge "HFP: Remove dead code in native interface"
Jack He [Fri, 8 Dec 2017 01:37:44 +0000 (01:37 +0000)]
Merge "HFP: Remove dead code in native interface"
am: 2fbb2e982e

Change-Id: Id8a4f4b3446b77f4ea57b3af8e900c48065c3f45

6 years agoMerge "HFP: Remove dead code in native interface"
Treehugger Robot [Fri, 8 Dec 2017 01:14:59 +0000 (01:14 +0000)]
Merge "HFP: Remove dead code in native interface"

6 years agoMerge "Make LE CoC Maximum PDU Size configurable" am: bde88fa29c
Jakub Pawlowski [Thu, 7 Dec 2017 22:34:34 +0000 (22:34 +0000)]
Merge "Make LE CoC Maximum PDU Size configurable" am: bde88fa29c
am: 4748b50e43

Change-Id: I89d86e5b1c2b2a4a8670050ce16d7c9649896cb2

6 years agoMerge "Make LE CoC Maximum PDU Size configurable"
Jakub Pawlowski [Thu, 7 Dec 2017 22:32:01 +0000 (22:32 +0000)]
Merge "Make LE CoC Maximum PDU Size configurable"
am: bde88fa29c

Change-Id: I5a898bd5f71dcaf00674125ee25d6e80247660d1

6 years agoMerge "Make LE CoC Maximum PDU Size configurable"
Treehugger Robot [Thu, 7 Dec 2017 22:20:51 +0000 (22:20 +0000)]
Merge "Make LE CoC Maximum PDU Size configurable"

6 years agoMake LE CoC Maximum PDU Size configurable
Jakub Pawlowski [Tue, 5 Dec 2017 07:17:49 +0000 (23:17 -0800)]
Make LE CoC Maximum PDU Size configurable

Hearing Aid will need to modify this value. For existing code keep the
value as is.

Test: none
Bug: 69623109
Change-Id: I8c97882b5dd08a049d3a958c51163bad41df4d6a

6 years agoMerge "BTIF: Fix return types of interface getters" am: 946ddd2770
Jack He [Thu, 7 Dec 2017 20:37:01 +0000 (20:37 +0000)]
Merge "BTIF: Fix return types of interface getters" am: 946ddd2770
am: 6f3e31b153

Change-Id: I85486eaeacb5fe51e0ad8b847e89b59a41e5ebd9

6 years agoMerge "BTIF: Fix return types of interface getters"
Jack He [Thu, 7 Dec 2017 20:34:30 +0000 (20:34 +0000)]
Merge "BTIF: Fix return types of interface getters"
am: 946ddd2770

Change-Id: I9121c1a99c593b2b27e15695121ed667f64008b8

6 years agoMerge "BTIF: Fix return types of interface getters"
Treehugger Robot [Thu, 7 Dec 2017 20:21:54 +0000 (20:21 +0000)]
Merge "BTIF: Fix return types of interface getters"

6 years agoGATT cache memory corruption fix am: 6918d40fd9
Jakub Pawlowski [Thu, 7 Dec 2017 20:18:02 +0000 (20:18 +0000)]
GATT cache memory corruption fix am: 6918d40fd9
am: 52cec2dc82

Change-Id: I0ac29e9ccb727a9f436df8d523d4c41f03d2297d

6 years agoGATT cache memory corruption fix
Jakub Pawlowski [Thu, 7 Dec 2017 20:13:22 +0000 (20:13 +0000)]
GATT cache memory corruption fix
am: 6918d40fd9

Change-Id: I7b5d4804d17675198c5995fa18faff74f0a2efae

6 years agoHFP: Remove dead code in native interface
Jack He [Thu, 7 Dec 2017 19:19:06 +0000 (11:19 -0800)]
HFP: Remove dead code in native interface

The following hidden API methods are not implemented by the stack and
should be removed:
  - getBatteryUsageHint()
  - acceptIncomingConnect()
  - rejectIncomingConnect()

The following hidden API methods are no longer needed due to lack of
usage and should be removed:
  - enableWBS()
  - disableWBS()
  - bindResponse()

Bug: 70336991
Test: make
Change-Id: Ifa0d3cbdf4487465782144b84a2bed5e4f7acc4e

6 years agoGATT cache memory corruption fix
Jakub Pawlowski [Tue, 5 Dec 2017 12:05:46 +0000 (04:05 -0800)]
GATT cache memory corruption fix

When doing GATT discovery, we interleave adding elements to vector,
and storing pointers to them. This can cause memory corruption, because
vector can reallocate the memory when adding element, leaving the pointers
invalid. To fix that, never store pointers to mutable vector elements.

Bug: 70041392
Test: manual, connected to HID device
Change-Id: I6bb3fec61afa742f446b66e3291c5f326738ee17

6 years agoBTA GATT operation queue am: 80c1e1c494
Jakub Pawlowski [Thu, 7 Dec 2017 18:40:54 +0000 (18:40 +0000)]
BTA GATT operation queue am: 80c1e1c494
am: 5735d8495b

Change-Id: I3323250be3ad5b7a2eaa23843b0390614a7fe354

6 years agoBTA GATT operation queue
Jakub Pawlowski [Thu, 7 Dec 2017 18:22:40 +0000 (18:22 +0000)]
BTA GATT operation queue
am: 80c1e1c494

Change-Id: I771d06a5fb93f7a02a1cad8e70a158c2a523a5d0

6 years agoBTA GATT operation queue
Jakub Pawlowski [Thu, 30 Nov 2017 05:49:32 +0000 (21:49 -0800)]
BTA GATT operation queue

Currently, HID BTA app have own GATT queue for scheduling reads/writes
during device setup. Such queue will also be needed for Hearing Aid.
This patch makes the GATT queue code generic and clean it up.

Test: manual, bond HID device
Bug: 69623109
Change-Id: Ic893d630ab5154f7c1875748f3e275cbad02a7b2

6 years agoBTIF: Fix return types of interface getters
Jack He [Mon, 4 Dec 2017 22:30:42 +0000 (14:30 -0800)]
BTIF: Fix return types of interface getters

* They should return const pointer to interface structs
* Fixed return type for btif_rc_ctrl_get_interface, it should be
  "const btrc_ctrl_interface_t*" but was "btrc_interface_t*". Later
  casting masked this error, but it may hurt us in the future if not
  fixed

Test: make
Change-Id: I41b2366cce68b1338761d84cef9ab986fd3334df

6 years agoMerge "Log BT Trace levels per profile" am: 792a202b39
Eagle Kang [Wed, 6 Dec 2017 21:07:38 +0000 (21:07 +0000)]
Merge "Log BT Trace levels per profile" am: 792a202b39
am: 44642fddb9

Change-Id: If27b5a946cf2fbd63f1debcd6e3b27f53ae7ad0d

6 years agoMerge "Log BT Trace levels per profile"
Eagle Kang [Wed, 6 Dec 2017 21:04:38 +0000 (21:04 +0000)]
Merge "Log BT Trace levels per profile"
am: 792a202b39

Change-Id: If37fac010c209f8bab22a6a3837db019e142b3fa

6 years agoMerge "Log BT Trace levels per profile"
Treehugger Robot [Wed, 6 Dec 2017 20:51:42 +0000 (20:51 +0000)]
Merge "Log BT Trace levels per profile"

6 years agoMerge "Remove BluetoothHidDeviceAppConfiguration (1/4)" am: ad8c5197e2
Hansong Zhang [Wed, 6 Dec 2017 20:50:40 +0000 (20:50 +0000)]
Merge "Remove BluetoothHidDeviceAppConfiguration (1/4)" am: ad8c5197e2
am: bb17accde4

Change-Id: I6701c5abd591d1a38f72ec4b0ed59d1b7e18c2cb

6 years agoMerge "Remove BluetoothHidDeviceAppConfiguration (1/4)"
Hansong Zhang [Wed, 6 Dec 2017 20:34:01 +0000 (20:34 +0000)]
Merge "Remove BluetoothHidDeviceAppConfiguration (1/4)"
am: ad8c5197e2

Change-Id: If7ac469d6047883aa00efc267f9123b41205ddda

6 years agoMerge "Remove BluetoothHidDeviceAppConfiguration (1/4)"
Treehugger Robot [Wed, 6 Dec 2017 19:34:22 +0000 (19:34 +0000)]
Merge "Remove BluetoothHidDeviceAppConfiguration (1/4)"

6 years agoRemove the remote from paired list when auth fails am: dae4076bcb
Venkata Jagadeesh Garaga [Wed, 6 Dec 2017 19:12:06 +0000 (19:12 +0000)]
Remove the remote from paired list when auth fails am: dae4076bcb
am: 01c831aed7

Change-Id: Ib7e4d4edc64e24b5c2bceb276e7c97b1ebe13937

6 years agoRemove the remote from paired list when auth fails
Venkata Jagadeesh Garaga [Wed, 6 Dec 2017 19:06:40 +0000 (19:06 +0000)]
Remove the remote from paired list when auth fails
am: dae4076bcb

Change-Id: I5c0d47a55b13e2b4bf13678edcb45e01584d8cad

6 years agoRemove the remote from paired list when auth fails
Venkata Jagadeesh Garaga [Sun, 30 Jul 2017 11:05:54 +0000 (16:35 +0530)]
Remove the remote from paired list when auth fails

Problem:
Remote stuck in connecting state during reconnection.

Steps:
1.Pair and connect the remote.
2.disconnect the remote and try to connect again from the DUT. In few trial authentication failure observed.

Root Cause:
During profile re connection scenario stack not posting
bond state change call back with bond none state if any
authentication failure. Any profile connection triggered
after this can stuck in security procedure and
never recovers.

Fix:
Hence remove the remote from paired list when auth fails

Test: manual
Bug:69028610
Change-Id: I6ac627e733f8b0b191c600153542acbb07f8c7a8

6 years agoCheck MT call setup state before starting ring timer
Satish Kodishala [Wed, 13 Jan 2016 13:53:04 +0000 (19:23 +0530)]
Check MT call setup state before starting ring timer

Test: 1. Pair and connect to Bluetooth Headset.
2. Make an incoming call and accept it from phone or BT headset.

Failure:
User may hear ring although incoming call accepted.

Root cause:
There is a ring timer to send RING every 5 secs to connected
headset until the MT call is accepted. When the call is
accepted, we stop the ring timer and send call indicators.
In case, just at the same time the ring timer stopped and
call indicators sent, if ring timer expired, it will be started
again.

Fix:
Start the ring timer only if the call is not accepted yet.

Bug: 35415875
Change-Id: Ifbde9ac45ac406f46e418a8d20abff0fefe6d414

6 years agoLog BT Trace levels per profile
Eagle Kang [Thu, 13 Apr 2017 06:50:53 +0000 (14:50 +0800)]
Log BT Trace levels per profile

BT stack trace level load from bt_stack.conf.
This change help developer to know BT stack log level
when analyze main logs.

Test: manual
Change-Id: I00037ac7d3a4bf88ea027ded77f22bef212a5874

6 years agoMerge "Add missing space in GATT_Register log" am: 563d7af58d
Jakub Pawlowski [Tue, 5 Dec 2017 18:31:49 +0000 (18:31 +0000)]
Merge "Add missing space in GATT_Register log" am: 563d7af58d
am: ccac0c2770

Change-Id: I67d254b28316110fe4b5d9c7116faeb55d667a11

6 years agoMerge "Add missing space in GATT_Register log"
Jakub Pawlowski [Tue, 5 Dec 2017 18:28:42 +0000 (18:28 +0000)]
Merge "Add missing space in GATT_Register log"
am: 563d7af58d

Change-Id: Ic74998a761cfaedf42e18fceea0006c386a93a66

6 years agoMerge "Add missing space in GATT_Register log"
Treehugger Robot [Tue, 5 Dec 2017 18:07:27 +0000 (18:07 +0000)]
Merge "Add missing space in GATT_Register log"

6 years agoFind connection ID on BR/EDR am: 72b64d5302
Chao Quan [Tue, 5 Dec 2017 14:37:27 +0000 (14:37 +0000)]
Find connection ID on BR/EDR am: 72b64d5302
am: 5f72f2a9bb

Change-Id: Ibd7ddeea4e795351baebc5405d1cdccfb15e0bac

6 years agoFind connection ID on BR/EDR
Chao Quan [Tue, 5 Dec 2017 14:34:24 +0000 (14:34 +0000)]
Find connection ID on BR/EDR
am: 72b64d5302

Change-Id: I8a51ce2405720b000ce52c01855540ae45b33e3d

6 years agoFind connection ID on BR/EDR
Chao Quan [Mon, 23 Oct 2017 11:56:16 +0000 (19:56 +0800)]
Find connection ID on BR/EDR

GATT profile may send service change indication to its
connected client and gatt_profile_find_conn_id_by_bd_addr
function helps gatt profile to find its connected client.
Gatt profile may use a BR/EDR link. So need to check it
also to avoid missing.

Test: manual
Change-Id: Ieb64cf6eab9d94352440c876be69990a7a4eb57f

6 years agoAdd missing space in GATT_Register log
Jakub Pawlowski [Tue, 5 Dec 2017 08:19:44 +0000 (00:19 -0800)]
Add missing space in GATT_Register log

Test: none
Change-Id: Idab3083daa68a958f33b264db1ff5e2f0c211ba5

6 years agoHFP: notify HF about call status forcibly am: 424f2cc7b7
Albin Joy [Tue, 5 Dec 2017 01:05:30 +0000 (01:05 +0000)]
HFP: notify HF about call status forcibly am: 424f2cc7b7
am: fd53a5ca44

Change-Id: I2586c61197fea96126f0aa4c049343ced0068cac

6 years agoHFP: notify HF about call status forcibly
Albin Joy [Tue, 5 Dec 2017 00:19:30 +0000 (00:19 +0000)]
HFP: notify HF about call status forcibly
am: 424f2cc7b7

Change-Id: Ib5495e1f600f82993382e4a0078af30fefd50fc4

6 years agoRemove BluetoothHidDeviceAppConfiguration (1/4)
Hansong Zhang [Fri, 1 Dec 2017 00:33:47 +0000 (16:33 -0800)]
Remove BluetoothHidDeviceAppConfiguration (1/4)

BluetoothHidDeviceAppConfiguration is no longer used. Remove it from
AIDL files.

Test: HID Device SL4A Test
Bug: 69981563
Merged-In: I23540fc10d114ac82cd3f484c0a472a6ba37807a
Change-Id: I23540fc10d114ac82cd3f484c0a472a6ba37807a

6 years agoHFP: notify HF about call status forcibly
Albin Joy [Wed, 14 Jun 2017 11:10:42 +0000 (19:10 +0800)]
HFP: notify HF about call status forcibly

When call is hung up and still there is another
call is in active,some of the HF cannot acquire
the call states by its own. If HF try to terminate
a call, it may not send the command AT+CHUP because
the call states are not updated properly. HF should
get informed the call status forcibly.

Bug: 63411867
Test: motorola H500
Change-Id: I4025b39ebcef0bc915a6ab146ea3a5c5a8ebb2c2

6 years agoDO NOT MERGE ANYWHERE: Disable the use of GATT cache by default. am: b050cd5d9a ...
Jacky Cheung [Fri, 1 Dec 2017 22:59:09 +0000 (22:59 +0000)]
DO NOT MERGE ANYWHERE: Disable the use of GATT cache by default. am: b050cd5d9a  -s ours am: 148f6d31a0  -s ours am: fab8ca8793  -s ours am: 3ed011da88  -s ours
am: 079008c943  -s ours

Change-Id: I71e2daa1f38f6c50a14e9ef7edde9e31f587170a

6 years agoDO NOT MERGE ANYWHERE: Disable the use of GATT cache by default. am: b050cd5d9a ...
Jacky Cheung [Fri, 1 Dec 2017 22:55:37 +0000 (22:55 +0000)]
DO NOT MERGE ANYWHERE: Disable the use of GATT cache by default. am: b050cd5d9a  -s ours am: 148f6d31a0  -s ours am: fab8ca8793  -s ours
am: 3ed011da88  -s ours

Change-Id: Ibe322547dff301c4c0e48420cbed243a0f826741

6 years agoDO NOT MERGE ANYWHERE: Disable the use of GATT cache by default. am: b050cd5d9a ...
Jacky Cheung [Fri, 1 Dec 2017 22:53:37 +0000 (22:53 +0000)]
DO NOT MERGE ANYWHERE: Disable the use of GATT cache by default. am: b050cd5d9a  -s ours am: 148f6d31a0  -s ours
am: fab8ca8793  -s ours

Change-Id: If61e7c4dd96815a9d423ea7d0f778573f13f2b78

6 years agoDO NOT MERGE ANYWHERE: Disable the use of GATT cache by default. am: b050cd5d9a ...
Jacky Cheung [Fri, 1 Dec 2017 22:51:36 +0000 (22:51 +0000)]
DO NOT MERGE ANYWHERE: Disable the use of GATT cache by default. am: b050cd5d9a  -s ours
am: 148f6d31a0  -s ours

Change-Id: I9393ade6467b657ac813666d9f0e1a1937575024

6 years agoDO NOT MERGE ANYWHERE: Disable the use of GATT cache by default.
Jacky Cheung [Fri, 1 Dec 2017 22:49:36 +0000 (22:49 +0000)]
DO NOT MERGE ANYWHERE: Disable the use of GATT cache by default.
am: b050cd5d9a  -s ours

Change-Id: Iaf10a993829cebefecbf49290dd0db345cd71dde

6 years agoReplace strncpy with strlcpy in HID and PAN code am: 4449ed4412
Hemant Gupta [Fri, 1 Dec 2017 21:09:34 +0000 (21:09 +0000)]
Replace strncpy with strlcpy in HID and PAN code am: 4449ed4412
am: 85822fe14d

Change-Id: I954194d4724ec8ea0c7ce2c998fcaba36da65cd1

6 years agoReplace strncpy with strlcpy in HID and PAN code
Hemant Gupta [Fri, 1 Dec 2017 21:05:33 +0000 (21:05 +0000)]
Replace strncpy with strlcpy in HID and PAN code
am: 4449ed4412

Change-Id: Ie9aabc36fcc86b2b886206b7f018b0d2d932974e

6 years agoReplace strncpy with strlcpy in HID and PAN code
Hemant Gupta [Mon, 12 Jun 2017 08:57:10 +0000 (14:27 +0530)]
Replace strncpy with strlcpy in HID and PAN code

Test: HID and PAN functionality work fine

Bug: 62525262
Change-Id: Icd4f9073a2356f3c8ecc4a23c22388b3509974e9

6 years agoHID: Fix issues reported by Static Analysis Tool am: e70c11fc67
Hemant Gupta [Fri, 1 Dec 2017 19:40:32 +0000 (19:40 +0000)]
HID: Fix issues reported by Static Analysis Tool am: e70c11fc67
am: cf1b169ec4

Change-Id: Ie261cd66ef6ad8000d4d231a1595fdb229071b34

6 years agoHID: Fix issues reported by Static Analysis Tool
Hemant Gupta [Fri, 1 Dec 2017 19:37:05 +0000 (19:37 +0000)]
HID: Fix issues reported by Static Analysis Tool
am: e70c11fc67

Change-Id: I69ce912dd8b3e69b7a2a97ff6917caf21ff3b586

6 years agoHID: Fix issues reported by Static Analysis Tool
Hemant Gupta [Wed, 29 Nov 2017 06:40:45 +0000 (12:10 +0530)]
HID: Fix issues reported by Static Analysis Tool

- Update error checking condition in bta_hh_le_co_cache_load API
  to return if either num of report is 0 or if length of report is
  less than size of report cache structure.

- Memset the report descriptor before use to properly initialize variables
  not updated in function.

Test: builds, hid functionality works fine

Bug: 35013844
Change-Id: Ie0347307d7536f18bf8f32a2dfeda593a41933bf

6 years agoEnable multiple connection requests for same UUID if different addresses am: f270bd3253
Pavlin Radoslavov [Fri, 1 Dec 2017 01:51:50 +0000 (01:51 +0000)]
Enable multiple connection requests for same UUID if different addresses am: f270bd3253
am: 699905b4d5

Change-Id: I6b2f52485aa3965c9e37ad60bcd7628217778fc1

6 years agoEnable multiple connection requests for same UUID if different addresses
Pavlin Radoslavov [Fri, 1 Dec 2017 01:50:18 +0000 (01:50 +0000)]
Enable multiple connection requests for same UUID if different addresses
am: f270bd3253

Change-Id: I1d3cf0abc929f707940bee5ddb661106fcf92f41

6 years agoEnable multiple connection requests for same UUID if different addresses
Pavlin Radoslavov [Tue, 21 Nov 2017 20:47:21 +0000 (12:47 -0800)]
Enable multiple connection requests for same UUID if different addresses

Allow the BTIF Profile Queue to contain entries with same UUID, but
different addresses.
Also:
 - Refactor the internal implementation of the Profile Queue to use
   C++ std::list instead of the local osi/include/list.h implementation.
 - Replaced struct connect_node_t with class ConnectNode, and moved the
   connect callback logic to ConnectNode::connect().
 - Simplified the implementation by replacing the existing callback
   mechanism based on btif_transfer_context() with do_in_jni_thread().
 - Updated the unit tests to test the new behavior.

Test: Manual and unit tests.
Bug: 69634326
Change-Id: I3c4021361902c19f004e2d8b56ad20e66a5a690a

6 years agoDO NOT MERGE ANYWHERE: Disable the use of GATT cache by default.
Jacky Cheung [Tue, 7 Nov 2017 19:17:38 +0000 (11:17 -0800)]
DO NOT MERGE ANYWHERE: Disable the use of GATT cache by default.

When a set of GATT services of a bonded device is cached locally,
an application needs to call BluetoothGatt.refresh() to clear it out
and to trigger a new service discovery.  By disabling local caching,
a service discovery is performed on every connection and that prevents
an application from getting staled GATT services.

bug: 68954828
Change-Id: I2c07404c3d56a5c8a0ffc86bc65d36480f3c46f2

6 years agoMerge "Fix assert when freeing L2CAP flow control credit packets" am: 15cbc0e953
Stanley Tng [Thu, 30 Nov 2017 17:49:22 +0000 (17:49 +0000)]
Merge "Fix assert when freeing L2CAP flow control credit packets" am: 15cbc0e953
am: 91d8f0535d

Change-Id: Iff15238c381324984af70ecd3689d3fcae2ca8eb

6 years agoMerge "Fix assert when freeing L2CAP flow control credit packets"
Stanley Tng [Thu, 30 Nov 2017 17:47:20 +0000 (17:47 +0000)]
Merge "Fix assert when freeing L2CAP flow control credit packets"
am: 15cbc0e953

Change-Id: I2845cd484f4a734732578fe69a2498e0e8ad494b

6 years agoMerge "Fix assert when freeing L2CAP flow control credit packets"
Treehugger Robot [Thu, 30 Nov 2017 17:43:08 +0000 (17:43 +0000)]
Merge "Fix assert when freeing L2CAP flow control credit packets"

6 years agoFix assert when freeing L2CAP flow control credit packets
Stanley Tng [Tue, 28 Nov 2017 22:35:08 +0000 (14:35 -0800)]
Fix assert when freeing L2CAP flow control credit packets

The data buffers for the L2CEVT_L2CA_SEND_FLOW_CONTROL_CREDIT and
L2CEVT_L2CAP_RECV_FLOW_CONTROL_CREDIT packets do not need to be
freed.

Test: Run new SL4A Test for Connection-oriented channel
Bug: 69859537
Change-Id: Ice412a1c7f0a9b413376438a9fa34cf3f91482af

6 years agoMerge "Add is_on_jni_thread" am: 01d2c72529
Jakub Pawlowski [Thu, 30 Nov 2017 08:24:03 +0000 (08:24 +0000)]
Merge "Add is_on_jni_thread" am: 01d2c72529
am: b0a4f334ac

Change-Id: Idda3ad0172a9438da2165172e4a5f33116761902

6 years agoMerge "Add is_on_jni_thread"
Jakub Pawlowski [Thu, 30 Nov 2017 08:21:22 +0000 (08:21 +0000)]
Merge "Add is_on_jni_thread"
am: 01d2c72529

Change-Id: Idc1dae5d338b08f3a4540566e12b8b4a5056af91

6 years agoMerge "Add is_on_jni_thread"
Treehugger Robot [Thu, 30 Nov 2017 08:17:26 +0000 (08:17 +0000)]
Merge "Add is_on_jni_thread"

6 years agoAdd is_on_jni_thread
Jakub Pawlowski [Thu, 30 Nov 2017 02:31:13 +0000 (18:31 -0800)]
Add is_on_jni_thread

is_on_jni_thread can be used to check if current thread is btif thread.

Test: compilation
Change-Id: I26e794c3771ae26e15e6cee6c3d4f9a1513571f4

6 years agoMerge "test_vendor: Use the license template" am: 06d65d281b
Myles Watson [Wed, 29 Nov 2017 20:14:36 +0000 (20:14 +0000)]
Merge "test_vendor: Use the license template" am: 06d65d281b
am: a0d942e6fa

Change-Id: Ie2a788185d260fbfdd9163b9ffee9030c99e9aca

6 years agoMerge "test_vendor: Use the license template"
Myles Watson [Wed, 29 Nov 2017 20:10:28 +0000 (20:10 +0000)]
Merge "test_vendor: Use the license template"
am: 06d65d281b

Change-Id: Ifa4a80ab9de9d6bba22abc299ff08b2b7e448df3

6 years agoMerge "test_vendor: Use the license template"
Treehugger Robot [Wed, 29 Nov 2017 20:06:20 +0000 (20:06 +0000)]
Merge "test_vendor: Use the license template"

6 years agoMerge "Added SPP version 1.2 to SDP record." am: 77a10d857e
Srinu Jella [Wed, 29 Nov 2017 20:02:09 +0000 (20:02 +0000)]
Merge "Added SPP version 1.2 to SDP record." am: 77a10d857e
am: 0f577092a0

Change-Id: Ia8423c5d5a88afd0d3da7dd6a359781090cd09bb

6 years agoMerge "Added SPP version 1.2 to SDP record."
Srinu Jella [Wed, 29 Nov 2017 19:58:06 +0000 (19:58 +0000)]
Merge "Added SPP version 1.2 to SDP record."
am: 77a10d857e

Change-Id: I5749099e436a0343080f30bb66d120ed7a74cc94

6 years agoMerge "Added SPP version 1.2 to SDP record."
Treehugger Robot [Wed, 29 Nov 2017 19:51:55 +0000 (19:51 +0000)]
Merge "Added SPP version 1.2 to SDP record."

6 years agoOSI: Copy temporary directoryname am: 1a651dbddd
Myles Watson [Wed, 29 Nov 2017 18:48:51 +0000 (18:48 +0000)]
OSI: Copy temporary directoryname am: 1a651dbddd
am: 43ef3f1c9b

Change-Id: Ibd2dfe12f09f3684d15185c60b5a667e3cd4ae7c

6 years agoOSI: Copy temporary directoryname
Myles Watson [Wed, 29 Nov 2017 18:43:56 +0000 (18:43 +0000)]
OSI: Copy temporary directoryname
am: 1a651dbddd

Change-Id: I6c796f8b18ba8e146d478358428ec06d5f2f6bea

6 years agoOSI: Copy temporary directoryname
Myles Watson [Wed, 29 Nov 2017 00:26:06 +0000 (16:26 -0800)]
OSI: Copy temporary directoryname

Bug: 69677828
Test: compiles
Change-Id: I70adc421812c71848712b03650aff2f85613ed81

6 years agoMerge "PAN: Fix issues reported by Static Analysis Tool" am: 1066862a95
Hemant Gupta [Wed, 29 Nov 2017 00:59:59 +0000 (00:59 +0000)]
Merge "PAN: Fix issues reported by Static Analysis Tool" am: 1066862a95
am: 06987337b7

Change-Id: Iad7d6cfe4ac43506af7546ebd66e6b074931adc1

6 years agoMerge "PAN: Fix issues reported by Static Analysis Tool"
Hemant Gupta [Wed, 29 Nov 2017 00:56:23 +0000 (00:56 +0000)]
Merge "PAN: Fix issues reported by Static Analysis Tool"
am: 1066862a95

Change-Id: I19dd06d77a87a18e57904d4776e4cc592955a37b

6 years agoMerge "PAN: Fix issues reported by Static Analysis Tool"
Treehugger Robot [Wed, 29 Nov 2017 00:51:41 +0000 (00:51 +0000)]
Merge "PAN: Fix issues reported by Static Analysis Tool"

6 years agoAdded SPP version 1.2 to SDP record.
Srinu Jella [Thu, 17 Nov 2016 09:04:50 +0000 (14:34 +0530)]
Added SPP version 1.2 to SDP record.

Added SPP version 1.2 to SDP record, SPP 1.0 is deprecated.

Test: mm -j8
Bug: 68303292
Change-Id: Ib0ed919d6145078fb9fc4214caae15ab6e7be780