diff --git a/components/bt/host/bluedroid/stack/smp/smp_keys.c b/components/bt/host/bluedroid/stack/smp/smp_keys.c index 99cce9b401f..8924b2f90e8 100644 --- a/components/bt/host/bluedroid/stack/smp/smp_keys.c +++ b/components/bt/host/bluedroid/stack/smp/smp_keys.c @@ -2315,11 +2315,8 @@ BOOLEAN smp_calculate_link_key_from_long_term_key(tSMP_CB *p_cb) SMP_TRACE_ERROR("%s failed", __func__); } else { UINT8 link_key_type; - if (btm_cb.security_mode == BTM_SEC_MODE_SC) { - /* Secure Connections Only Mode */ - link_key_type = BTM_LKEY_TYPE_AUTH_COMB_P_256; - } else if (controller_get_interface()->supports_secure_connections()) { - /* both transports are SC capable */ + if ((btm_cb.security_mode == BTM_SEC_MODE_SC) || + (controller_get_interface()->supports_secure_connections())) { if (p_cb->sec_level == SMP_SEC_AUTHENTICATED) { link_key_type = BTM_LKEY_TYPE_AUTH_COMB_P_256; } else {