Lines Matching refs:target

71 static A_STATUS htc_process_trailer(HTC_TARGET *target,
150 HTC_TARGET *target = GET_HTC_TARGET_FROM_HANDLE(HTCHandle); in htc_get_num_recv_buffers() local
152 HTC_ENDPOINT *pEndpoint = &target->endpoint[Endpoint]; in htc_get_num_recv_buffers()
156 HTC_PACKET *allocate_htc_packet_container(HTC_TARGET *target) in allocate_htc_packet_container() argument
160 LOCK_HTC_RX(target); in allocate_htc_packet_container()
162 if (!target->pHTCPacketStructPool) { in allocate_htc_packet_container()
163 UNLOCK_HTC_RX(target); in allocate_htc_packet_container()
167 pPacket = target->pHTCPacketStructPool; in allocate_htc_packet_container()
168 target->pHTCPacketStructPool = (HTC_PACKET *) pPacket->ListLink.pNext; in allocate_htc_packet_container()
170 UNLOCK_HTC_RX(target); in allocate_htc_packet_container()
176 void free_htc_packet_container(HTC_TARGET *target, HTC_PACKET *pPacket) in free_htc_packet_container() argument
180 LOCK_HTC_RX(target); in free_htc_packet_container()
181 if (!target->pHTCPacketStructPool) { in free_htc_packet_container()
182 target->pHTCPacketStructPool = pPacket; in free_htc_packet_container()
186 (DL_LIST *) target->pHTCPacketStructPool; in free_htc_packet_container()
187 target->pHTCPacketStructPool = pPacket; in free_htc_packet_container()
190 UNLOCK_HTC_RX(target); in free_htc_packet_container()
194 qdf_nbuf_t rx_sg_to_single_netbuf(HTC_TARGET *target) in rx_sg_to_single_netbuf() argument
202 qdf_nbuf_queue_t *rx_sg_queue = &target->RxSgQueue; in rx_sg_to_single_netbuf()
212 new_skb = qdf_nbuf_alloc(target->ExpRxSgTotalLen, 0, 4, false); in rx_sg_to_single_netbuf()
216 target->ExpRxSgTotalLen)); in rx_sg_to_single_netbuf()
232 RESET_RX_SG_CONFIG(target); in rx_sg_to_single_netbuf()
240 RESET_RX_SG_CONFIG(target); in rx_sg_to_single_netbuf()
250 HTC_TARGET *target = (HTC_TARGET *) Context; in htc_rx_completion_handler() local
264 LOCK_HTC_RX(target); in htc_rx_completion_handler()
265 if (target->IsRxSgInprogress) { in htc_rx_completion_handler()
266 target->CurRxSgTotalLen += qdf_nbuf_len(netbuf); in htc_rx_completion_handler()
267 qdf_nbuf_queue_add(&target->RxSgQueue, netbuf); in htc_rx_completion_handler()
268 if (target->CurRxSgTotalLen == target->ExpRxSgTotalLen) { in htc_rx_completion_handler()
269 netbuf = rx_sg_to_single_netbuf(target); in htc_rx_completion_handler()
271 UNLOCK_HTC_RX(target); in htc_rx_completion_handler()
276 UNLOCK_HTC_RX(target); in htc_rx_completion_handler()
280 UNLOCK_HTC_RX(target); in htc_rx_completion_handler()
310 pEndpoint = &target->endpoint[htc_ep_id]; in htc_rx_completion_handler()
320 currendpoint = &target->endpoint[i]; in htc_rx_completion_handler()
334 LOCK_HTC_RX(target); in htc_rx_completion_handler()
335 target->IsRxSgInprogress = true; in htc_rx_completion_handler()
336 qdf_nbuf_queue_init(&target->RxSgQueue); in htc_rx_completion_handler()
337 qdf_nbuf_queue_add(&target->RxSgQueue, netbuf); in htc_rx_completion_handler()
338 target->ExpRxSgTotalLen = (payloadLen + HTC_HDR_LENGTH); in htc_rx_completion_handler()
339 target->CurRxSgTotalLen += netlen; in htc_rx_completion_handler()
340 UNLOCK_HTC_RX(target); in htc_rx_completion_handler()
362 LOCK_HTC_RX(target); in htc_rx_completion_handler()
364 UNLOCK_HTC_RX(target); in htc_rx_completion_handler()
391 temp_status = htc_process_trailer(target, in htc_rx_completion_handler()
427 if (target->CtrlResponseProcessing) { in htc_rx_completion_handler()
439 LOCK_HTC_RX(target); in htc_rx_completion_handler()
440 target->CtrlResponseLength = in htc_rx_completion_handler()
443 qdf_mem_copy(target->CtrlResponseBuffer, in htc_rx_completion_handler()
445 target->CtrlResponseLength); in htc_rx_completion_handler()
448 target->CtrlResponseProcessing = true; in htc_rx_completion_handler()
449 UNLOCK_HTC_RX(target); in htc_rx_completion_handler()
450 qdf_event_set(&target->ctrl_response_valid); in htc_rx_completion_handler()
460 info = &target->HTCInitInfo; in htc_rx_completion_handler()
476 target->HTCInitInfo.TargetSendSuspendComplete( in htc_rx_completion_handler()
477 target->HTCInitInfo.target_psoc, in htc_rx_completion_handler()
490 target->HTCInitInfo.TargetSendSuspendComplete( in htc_rx_completion_handler()
491 target->HTCInitInfo.target_psoc, in htc_rx_completion_handler()
506 pPacket = allocate_htc_packet_container(target); in htc_rx_completion_handler()
523 free_htc_packet_container(target, pPacket); in htc_rx_completion_handler()
543 HTC_TARGET *target = GET_HTC_TARGET_FROM_HANDLE(HTCHandle); in htc_add_receive_pkt_multiple() local
567 pEndpoint = &target->endpoint[pFirstPacket->Endpoint]; in htc_add_receive_pkt_multiple()
569 LOCK_HTC_RX(target); in htc_add_receive_pkt_multiple()
573 if (HTC_STOPPING(target)) { in htc_add_receive_pkt_multiple()
584 UNLOCK_HTC_RX(target); in htc_add_receive_pkt_multiple()
599 void htc_flush_rx_hold_queue(HTC_TARGET *target, HTC_ENDPOINT *pEndpoint) in htc_flush_rx_hold_queue() argument
603 LOCK_HTC_RX(target); in htc_flush_rx_hold_queue()
609 UNLOCK_HTC_RX(target); in htc_flush_rx_hold_queue()
618 LOCK_HTC_RX(target); in htc_flush_rx_hold_queue()
621 UNLOCK_HTC_RX(target); in htc_flush_rx_hold_queue()
624 void htc_recv_init(HTC_TARGET *target) in htc_recv_init() argument
627 qdf_event_create(&target->ctrl_response_valid); in htc_recv_init()
631 QDF_STATUS htc_wait_recv_ctrl_message(HTC_TARGET *target) in htc_wait_recv_ctrl_message() argument
638 if (qdf_wait_single_event(&target->ctrl_response_valid, in htc_wait_recv_ctrl_message()
639 (target->HTCInitInfo.htc_ready_timeout_ms))) { in htc_wait_recv_ctrl_message()
645 LOCK_HTC_RX(target); in htc_wait_recv_ctrl_message()
647 target->CtrlResponseProcessing = true; in htc_wait_recv_ctrl_message()
649 UNLOCK_HTC_RX(target); in htc_wait_recv_ctrl_message()
655 static A_STATUS htc_process_trailer(HTC_TARGET *target, in htc_process_trailer() argument
706 htc_process_credit_rpt(target, in htc_process_trailer()