Lines Matching refs:p_ccb
44 tAVCT_CCB *p_ccb = &avct_cb.ccb[0]; in avct_ccb_alloc() local
47 for (i = 0; i < AVCT_NUM_CONN; i++, p_ccb++) in avct_ccb_alloc()
49 if (!p_ccb->allocated) in avct_ccb_alloc()
51 p_ccb->allocated = AVCT_ALOC_LCB; in avct_ccb_alloc()
52 memcpy(&p_ccb->cc, p_cc, sizeof(tAVCT_CC)); in avct_ccb_alloc()
61 p_ccb = NULL; in avct_ccb_alloc()
64 return p_ccb; in avct_ccb_alloc()
78 void avct_ccb_dealloc(tAVCT_CCB *p_ccb, UINT8 event, UINT16 result, BD_ADDR bd_addr) in avct_ccb_dealloc() argument
80 tAVCT_CTRL_CBACK *p_cback = p_ccb->cc.p_ctrl_cback; in avct_ccb_dealloc()
82 AVCT_TRACE_DEBUG1("avct_ccb_dealloc %d", avct_ccb_to_idx(p_ccb)); in avct_ccb_dealloc()
84 if(p_ccb->p_bcb == NULL) in avct_ccb_dealloc()
85 memset(p_ccb, 0, sizeof(tAVCT_CCB)); in avct_ccb_dealloc()
89 avct_bcb_event(p_ccb->p_bcb, AVCT_LCB_UL_UNBIND_EVT, (tAVCT_LCB_EVT *) &p_ccb); in avct_ccb_dealloc()
90 p_ccb->p_lcb = NULL; in avct_ccb_dealloc()
93 memset(p_ccb, 0, sizeof(tAVCT_CCB)); in avct_ccb_dealloc()
98 (*p_cback)(avct_ccb_to_idx(p_ccb), event, result, bd_addr); in avct_ccb_dealloc()
112 UINT8 avct_ccb_to_idx(tAVCT_CCB *p_ccb) in avct_ccb_to_idx() argument
115 return (UINT8) (p_ccb - avct_cb.ccb); in avct_ccb_to_idx()
130 tAVCT_CCB *p_ccb; in avct_ccb_by_idx() local
135 p_ccb = &avct_cb.ccb[idx]; in avct_ccb_by_idx()
138 if (!p_ccb->allocated) in avct_ccb_by_idx()
140 p_ccb = NULL; in avct_ccb_by_idx()
146 p_ccb = NULL; in avct_ccb_by_idx()
149 return p_ccb; in avct_ccb_by_idx()