From f6f8d78acaaeee43a6dba9c434d90976ebdc964c Mon Sep 17 00:00:00 2001 From: Zhi Wei Jian Date: Wed, 7 Jan 2026 17:23:59 +0800 Subject: [PATCH] fix(ble/bluedroid): Disable bluedroid host Qos (cherry picked from commit 47f13aa75b88234e9d742671c189d2bc0746ceb5) Co-authored-by: zhiweijian --- components/bt/host/bluedroid/stack/btm/btm_acl.c | 5 ++++- components/bt/host/bluedroid/stack/btm/include/btm_int.h | 3 ++- components/bt/host/bluedroid/stack/btu/btu_hcif.c | 2 ++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/components/bt/host/bluedroid/stack/btm/btm_acl.c b/components/bt/host/bluedroid/stack/btm/btm_acl.c index 6bd991c1f96..192b62408bb 100644 --- a/components/bt/host/bluedroid/stack/btm/btm_acl.c +++ b/components/bt/host/bluedroid/stack/btm/btm_acl.c @@ -1891,6 +1891,7 @@ tBTM_STATUS BTM_RegAclLinkStatNotif(tBTM_ACL_LINK_STAT_CB *p_cb) return BTM_SUCCESS; } +#if (CLASSIC_BT_INCLUDED == TRUE) /******************************************************************************* ** ** Function BTM_SetQoS @@ -1972,7 +1973,7 @@ void btm_qos_setup_complete (UINT8 status, UINT16 handle, FLOW_SPEC *p_flow) (*p_cb)(&qossu); } } - +#endif // (CLASSIC_BT_INCLUDED == TRUE) /******************************************************************************* ** ** Function btm_qos_setup_timeout @@ -1987,7 +1988,9 @@ void btm_qos_setup_timeout (void *p_tle) { BTM_TRACE_DEBUG ("%s\n", __func__); +#if (CLASSIC_BT_INCLUDED == TRUE) btm_qos_setup_complete (HCI_ERR_HOST_TIMEOUT, 0, NULL); +#endif // (CLASSIC_BT_INCLUDED == TRUE) } /******************************************************************************* diff --git a/components/bt/host/bluedroid/stack/btm/include/btm_int.h b/components/bt/host/bluedroid/stack/btm/include/btm_int.h index 4adea06b061..d4699329adb 100644 --- a/components/bt/host/bluedroid/stack/btm/include/btm_int.h +++ b/components/bt/host/bluedroid/stack/btm/include/btm_int.h @@ -201,10 +201,11 @@ tBTM_CMPL_CB *p_lnk_qual_cmpl_cb;/* Callback function to be called when TIMER_LIST_ENT txpwer_timer; tBTM_CMPL_CB *p_txpwer_cmpl_cb; /* Callback function to be called when */ /* read inq tx power function completes */ - +#if (CLASSIC_BT_INCLUDED == TRUE) TIMER_LIST_ENT qossu_timer; tBTM_CMPL_CB *p_qossu_cmpl_cb; /* Callback function to be called when */ /* qos setup function completes */ +#endif // (CLASSIC_BT_INCLUDED == TRUE) tBTM_ROLE_SWITCH_CMPL switch_role_ref_data; tBTM_CMPL_CB *p_switch_role_cb; /* Callback function to be called when */ diff --git a/components/bt/host/bluedroid/stack/btu/btu_hcif.c b/components/bt/host/bluedroid/stack/btu/btu_hcif.c index 52365cf62c2..728d2b178f3 100644 --- a/components/bt/host/bluedroid/stack/btu/btu_hcif.c +++ b/components/bt/host/bluedroid/stack/btu/btu_hcif.c @@ -1702,8 +1702,10 @@ static void btu_hcif_hdl_command_status (UINT16 opcode, UINT8 status, UINT8 *p_c break; case HCI_QOS_SETUP_COMP_EVT: + #if (CLASSIC_BT_INCLUDED == TRUE) /* Tell qos setup that we are done */ btm_qos_setup_complete(status, 0, NULL); + #endif // (CLASSIC_BT_INCLUDED == TRUE) break; case HCI_SWITCH_ROLE: