Bluetooth: Handle sub system restart gracefully

Before triggering the restart of Bluetooth stack as part of sub-system
restart, make sure of proper cleanup of handles by informing the ssr
case to vendor modules by calling appropriate functions

Change-Id: Ic684ba13815ee21bb1706b6d6792e6bf17fa8286
Bluetooth: Acquire wake lock to avoid power collapse

This ensures that target wont go into power save mode
when there is an acl is active and timer are running.

Change-Id: I8a5d691760e7c9602f9c4d5d366825302aebd416
CRs-fixed: 576239
Bluetooth: Remove conn update at conn_cmpl to prevent encruption failure

This patch removes the conn update sent by the host based
on previously stored preferred connection params at the time of
new connection to prevent encryption command being
disallowed by the controller

Change-Id: Id9f14f92cfed27f8e1d8d285475cfd110ef5168e
CRs-Fixed: 585765
Bluetooth: Avoid bluetooth crash due to VS command for clear whitelist

This patch removes the clear AD white list VS command which
needs firmware update to work correctly.

Change-Id: I68124e7f8198456c83c171094ee7807f16e1140a
CRs-Fixed: 586204
Bluetooth: Handle SDP discover failure properly

AVDTP connection Request is sent even when the SDP discover is
failed to get the remote AVDTP capabilities. This change will
avoid the AVDTP connection in this scenario and also starts
pm idle timer for sniff.

CRs-Fixed: 581088

Change-Id: Ie51fcdd9ebea854ed7ca0f9917e244a117ccd764
Bluetooth: Disable Content Protection

Revert change 536691.
Content Protection needs to be disabled by default.

Change-Id: I7ce3fbe7b3b4ed9dba2962ad9b519c9261e2d3d6
Bluetooth: Add sdp record for Blueooth MAP: Email Message Access.

Add sdp record for Email Message Access, as part of email support
 in bluetooth Message Access profile.

Change-Id: I94dfa72c25bf19c7d43d343d842566f540be5e01
Merge "Bluetooth: Avoid bluetooth crash due to VS command for clear whitelist"
Merge "Bluetooth: Handle sub system restart gracefully"
Merge "Bluetooth: Disable Content Protection"
Merge "Bluetooth: Handle SDP discover failure properly"
Bluetooth: GAP: Don't update short name if the device paired

Don't notify the BT APP about the shortened device name which
will be part of EIR response,incase of device is already
paired.

Incase if the alias name present for that device, it
will notify th BT APP alias name as the actual device name.

CRs-Fixed: 576911
Change-Id: Ia64e1e90aae8c4e0cc52643ce3bbbb1332fe5b66
Bluetooth: Changes to implement A2DP Sink Support

 - changes in core stack and adaptation layer
 - awareness of sep type

CRs-Fixed: 580884

Change-Id: I9affefdd2d00597545e49c593ef3bddb110d4c9c
Bluetooth: link audioTrack and sbc decoder

 - load sbc decoder library dynammically
 - interaction with audiotrack module
 - buffering mechanism
 - feturize for OSS builds

CRs-Fixed: 580884

Change-Id: I48373c77a02746f406f4a9c790d36dcd4924558c
Bluetooth: Updated SCO sniff policy.

This change makes sure that DUT
uses correct Sniff policy when
in SCO connection.

Change-Id: I291a3ebda86eebe8d0b5def271404350a9a91b46
CRs-Fixed: 586744
Bluetooth: Fix for device in paired list after cancelling pairing

This patch adds an additional check before determining the smp
status of the disconn_cmpl event received from the SOC.
In case the disconn_cmpl is sent by the controller, the reason
form smp failure is verified before terminating the smp delay
as a result of authentication failure.

Change-Id: Iaea219077b4f8a64ed346b58380d11fd5dbe2d03
CRs-Fixed: 573572
Bluetooth: GAP: Reject incoming pairing if already in progress

This patch properly rejects incoming pairing request from remote device
if already in pairing state. Without this patch it was observed that in
some corner cases pairing was auto accepted for remote device while
pairing was in progress with another remote device leading to inconsistent
behaviour.

CRs-Fixed: 585463
Change-Id: Ic5489e79d1e41c944648e6064ecd25e0a73df669
Bluetooth: Move to proper state on SDP failure

After SDP is failed for AVDTP connection, we should move
to proper stable state.

CRs-Fixed: 588108

Change-Id: I58e60cd29e9f2ede98cb514a7f45774a3bc1d8ac
Fixes host behavior for pin or key missing encryption issue

When the host receives encryption change event with
pin or key missing status, the host was disconnecting
the connection to the remote device. This change
makes the host send Pairing request in this scenario.

CRs-fixed: 562960

Change-Id: Iba2aff00d5e6ef0932570678482054d9748df225
Merge "Bluetooth: GAP: Reject incoming pairing if already in progress"