diff options
Diffstat (limited to 'stack')
-rw-r--r-- | stack/btm/btm_inq.c | 2 | ||||
-rw-r--r-- | stack/btm/btm_sec.c | 6 | ||||
-rw-r--r-- | stack/btu/btu_task.c | 17 | ||||
-rw-r--r-- | stack/include/btu.h | 7 | ||||
-rw-r--r-- | stack/l2cap/l2c_fcr.c | 1 | ||||
-rw-r--r-- | stack/rfcomm/rfc_l2cap_if.c | 2 |
6 files changed, 5 insertions, 30 deletions
diff --git a/stack/btm/btm_inq.c b/stack/btm/btm_inq.c index 629423273..7d544d8e5 100644 --- a/stack/btm/btm_inq.c +++ b/stack/btm/btm_inq.c @@ -1988,7 +1988,7 @@ void btm_process_inq_results (UINT8 *p, UINT8 inq_res_mode) p_cur->dev_class[2] = dc[2]; p_cur->clock_offset = clock_offset | BTM_CLOCK_OFFSET_VALID; - p_i->time_of_resp = GKI_get_tick_count (); + p_i->time_of_resp = GKI_get_os_tick_count(); if (p_i->inq_count != p_inq->inq_counter) p_inq->inq_cmpl_info.num_resp++; /* A new response was found */ diff --git a/stack/btm/btm_sec.c b/stack/btm/btm_sec.c index 83d1679e9..029eb39b2 100644 --- a/stack/btm/btm_sec.c +++ b/stack/btm/btm_sec.c @@ -44,7 +44,7 @@ #include "gatt_int.h" #endif -#define BTM_SEC_MAX_COLLISION_DELAY (GKI_SECS_TO_TICKS(5)) +#define BTM_SEC_MAX_COLLISION_DELAY (5000) #ifdef APPL_AUTH_WRITE_EXCEPTION BOOLEAN (APPL_AUTH_WRITE_EXCEPTION)(BD_ADDR bd_addr); @@ -3562,9 +3562,9 @@ static void btm_sec_auth_collision (UINT16 handle) tBTM_SEC_DEV_REC *p_dev_rec; if (!btm_cb.collision_start_time) - btm_cb.collision_start_time = GKI_get_tick_count (); + btm_cb.collision_start_time = GKI_get_os_tick_count(); - if ((GKI_get_tick_count () - btm_cb.collision_start_time) < btm_cb.max_collision_delay) + if ((GKI_get_os_tick_count() - btm_cb.collision_start_time) < btm_cb.max_collision_delay) { if (handle == BTM_SEC_INVALID_HANDLE) { diff --git a/stack/btu/btu_task.c b/stack/btu/btu_task.c index 99d73b970..6cef4fb7c 100644 --- a/stack/btu/btu_task.c +++ b/stack/btu/btu_task.c @@ -447,7 +447,6 @@ void btu_general_alarm_cb(void *data) { TIMER_LIST_ENT *p_tle = (TIMER_LIST_ENT *)data; fixed_queue_enqueue(btu_general_alarm_queue, p_tle); - GKI_send_event(BTU_TASK, TIMER_0_EVT_MASK); } void btu_start_timer(TIMER_LIST_ENT *p_tle, UINT16 type, UINT32 timeout_sec) { @@ -476,20 +475,6 @@ void btu_start_timer(TIMER_LIST_ENT *p_tle, UINT16 type, UINT32 timeout_sec) { /******************************************************************************* ** -** Function btu_remaining_time -** -** Description Return amount of time to expire -** -** Returns time in second -** -*******************************************************************************/ -UINT32 btu_remaining_time (TIMER_LIST_ENT *p_tle) -{ - return(GKI_get_remaining_ticks (&btu_cb.timer_queue, p_tle)); -} - -/******************************************************************************* -** ** Function btu_stop_timer ** ** Description Stop a timer. @@ -542,7 +527,6 @@ static void btu_l2cap_alarm_cb(void *data) { TIMER_LIST_ENT *p_tle = (TIMER_LIST_ENT *)data; fixed_queue_enqueue(btu_l2cap_alarm_queue, p_tle); - GKI_send_event(BTU_TASK, TIMER_2_EVT_MASK); } void btu_start_quick_timer(TIMER_LIST_ENT *p_tle, UINT16 type, UINT32 timeout_ticks) { @@ -602,7 +586,6 @@ void btu_oneshot_alarm_cb(void *data) { btu_stop_timer_oneshot(p_tle); fixed_queue_enqueue(btu_oneshot_alarm_queue, p_tle); - GKI_send_event(BTU_TASK, TIMER_3_EVT_MASK); } /* diff --git a/stack/include/btu.h b/stack/include/btu.h index 5449c1a78..2da0035d7 100644 --- a/stack/include/btu.h +++ b/stack/include/btu.h @@ -224,10 +224,6 @@ typedef struct tBTU_TIMER_REG timer_reg[BTU_MAX_REG_TIMER]; tBTU_EVENT_REG event_reg[BTU_MAX_REG_EVENT]; - TIMER_LIST_Q quick_timer_queue; /* Timer queue for transport level (100/10 msec)*/ - TIMER_LIST_Q timer_queue; /* Timer queue for normal BTU task (1 second) */ - TIMER_LIST_Q timer_queue_oneshot; /* Timer queue for oneshot BTU tasks */ - BOOLEAN reset_complete; /* TRUE after first ack from device received */ UINT8 trace_level; /* Trace level for HCI layer */ } tBTU_CB; @@ -253,16 +249,13 @@ extern void btu_start_timer (TIMER_LIST_ENT *p_tle, UINT16 type, UINT32 timeout) extern void btu_stop_timer (TIMER_LIST_ENT *p_tle); extern void btu_start_timer_oneshot(TIMER_LIST_ENT *p_tle, UINT16 type, UINT32 timeout); extern void btu_stop_timer_oneshot(TIMER_LIST_ENT *p_tle); -extern UINT32 btu_remaining_time (TIMER_LIST_ENT *p_tle); -extern UINT32 btu_remaining_time (TIMER_LIST_ENT *p_tle); extern void btu_uipc_rx_cback(BT_HDR *p_msg); /* ** Quick Timer */ #if defined(QUICK_TIMER_TICKS_PER_SEC) && (QUICK_TIMER_TICKS_PER_SEC > 0) -#define QUICK_TIMER_TICKS (GKI_SECS_TO_TICKS (1)/QUICK_TIMER_TICKS_PER_SEC) extern void btu_start_quick_timer (TIMER_LIST_ENT *p_tle, UINT16 type, UINT32 timeout); extern void btu_stop_quick_timer (TIMER_LIST_ENT *p_tle); extern void btu_process_quick_timer_evt (void); diff --git a/stack/l2cap/l2c_fcr.c b/stack/l2cap/l2c_fcr.c index 1dbcbeb54..ec9a4ef88 100644 --- a/stack/l2cap/l2c_fcr.c +++ b/stack/l2cap/l2c_fcr.c @@ -243,7 +243,6 @@ void l2c_fcr_cleanup (tL2C_CCB *p_ccb) UINT16 i; UINT32 throughput_avg, ack_delay_avg, ack_q_count_avg; - dur = GKI_OS_TICKS_TO_MS(dur); BT_TRACE(TRACE_CTRL_GENERAL | TRACE_LAYER_GKI | TRACE_ORG_GKI , TRACE_TYPE_GENERIC, "--- L2CAP ERTM Stats for CID: 0x%04x Duration: %08ums", p_ccb->local_cid, dur); BT_TRACE(TRACE_CTRL_GENERAL | TRACE_LAYER_GKI | TRACE_ORG_GKI , TRACE_TYPE_GENERIC, diff --git a/stack/rfcomm/rfc_l2cap_if.c b/stack/rfcomm/rfc_l2cap_if.c index 9c11d060a..3207a0345 100644 --- a/stack/rfcomm/rfc_l2cap_if.c +++ b/stack/rfcomm/rfc_l2cap_if.c @@ -105,7 +105,7 @@ void RFCOMM_ConnectInd (BD_ADDR bd_addr, UINT16 lcid, UINT16 psm, UINT8 id) RFCOMM_TRACE_DEBUG ("RFCOMM_ConnectInd start timer for collision, initiator's LCID(0x%x), acceptor's LCID(0x%x)", p_mcb->lcid, p_mcb->pending_lcid); - rfc_timer_start(p_mcb, (UINT16)(GKI_get_tick_count()%10 + 2)); + rfc_timer_start(p_mcb, (UINT16)(GKI_get_os_tick_count()%10 + 2)); return; } else |