component/bt: Add SPP profile

This commit is contained in:
baohongde
2018-01-05 16:48:29 +08:00
parent 5401a75bad
commit d2663c866e
45 changed files with 7214 additions and 46 deletions
@@ -498,6 +498,34 @@ void btu_stop_timer(TIMER_LIST_ENT *p_tle)
osi_alarm_cancel(alarm);
}
/*******************************************************************************
**
** Function btu_free_timer
**
** Description Stop and free a timer.
**
** Returns void
**
*******************************************************************************/
void btu_free_timer(TIMER_LIST_ENT *p_tle)
{
assert(p_tle != NULL);
if (p_tle->in_use == FALSE) {
return;
}
p_tle->in_use = FALSE;
// Get the alarm for the timer list entry.
osi_alarm_t *alarm = hash_map_get(btu_general_alarm_hash_map, p_tle);
if (alarm == NULL) {
LOG_WARN("%s Unable to find expected alarm in hashmap", __func__);
return;
}
osi_alarm_cancel(alarm);
hash_map_erase(btu_general_alarm_hash_map, p_tle);
}
#if defined(QUICK_TIMER_TICKS_PER_SEC) && (QUICK_TIMER_TICKS_PER_SEC > 0)
/*******************************************************************************
**