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

Commit de5ce33d authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "Floss: fix wbs_supported for sco_hfp_hal_linux"

parents 30c877e8 a888bfbf
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -180,6 +180,7 @@ cc_defaults {
        "lib-bt-packets-base",
        "lib-bt-packets-avrcp",
        "libbt-audio-hal-interface",
        "libbt-stack",
        "libaudio-a2dp-hw-utils",
    ],
    cflags: [
@@ -486,6 +487,7 @@ cc_test {
          "libaudio-a2dp-hw-utils",
          "libbluetooth-types",
          "libbt-audio-hal-interface",
          "libbt-stack",
          "libbtdevice",
          "lib-bt-packets",
          "lib-bt-packets-avrcp",
+5 −5
Original line number Diff line number Diff line
@@ -45,6 +45,7 @@
#include "include/hardware/bt_hf.h"
#include "main/shim/dumpsys.h"
#include "osi/include/log.h"
#include "stack/btm/btm_sco_hfp_hal.h"
#include "stack/include/btm_api.h"
#include "types/raw_address.h"

@@ -552,11 +553,10 @@ static void btif_hf_upstreams_evt(uint16_t event, char* p_param) {
    case BTA_AG_AT_BAC_EVT:
      BTIF_TRACE_DEBUG("AG Bitmap of peer-codecs %d", p_data->val.num);
      /* If the peer supports mSBC and the BTIF preferred codec is also mSBC,
      then
      we should set the BTA AG Codec to mSBC. This would trigger a +BCS to mSBC
      at the time
      of SCO connection establishment */
      if (p_data->val.num & BTM_SCO_CODEC_MSBC) {
       * then we should set the BTA AG Codec to mSBC. This would trigger a +BCS
       * to mSBC at the time of SCO connection establishment */
      if (hfp_hal_interface::get_wbs_supported() &&
          (p_data->val.num & BTM_SCO_CODEC_MSBC)) {
        BTIF_TRACE_EVENT("%s: btif_hf override-Preferred Codec to MSBC",
                         __func__);
        BTA_AgSetCodec(btif_hf_cb[idx].handle, BTM_SCO_CODEC_MSBC);