diff options
author | Jack He <siyuanh@google.com> | 2022-02-23 16:58:03 +0000 |
---|---|---|
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | 2022-02-23 16:58:03 +0000 |
commit | 3a88d77b08c87cb1517fa63cbdf7f99ca10100db (patch) | |
tree | c2c8d3e52f453cfd79776457c35d2935a698b93c /system/bta | |
parent | 89b965d721c1b41755dc4935e576158d554714e5 (diff) | |
parent | 2e6d4b42917664491cd42bc0e13a2961ef058db4 (diff) |
Merge changes I343ff48c,I4b1ecf81 am: 2e6d4b4291
Original change: https://android-review.googlesource.com/c/platform/packages/modules/Bluetooth/+/1985329
Change-Id: Id92c7e06e2d4a4ecbbf63942a922613ce6484020
Diffstat (limited to 'system/bta')
-rw-r--r-- | system/bta/has/has_client.cc | 12 | ||||
-rw-r--r-- | system/bta/has/has_types.h | 2 |
2 files changed, 7 insertions, 7 deletions
diff --git a/system/bta/has/has_client.cc b/system/bta/has/has_client.cc index 7c6bbdc3c9..044713437f 100644 --- a/system/bta/has/has_client.cc +++ b/system/bta/has/has_client.cc @@ -1044,14 +1044,14 @@ class HasClientImpl : public HasClient { /* Journal update */ device->has_journal_.Append(HasJournalRecord(features, true)); - /* When service is not yet validated, report the available device and - * notify features otherwise. + /* When service is not yet validated, report the available device with + * features. */ - if (!device->isGattServiceValid()) { + if (!device->isGattServiceValid()) callbacks_->OnDeviceAvailable(device->addr, device->GetFeatures()); - } else { - callbacks_->OnFeaturesUpdate(device->addr, device->GetFeatures()); - } + + /* Notify features */ + callbacks_->OnFeaturesUpdate(device->addr, device->GetFeatures()); MarkDeviceValidIfInInitialDiscovery(*device); } diff --git a/system/bta/has/has_types.h b/system/bta/has/has_types.h index 89ed82a8ce..d726f07cf7 100644 --- a/system/bta/has/has_types.h +++ b/system/bta/has/has_types.h @@ -72,7 +72,7 @@ static_assert(sizeof(HasGattOpContext) <= sizeof(void*)); /* Service UUIDs */ /* FIXME: actually these were not yet assigned - using placeholders for now. */ static const bluetooth::Uuid kUuidHearingAccessService = - bluetooth::Uuid::From16Bit(0xEEEE); + bluetooth::Uuid::From16Bit(0x1854); static const bluetooth::Uuid kUuidHearingAidFeatures = bluetooth::Uuid::From16Bit(0xEEED); static const bluetooth::Uuid kUuidHearingAidPresetControlPoint = |