MCPcopy Create free account
hub / github.com/F-Stack/f-stack / sfc_ev_qpoll

Function sfc_ev_qpoll

dpdk/drivers/net/sfc/sfc_ev.c:570–626  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

568
569
570void
571sfc_ev_qpoll(struct sfc_evq *evq)
572{
573 struct sfc_adapter *sa;
574
575 SFC_ASSERT(evq->init_state == SFC_EVQ_STARTED ||
576 evq->init_state == SFC_EVQ_STARTING);
577
578 /* Synchronize the DMA memory for reading not required */
579
580 efx_ev_qpoll(evq->common, &evq->read_ptr, evq->callbacks, evq);
581
582 sa = evq->sa;
583 if (unlikely(evq->exception) && sfc_adapter_trylock(sa)) {
584 int rc;
585
586 if (evq->dp_rxq != NULL) {
587 sfc_sw_index_t rxq_sw_index;
588
589 rxq_sw_index = evq->dp_rxq->dpq.queue_id;
590
591 sfc_warn(sa,
592 "restart RxQ %u because of exception on its EvQ %u",
593 rxq_sw_index, evq->evq_index);
594
595 sfc_rx_qstop(sa, rxq_sw_index);
596 rc = sfc_rx_qstart(sa, rxq_sw_index);
597 if (rc != 0)
598 sfc_err(sa, "cannot restart RxQ %u",
599 rxq_sw_index);
600 }
601
602 if (evq->dp_txq != NULL) {
603 sfc_sw_index_t txq_sw_index;
604
605 txq_sw_index = evq->dp_txq->dpq.queue_id;
606
607 sfc_warn(sa,
608 "restart TxQ %u because of exception on its EvQ %u",
609 txq_sw_index, evq->evq_index);
610
611 sfc_tx_qstop(sa, txq_sw_index);
612 rc = sfc_tx_qstart(sa, txq_sw_index);
613 if (rc != 0)
614 sfc_err(sa, "cannot restart TxQ %u",
615 txq_sw_index);
616 }
617
618 if (evq->exception)
619 sfc_panic(sa, "unrecoverable exception on EvQ %u",
620 evq->evq_index);
621
622 sfc_adapter_unlock(sa);
623 }
624
625 /* Poll-mode driver does not re-prime the event queue for interrupts */
626}
627

Callers 10

sfc_ev_mgmt_qpollFunction · 0.85
sfc_ev_qstartFunction · 0.85
sfc_tx_qstopFunction · 0.85
sfc_efx_tx_reapFunction · 0.85
sfc_efx_tx_qdesc_statusFunction · 0.85
sfc_efx_recv_pktsFunction · 0.85
sfc_efx_rx_qdesc_statusFunction · 0.85
sfc_rx_qflushFunction · 0.85
sfc_intr_handle_mgmt_evqFunction · 0.85

Calls 5

efx_ev_qpollFunction · 0.85
sfc_rx_qstopFunction · 0.85
sfc_rx_qstartFunction · 0.85
sfc_tx_qstopFunction · 0.85
sfc_tx_qstartFunction · 0.85

Tested by

no test coverage detected