Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit cb1d20f4 authored by William Escande's avatar William Escande Committed by Gerrit Code Review
Browse files

Merge changes from topic "conn.min.limit_sysprop-master"

* changes:
  Point directly to generated c sysprop_library
  Use the "bluetooth.core.gap.le.conn.min.limit" sysprop config
parents c09521a6 fbd760c8
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -38,6 +38,7 @@ cc_defaults {
        "android.hardware.bluetooth@1.1",
        "android.system.suspend-V1-ndk",
        "android.system.suspend.control-V1-ndk",
        "libPlatformProperties",
        "libaaudio",
        "libbinder_ndk",
        "libcrypto",
+1 −3
Original line number Diff line number Diff line
@@ -210,9 +210,6 @@ cc_library_static {
    ],
    target: {
        android: {
            whole_static_libs: [
                "libPlatformProperties",
            ],
            srcs: ["src/btif_avrcp_audio_track.cc"],
        },
        host: {
@@ -298,6 +295,7 @@ cc_test {
        android: {
            shared_libs: [
                "android.hardware.bluetooth.audio-V3-ndk",
                "libPlatformProperties",
                "libbinder_ndk",
            ],
        },
+1 −0
Original line number Diff line number Diff line
@@ -213,6 +213,7 @@ cc_defaults {
                "android.hardware.bluetooth.audio@2.0",
                "android.hardware.bluetooth.audio@2.1",
                "android.system.suspend-V1-ndk",
                "libPlatformProperties",
                "libaaudio",
                "libbinder_ndk",
                "libcutils",
+8 −0
Original line number Diff line number Diff line
@@ -316,6 +316,7 @@ cc_test {
        "android.hardware.bluetooth.audio@2.1",
        "android.hardware.bluetooth@1.0",
        "android.hardware.bluetooth@1.1",
        "libPlatformProperties",
        "libaaudio",
        "libbinder_ndk",
        "libcrypto",
@@ -1430,6 +1431,13 @@ cc_test {
        "libbinder_ndk",
        "libcrypto",
    ],
    target: {
        android: {
            shared_libs: [
                "libPlatformProperties",
            ],
        },
    },
    sanitize: {
        address: true,
        all_undefined: true,
+14 −0
Original line number Diff line number Diff line
@@ -28,6 +28,10 @@
#include <base/strings/stringprintf.h>
#include <log/log.h>

#ifdef OS_ANDROID
#include <android/sysprop/BluetoothProperties.sysprop.h>
#endif

#include "bt_target.h"
#include "bta/include/bta_hearing_aid_api.h"
#include "btif/include/core_callbacks.h"
@@ -39,6 +43,7 @@
#include "osi/include/allocator.h"
#include "osi/include/log.h"
#include "osi/include/osi.h"
#include "osi/include/properties.h"
#include "stack/btm/btm_dev.h"
#include "stack/btm/btm_sec.h"
#include "stack/include/acl_api.h"
@@ -1655,7 +1660,16 @@ tL2CAP_LE_RESULT_CODE l2ble_sec_access_req(const RawAddress& bd_addr,
void L2CA_AdjustConnectionIntervals(uint16_t* min_interval,
                                    uint16_t* max_interval,
                                    uint16_t floor_interval) {
  // Allow for customization by systemprops for mainline
  uint16_t phone_min_interval = floor_interval;
  #ifdef OS_ANDROID
    phone_min_interval =
        android::sysprop::BluetoothProperties::getGapLeConnMinLimit().value_or(
            floor_interval);
  #else
    phone_min_interval = (uint16_t)osi_property_get_int32(
      "bluetooth.core.gap.le.conn.min.limit", (int32_t)floor_interval);
  #endif

  if (GetInterfaceToProfiles()
          ->profileSpecific_HACK->GetHearingAidDeviceCount()) {
Loading