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

Commit 6c0a1a8c authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Merge cherrypicks of ['googleplex-android-review.googlesource.com/27901010',...

Merge cherrypicks of ['googleplex-android-review.googlesource.com/27901010', 'googleplex-android-review.googlesource.com/27901672'] into 24Q4-release.

Change-Id: I75fdd04697e3303ddf24518736e7f8f5a7c5b5f2
parents 80dc5403 74feaa08
Loading
Loading
Loading
Loading
+0 −10
Original line number Diff line number Diff line
@@ -75,13 +75,3 @@ flag {
        purpose: PURPOSE_BUGFIX
    }
}

flag {
    name: "a2dp_check_lea_iso_channel"
    namespace: "bluetooth"
    description: "Prevent A2DP stream from starting when LEA ISO channels are in use"
    bug: "346475618"
    metadata {
        purpose: PURPOSE_BUGFIX
    }
}
+0 −10
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@
#include "a2dp_encoding_aidl.h"

#include <bluetooth/log.h>
#include <com_android_bluetooth_flags.h>

#include <vector>

@@ -27,7 +26,6 @@
#include "audio_aidl_interfaces.h"
#include "bta/av/bta_av_int.h"
#include "btif/include/btif_common.h"
#include "btm_iso_api.h"
#include "codec_status_aidl.h"
#include "transport_instance.h"

@@ -99,14 +97,6 @@ BluetoothAudioCtrlAck A2dpTransport::StartRequest(bool is_low_latency) {
    return a2dp_ack_to_bt_audio_ctrl_ack(A2DP_CTRL_ACK_INCALL_FAILURE);
  }

  if (com::android::bluetooth::flags::a2dp_check_lea_iso_channel()) {
    // Don't send START request to stack while LEA sessions are in use
    if (hci::IsoManager::GetInstance()->GetNumberOfActiveIso() > 0) {
      log::error("LEA currently has active ISO channels");
      return a2dp_ack_to_bt_audio_ctrl_ack(A2DP_CTRL_ACK_FAILURE);
    }
  }

  if (btif_av_stream_started_ready(A2dpType::kSource)) {
    // Already started, ACK back immediately.
    return a2dp_ack_to_bt_audio_ctrl_ack(A2DP_CTRL_ACK_SUCCESS);
+0 −4
Original line number Diff line number Diff line
@@ -90,10 +90,6 @@ void IsoManager::DisconnectCis(uint16_t cis_handle, uint8_t reason) {
  pimpl_->iso_impl_->disconnect_cis(cis_handle, reason);
}

int IsoManager::GetNumberOfActiveIso() {
  return pimpl_->iso_impl_->get_number_of_active_iso();
}

void IsoManager::SetupIsoDataPath(
    uint16_t iso_handle, struct iso_manager::iso_data_path_params path_params) {
  pimpl_->iso_impl_->setup_iso_data_path(iso_handle, std::move(path_params));
+0 −6
Original line number Diff line number Diff line
@@ -342,12 +342,6 @@ struct iso_impl {
                       hci_reason_code_text((tHCI_REASON)(reason)).c_str()));
  }

  int get_number_of_active_iso() {
    int num_iso = conn_hdl_to_cis_map_.size() + conn_hdl_to_bis_map_.size();
    log::info("Current number of active_iso is {}", num_iso);
    return num_iso;
  }

  void on_setup_iso_data_path(uint8_t* stream, uint16_t /* len */) {
    uint8_t status;
    uint16_t conn_handle;
+0 −5
Original line number Diff line number Diff line
@@ -226,11 +226,6 @@ class IsoManager {
  virtual void HandleHciEvent(uint8_t sub_code, uint8_t* params,
                              uint16_t length);

  /**
   * Return the current number of ISO channels
   */
  virtual int GetNumberOfActiveIso();

  /**
   * Starts the IsoManager module
   */
Loading