summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Henri Chataing <henrichataing@google.com> 2024-12-09 10:47:23 -0800
committer Henri Chataing <henrichataing@google.com> 2024-12-10 18:02:59 +0000
commitebc2e8b935480991ffff23ce89f11889ce6d261a (patch)
tree82d941ce05f86f8404b41ef10839ded382d818eb
parent0cb205b681a969e80458d46eab8453a57644c3f0 (diff)
Flags 24Q4: Remove the flag avdtp_error_codes
Bug: 338139069 Test: m com.android.btservices Flag: com.android.bluetooth.flags.avdtp_error_codes Change-Id: I358fc43145e1b310ac4eb3b4c22b21d77d346bc7
-rw-r--r--android/pandora/server/configs/pts_bot_tests_config.json9
-rw-r--r--flags/a2dp.aconfig10
-rw-r--r--system/bta/av/bta_av_aact.cc5
-rw-r--r--system/stack/avdt/avdt_scb_act.cc7
4 files changed, 3 insertions, 28 deletions
diff --git a/android/pandora/server/configs/pts_bot_tests_config.json b/android/pandora/server/configs/pts_bot_tests_config.json
index 6ebae93244..758d21f07c 100644
--- a/android/pandora/server/configs/pts_bot_tests_config.json
+++ b/android/pandora/server/configs/pts_bot_tests_config.json
@@ -3216,15 +3216,6 @@
"flags": [
{
"flags": [
- "avdtp_error_codes"
- ],
- "tests": [
- "A2DP/SNK/AVP",
- "A2DP/SRC/AVP"
- ]
- },
- {
- "flags": [
"leaudio_allow_leaudio_only_devices",
"enable_hap_by_default"
],
diff --git a/flags/a2dp.aconfig b/flags/a2dp.aconfig
index 15cf789176..0cf6dc8ef0 100644
--- a/flags/a2dp.aconfig
+++ b/flags/a2dp.aconfig
@@ -2,16 +2,6 @@ package: "com.android.bluetooth.flags"
container: "com.android.btservices"
flag {
- name: "avdtp_error_codes"
- namespace: "bluetooth"
- description: "Use compliant error codes in AVDTP responses"
- bug: "338139069"
- metadata {
- purpose: PURPOSE_BUGFIX
- }
-}
-
-flag {
name: "bta_av_use_peer_codec"
namespace: "bluetooth"
description: "Deprecate bta av codec state"
diff --git a/system/bta/av/bta_av_aact.cc b/system/bta/av/bta_av_aact.cc
index 7c4d8a04c1..b5bc3ff6fd 100644
--- a/system/bta/av/bta_av_aact.cc
+++ b/system/bta/av/bta_av_aact.cc
@@ -1782,11 +1782,6 @@ void bta_av_setconfig_rej(tBTA_AV_SCB* p_scb, tBTA_AV_DATA* p_data) {
log::info("sep_idx={} avdt_handle={} bta_handle=0x{:x} err_code=0x{:x}", p_scb->sep_idx,
p_scb->avdt_handle, p_scb->hndl, err_code);
- if (!com::android::bluetooth::flags::avdtp_error_codes()) {
- bta_av_adjust_seps_idx(p_scb, avdt_handle);
- err_code = AVDT_ERR_UNSUP_CFG;
- }
-
// The error code might not be set when the configuration is rejected
// based on the current AVDTP state.
if (err_code == AVDT_SUCCESS) {
diff --git a/system/stack/avdt/avdt_scb_act.cc b/system/stack/avdt/avdt_scb_act.cc
index 003f927c9c..e09cde8eeb 100644
--- a/system/stack/avdt/avdt_scb_act.cc
+++ b/system/stack/avdt/avdt_scb_act.cc
@@ -570,10 +570,9 @@ void avdt_scb_hdl_setconfig_cmd(AvdtpScb* p_scb, tAVDT_SCB_EVT* p_data) {
// the codec type differs from the type of the SEP, or INVALID_CODEC_TYPE
// if the codec type does not match the values defined by Assigned Numbers.
if (local_codec_type != remote_codec_type) {
- p_data->msg.hdr.err_code =
- !com::android::bluetooth::flags::avdtp_error_codes() ? AVDTP_UNSUPPORTED_CONFIGURATION
- : !A2DP_IsCodecTypeValid(remote_codec_type) ? A2DP_INVALID_CODEC_TYPE
- : A2DP_NOT_SUPPORTED_CODEC_TYPE;
+ p_data->msg.hdr.err_code = !A2DP_IsCodecTypeValid(remote_codec_type)
+ ? A2DP_INVALID_CODEC_TYPE
+ : A2DP_NOT_SUPPORTED_CODEC_TYPE;
p_data->msg.hdr.err_param = 0;
avdt_msg_send_rej(avdt_ccb_by_idx(p_data->msg.hdr.ccb_idx), p_data->msg.hdr.sig_id,
&p_data->msg);