Lines Matching refs:p_buf
675 BT_HDR *p_buf) in LLCP_SendUI() argument
700 if (p_buf->len <= llcp_cb.lcb.peer_miu) in LLCP_SendUI()
702 if (p_buf->offset >= LLCP_MIN_OFFSET) in LLCP_SendUI()
704 status = llcp_util_send_ui (ssap, dsap, p_app_cb, p_buf); in LLCP_SendUI()
709 p_buf->offset, LLCP_MIN_OFFSET ); in LLCP_SendUI()
724 GKI_freebuf (p_buf); in LLCP_SendUI()
751 BT_HDR *p_buf; in LLCP_ReadLogicalLinkData() local
767 p_buf = (BT_HDR *) p_app_cb->ui_rx_q.p_first; in LLCP_ReadLogicalLinkData()
768 p_ui_pdu = (UINT8*) (p_buf + 1) + p_buf->offset; in LLCP_ReadLogicalLinkData()
778 p_ui_pdu += p_buf->layer_specific; in LLCP_ReadLogicalLinkData()
781 … if (max_data_len >= (UINT32) (ui_pdu_length - LLCP_PDU_HEADER_SIZE - p_buf->layer_specific)) in LLCP_ReadLogicalLinkData()
784 … *p_data_len = (UINT32) (ui_pdu_length - LLCP_PDU_HEADER_SIZE - p_buf->layer_specific); in LLCP_ReadLogicalLinkData()
787 … p_buf->layer_specific = 0; /* reset offset to read from the first byte of next UI PDU */ in LLCP_ReadLogicalLinkData()
788 p_buf->offset += LLCP_PDU_AGF_LEN_SIZE + ui_pdu_length; in LLCP_ReadLogicalLinkData()
789 p_buf->len -= LLCP_PDU_AGF_LEN_SIZE + ui_pdu_length; in LLCP_ReadLogicalLinkData()
796 p_buf->layer_specific += max_data_len; in LLCP_ReadLogicalLinkData()
802 if (p_buf->len == 0) in LLCP_ReadLogicalLinkData()
805 GKI_freebuf (p_buf); in LLCP_ReadLogicalLinkData()
843 BT_HDR *p_buf; in LLCP_FlushLogicalLinkRxData() local
859 p_buf = (BT_HDR *) p_app_cb->ui_rx_q.p_first; in LLCP_FlushLogicalLinkRxData()
860 p_ui_pdu = (UINT8*) (p_buf + 1) + p_buf->offset; in LLCP_FlushLogicalLinkRxData()
865 … flushed_length += (UINT32) (ui_pdu_length - LLCP_PDU_HEADER_SIZE - p_buf->layer_specific); in LLCP_FlushLogicalLinkRxData()
868 p_buf->layer_specific = 0; /* offset */ in LLCP_FlushLogicalLinkRxData()
869 p_buf->offset += LLCP_PDU_AGF_LEN_SIZE + ui_pdu_length; in LLCP_FlushLogicalLinkRxData()
870 p_buf->len -= LLCP_PDU_AGF_LEN_SIZE + ui_pdu_length; in LLCP_FlushLogicalLinkRxData()
873 if (p_buf->len == 0) in LLCP_FlushLogicalLinkRxData()
876 GKI_freebuf (p_buf); in LLCP_FlushLogicalLinkRxData()
1129 BT_HDR *p_buf) in LLCP_SendData() argument
1141 if (p_dlcb->remote_miu >= p_buf->len) in LLCP_SendData()
1143 if (p_buf->offset >= LLCP_MIN_OFFSET) in LLCP_SendData()
1145 status = llcp_dlsm_execute (p_dlcb, LLCP_DLC_EVENT_API_DATA_REQ, p_buf); in LLCP_SendData()
1150 p_buf->offset, LLCP_MIN_OFFSET ); in LLCP_SendData()
1156 p_buf->len, p_dlcb->remote_miu); in LLCP_SendData()
1166 GKI_freebuf (p_buf); in LLCP_SendData()
1193 BT_HDR *p_buf; in LLCP_ReadDataLinkData() local
1208 p_buf = (BT_HDR *) p_dlcb->i_rx_q.p_first; in LLCP_ReadDataLinkData()
1209 p_i_pdu = (UINT8*) (p_buf + 1) + p_buf->offset; in LLCP_ReadDataLinkData()
1215 p_i_pdu += p_buf->layer_specific; in LLCP_ReadDataLinkData()
1218 if (max_data_len >= (UINT32) (i_pdu_length - p_buf->layer_specific)) in LLCP_ReadDataLinkData()
1221 *p_data_len = (UINT32) (i_pdu_length - p_buf->layer_specific); in LLCP_ReadDataLinkData()
1224 … p_buf->layer_specific = 0; /* reset offset to read from the first byte of next I PDU */ in LLCP_ReadDataLinkData()
1225 p_buf->offset += LLCP_PDU_AGF_LEN_SIZE + i_pdu_length; in LLCP_ReadDataLinkData()
1226 p_buf->len -= LLCP_PDU_AGF_LEN_SIZE + i_pdu_length; in LLCP_ReadDataLinkData()
1233 p_buf->layer_specific += max_data_len; in LLCP_ReadDataLinkData()
1238 if (p_buf->layer_specific == 0) in LLCP_ReadDataLinkData()
1244 if (p_buf->len == 0) in LLCP_ReadDataLinkData()
1247 GKI_freebuf (p_buf); in LLCP_ReadDataLinkData()
1297 BT_HDR *p_buf; in LLCP_FlushDataLinkRxData() local
1312 p_buf = (BT_HDR *) p_dlcb->i_rx_q.p_first; in LLCP_FlushDataLinkRxData()
1313 p_i_pdu = (UINT8*) (p_buf + 1) + p_buf->offset; in LLCP_FlushDataLinkRxData()
1318 flushed_length += (UINT32) (i_pdu_length - p_buf->layer_specific); in LLCP_FlushDataLinkRxData()
1321 p_buf->layer_specific = 0; /* offset */ in LLCP_FlushDataLinkRxData()
1322 p_buf->offset += LLCP_PDU_AGF_LEN_SIZE + i_pdu_length; in LLCP_FlushDataLinkRxData()
1323 p_buf->len -= LLCP_PDU_AGF_LEN_SIZE + i_pdu_length; in LLCP_FlushDataLinkRxData()
1326 if (p_buf->len == 0) in LLCP_FlushDataLinkRxData()
1329 GKI_freebuf (p_buf); in LLCP_FlushDataLinkRxData()