The ACTION_AUDIO_STATE_CHANGED intent action uses the HDP profile,
not the A2DP profile.
Bug: 158742305
Test: m ds-docs-java
Exempt-From-Owner-Approval: Docs-only change
Change-Id: I4358aac8c8aa9fc8b36e517e568e5a9db538555e
the non-SDK API list to the blocklist in Android 11 back to the non-SDK
API list.
Tag: #feature
Bug: 168812851
Test: atest BluetoothHostTest#testCodecMethodsAccessible
Change-Id: I29983284b1a1c271d983c99b286e204604abdc72
onServiceDisconnected method after unbinding the service
Bug: 155120232
Test: atest BluetoothHostTest#testMapClose
Change-Id: I324b4ea6654261eb67d5ec184f6b3456ba3d1aa4
Bug: 153103051
A binder cache recompute() function cannot compute a result based on any
data that is not known to the binder server. If the code depends on
local data that can change, then invalidation will not work properly.
The original getState() method returned OFF if the bluetooth service was
unavailable. This computation now occurs in the getStateInternal()
method, outside of the binder cache query() method.
The recompute() method converts RemoteExceptions to RuntimeExceptions.
Then, the conversion is reversed in getStateInternal(). This double
conversion is needed because the cache recompute() method has no throw
spec.
Test: Create a debug image that enables binder cache VERIFY. Run the
following tests:
* atest BluetoothInstrumentationTests
* atest PtsChreTestCases
* atest UserLifecycleTests
* manual testing connecting to bluetooth devices and toggling airplane
mode.
No cache inconsistencies found. No test failures seen.
Change-Id: I93b9742587c4eb695d9a11fc6ab145f6a40a0ece
Bug: 153103051
A binder cache query function cannot compute a result based on any data
that is not known to the binder server. If the code depends on local
data that can change, then invalidation will not work properly.
The getState() method returns OFF if the bluetooth service is
unavailable. This computation now occurs in the getState() method,
outside of the binder cache query() method.
The query method converts RemoteExceptions to RuntimeExceptions. Then,
the conversion is reversed in getState(). This double conversion is
needed because the cache query() method has no throw spec.
Test: Run 'atest BluetoothInstrumentationTests' with a special debug
image that enables binder cache VERIFY. The test found no cache
inconsistencies.
Change-Id: I80db86f66d8b51fa94207824c8b15972a9066ef5
* Use IBluetoothManager.enableBle() and disableBle() to toggle BLE only
mode instead of updateBleAppCount() then enable().
* Fix BluetoothAdapter.disableBle sometime won't disable Bluetooth.
* Add active log if Bluetooth is disabled via disableBle().
Bug: 139454316
Test: enableBle() -> disableBle() and check Bluetooth is OFF.
Change-Id: I173d5fed1b47ff68a6504741e25754e65cbd1455
Hide some APIs that were previously marked as @UnsupportedAppUsage and re-add annotation as changing the permissions for these SystemApis would break the unsupported app contract that was previously there. Therefore, we're choosing to hide them until we have a good story on how to deal with them next release.
Bug: 148689314
Test: Manual
Change-Id: I33ee2c7ccd3827db3d23d6447cf82d9ffc36836a
that do not need to be System APIs.
Bug: 146045934
Test: Manual
Merged-In: Ic6325fde05294eb0266fee25f4b3e7098749a287
Change-Id: Ic6325fde05294eb0266fee25f4b3e7098749a287
(removed all references to CustomerId) and added link to explain what
the HiSyncId represents
Bug: 149238489
Test: Manual
Merged-In: I4ff2a8d46f3fc5d06a29829a69a27a0c15e466f8
Change-Id: I4ff2a8d46f3fc5d06a29829a69a27a0c15e466f8
In the core functionality this changes everything including aidl's and
field names:
- Context
- ContentProvider
- AppOps*
- Package parsing
For the rest, this is a shallow change to only change to the changed
APIs. This keeps the change small-ish
Exempt-From-Owner-Approval: Rename
Fixes: 148792795
Test: TH
Change-Id: I2a2245fe76e09e62cb13d5785d2efb4a304ba54a
Merged-In: I2a2245fe76e09e62cb13d5785d2efb4a304ba54a
Remove disable Bluetooth action from AdapterService and move to
BluetoothManagerService.
Add factory reset reason into Bluetooth enable/disable reason list.
Bug: 110181479
Test: manual
Change-Id: I4bff3c3bb75fbb0d1e13c459c0d9d3fd3b8b3195
Revert "Revert "Pass in active device to all BluetoothA2dp APIs ..."
Revert "Revert "Pass in active device to all BluetoothA2dp APIs ..."
Revert submission 10303287-revert-10253996-bt-a2dp-no-null-FQRXACWPIA
Reason for revert: Fixing breakage
Reverted Changes:
I4d9f2f819:Revert "Make sure calls to BluetoothA2dp APIs pass...
I771ca0d57:Revert "Need to now pass in active device instead ...
I76529c7a1:Revert "Pass in active device to all BluetoothA2dp...
I297bda68d:Revert "Require user pass in a non-null BluetoothD...
I525327959:Revert "Pass in active device to all BluetoothA2dp...
I1d8660b11:Revert "Pass in active device to all BluetoothA2dp...
Bug: 147287141
Test: Manual
Merged-In: I4d7d971af75bff8967fd807d34dad90c32e24eba
Change-Id: I4d7d971af75bff8967fd807d34dad90c32e24eba
BluetoothMap APIs, disallow null device input for setConnectionPolicy,
getConnectionPolicy, and getConnectionState in BluetoothHidHost, and
BluetoothMap implements AutoCloseable, its close() method is public, and
utilizes a CloseGuard.
Bug: 149238030
Test: Manual
Merged-In: I8add9e26afcaf1a988c15e3cc7f8c446491f0686
Change-Id: I8add9e26afcaf1a988c15e3cc7f8c446491f0686
true on successfully setting the connection policy instead of on
disconnection. It also now indicates that if
BluetoothProfile#CONNECTION_POLICY_FORBIDDEN is passed in, the profile
will be disconnected.
Bug: 148966894
Test: Manual
Change-Id: I881c240fcbce0c8148625c35e6e88ab02ea7122f
Bug: 140788621
Test: A special build that puts the PropertyInvalidatedCache in verification
mode was loaded on the device. Then one iteration of MPTS was executed. No
cache inconsistencies were found and no SELinux violations (associated with
the binder cache) were found. The number of cache misses was approximately
10% of the total binder calls. Then the phone was cycled through bluetooth
pairing and unpairing events.
Change-Id: Ia494f0ad58b889130052e5beb3bec6d1011508ef
Revert "Pass in active device to all BluetoothA2dp APIs in packa..."
Revert "Pass in active device to all BluetoothA2dp APIs in packa..."
Revert submission 10253996-bt-a2dp-no-null
Reason for revert: b/149361880
Reverted Changes:
If43934374: Pass in active device to all BluetoothA2dp APIs in...
I22dd1ca36: Make sure calls to BluetoothA2dp APIs pass non-nul...
If6475af6f: Require user pass in a non-null BluetoothDevice to...
I9d0e2c89c: Pass in active device to all BluetoothA2dp APIs in...
I1faa6174d: Need to now pass in active device instead of null ...
I69a941a7e: Pass in active device to all BluetoothA2dp APIs in...
Change-Id: I297bda68da5023fd832201c485554d6bff05fa78
* A cache for isOffloadedFilteringSupported().
* A cache for getProfileConnectionState().
Bug: 140788621
Test: A special build that puts the PropertyInvalidatedCache in
verification mode was loaded on the device. Then one iteration of MPTS
was executed. No cache inconsistencies were found and no SELinux
violations (associated with the binder cache) were found. The number of
cache misses was approximately 15% of the total binder calls. A second
test was run in which bluetooth headphones were connected and
disconnected. Then bluetooth itself was disabled and then enabled. The
caches were invalidated as expected and no errors were uncovered.
Change-Id: Icfad1071725e2d1e320fd252a49f0c4ae8ce6ad0
instance of the class, add intdef to return value of
BluetoothPbap#getConnectionState, and move all SystemApis to require
the BLUETOOTH_PRIVILEGED permission
Bug: 148966894
Test: Manual
Change-Id: I4a798b0a16ab839f2047fc58f21c420cc99b6db6
BluetoothAdapter#disconnectAllEnabledProfiles updated to require
BLUETOOTH_PRIVILEGED permission and update documentation to indicate
connection and disconnection is asynchronous
Bug: 147321746
Test: Manual
Change-Id: I961f02a539a247b1397ce4f478b9dc804d9973ab
Bug: 140788621
Test: A special build that puts the PropertyInvalidatedCache in verification
mode was loaded on the device. Then one iteration of MPTS was executed. No
cache inconsistencies were found and no SELinux violations (associated with
the binder cache) were found. The number of cache misses was approximately
3% of the total binder calls. All binder calls went through the cache.
Repeated the test with a work profile installed (to provide a second user
ID).
Change-Id: I2f1d0b6d61dedc5d1badb06a20c5932eca415904