/drivers/thunderbolt/ |
D | tunnel.c | 85 int credits, usb3, pcie, spare; in tb_available_credits() local 99 credits = tb_usable_credits(port); in tb_available_credits() 105 ndp = (credits - (usb3 + pcie + spare)) / in tb_available_credits() 110 credits -= ndp * (sw->min_dp_aux_credits + sw->min_dp_main_credits); in tb_available_credits() 111 credits -= usb3; in tb_available_credits() 116 return credits > 0 ? credits : 0; in tb_available_credits() 160 unsigned int credits; in tb_pci_init_credits() local 166 credits = min(sw->max_pcie_credits, available); in tb_pci_init_credits() 168 if (credits < TB_MIN_PCIE_CREDITS) in tb_pci_init_credits() 171 credits = max(TB_MIN_PCIE_CREDITS, credits); in tb_pci_init_credits() [all …]
|
/drivers/infiniband/sw/rdmavt/ |
D | rc.c | 64 u32 credits; in rvt_compute_aeth() local 68 credits = READ_ONCE(qp->r_rq.kwq->count); in rvt_compute_aeth() 69 if (credits == 0) { in rvt_compute_aeth() 88 credits = rvt_get_rq_count(&qp->r_rq, head, tail); in rvt_compute_aeth() 98 if (credit_table[x] == credits) in rvt_compute_aeth() 100 if (credit_table[x] > credits) { in rvt_compute_aeth()
|
/drivers/net/wireless/ath/ath6kl/ |
D | htc_pipe.c | 130 __func__, credits_required, ep->cred_dist.credits); in get_htc_packet_credit_based() 140 if (ep->cred_dist.credits < credits_required) in get_htc_packet_credit_based() 143 ep->cred_dist.credits -= credits_required; in get_htc_packet_credit_based() 147 if (ep->cred_dist.credits < in get_htc_packet_credit_based() 272 ep->cred_dist.credits += packet->info.tx.cred_used; in htc_issue_packets() 550 int status, credits, credit_per_maxmsg, i; in htc_setup_target_buffer_assignments() local 560 credits = target->tgt_creds; in htc_setup_target_buffer_assignments() 569 __func__, credits); in htc_setup_target_buffer_assignments() 574 entry->credit_alloc = (credits - 6); in htc_setup_target_buffer_assignments() 578 credits -= (int) entry->credit_alloc; in htc_setup_target_buffer_assignments() [all …]
|
D | htc_mbox.c | 42 int credits) in ath6kl_credit_deposit() argument 45 ep_dist->endpoint, credits); in ath6kl_credit_deposit() 47 ep_dist->credits += credits; in ath6kl_credit_deposit() 48 ep_dist->cred_assngd += credits; in ath6kl_credit_deposit() 49 cred_info->cur_free_credits -= credits; in ath6kl_credit_deposit() 138 cur_ep_dist->credits, in ath6kl_credit_init() 170 int credits; in ath6kl_credit_reduce() local 177 if (ep_dist->credits <= limit) in ath6kl_credit_reduce() 180 credits = ep_dist->credits - limit; in ath6kl_credit_reduce() 181 ep_dist->credits -= credits; in ath6kl_credit_reduce() [all …]
|
/drivers/net/ethernet/pensando/ionic/ |
D | ionic_regs.h | 19 u32 credits; member 69 cred = ioread32(&intr_ctrl[intr_idx].credits); in ionic_intr_credits() 73 iowrite32(cred | flags, &intr_ctrl[intr_idx].credits); in ionic_intr_credits() 81 cred = ioread32(&intr_ctrl[intr_idx].credits); in ionic_intr_clean() 84 iowrite32(cred, &intr_ctrl[intr_idx].credits); in ionic_intr_clean()
|
/drivers/net/wireless/ath/ath11k/ |
D | htc.c | 82 int credits = 0; in ath11k_htc_send() local 93 credits = DIV_ROUND_UP(skb->len, htc->target_credit_size); in ath11k_htc_send() 95 if (ep->tx_credits < credits) { in ath11k_htc_send() 98 eid, credits, ep->tx_credits); in ath11k_htc_send() 103 ep->tx_credits -= credits; in ath11k_htc_send() 106 eid, credits, ep->tx_credits); in ath11k_htc_send() 131 ep->tx_credits += credits; in ath11k_htc_send() 134 eid, credits, ep->tx_credits); in ath11k_htc_send() 166 ep->tx_credits += report->credits; in ath11k_htc_process_credit_report() 169 report->eid, report->credits, ep->tx_credits); in ath11k_htc_process_credit_report() [all …]
|
/drivers/scsi/snic/ |
D | vnic_intr.h | 67 unsigned int credits, in svnic_intr_return_credits() argument 74 u32 int_credit_return = (credits & 0xffff) | in svnic_intr_return_credits() 90 unsigned int credits = svnic_intr_credits(intr); in svnic_intr_return_all_credits() local 94 svnic_intr_return_credits(intr, credits, unmask, reset_timer); in svnic_intr_return_all_credits()
|
/drivers/net/ethernet/cisco/enic/ |
D | vnic_intr.h | 70 unsigned int credits, int unmask, int reset_timer) in vnic_intr_return_credits() argument 75 u32 int_credit_return = (credits & 0xffff) | in vnic_intr_return_credits() 89 unsigned int credits = vnic_intr_credits(intr); in vnic_intr_return_all_credits() local 93 vnic_intr_return_credits(intr, credits, unmask, reset_timer); in vnic_intr_return_all_credits()
|
/drivers/scsi/fnic/ |
D | vnic_intr.h | 79 unsigned int credits, int unmask, int reset_timer) in vnic_intr_return_credits() argument 84 u32 int_credit_return = (credits & 0xffff) | in vnic_intr_return_credits() 98 unsigned int credits = vnic_intr_credits(intr); in vnic_intr_return_all_credits() local 102 vnic_intr_return_credits(intr, credits, unmask, reset_timer); in vnic_intr_return_all_credits()
|
/drivers/scsi/csiostor/ |
D | csio_wr.c | 123 int n = flq->credits; in csio_wr_fill_fl() 156 if (unlikely(flq->pidx >= flq->credits)) in csio_wr_update_fl() 157 flq->pidx -= (uint16_t)flq->credits; in csio_wr_update_fl() 261 q->credits = (qsz - q->wr_sz) / q->wr_sz; in csio_wr_alloc_q() 281 flq->un.fl.bufs = kcalloc(flq->credits, in csio_wr_alloc_q() 304 flq->pidx = flq->inc_idx = flq->credits - 8; in csio_wr_alloc_q() 315 q->credits = (qsz - csio_wr_qstat_pgsz(hw)) / CSIO_QCREDIT_SZ; in csio_wr_alloc_q() 320 q->credits = (qsz - csio_wr_qstat_pgsz(hw)) / sizeof(__be64); in csio_wr_alloc_q() 773 for (i = 0; i < q->credits; i++) { in csio_wr_cleanup_iq_ftr() 875 int credits; in csio_wr_get() local [all …]
|
/drivers/net/ethernet/chelsio/cxgb/ |
D | sge.c | 195 unsigned int credits; /* # of available RX buffers */ member 209 unsigned int credits; /* credits to be returned to SGE */ member 435 unsigned int credits) in sched_skb() argument 452 if (credits < MAX_SKB_FRAGS + 1) in sched_skb() 512 while (q->credits--) { in free_freelQ_buffers() 604 sge->respQ.credits = 0; in alloc_rx_resources() 837 while (q->credits < q->size) { in refill_free_list() 867 q->credits++; in refill_free_list() 885 if (sge->freelQ[0].credits > (sge->freelQ[0].size >> 2) && in freelQs_empty() 886 sge->freelQ[1].credits > (sge->freelQ[1].size >> 2)) { in freelQs_empty() [all …]
|
/drivers/infiniband/hw/hfi1/ |
D | trace_ctxts.h | 27 __field(u32, credits) 39 __entry->credits = uctxt->sc->credits; 52 __entry->credits,
|
D | pio.c | 438 sci->credits = scs->size; in init_send_contexts() 561 if (sc->credits <= release_credits) in sc_mtu_to_threshold() 564 threshold = sc->credits - release_credits; in sc_mtu_to_threshold() 578 return (sc->credits * percent) / 100; in sc_percent_to_threshold() 714 sc->credits = sci->credits; in sc_alloc() 715 sc->size = sc->credits * PIO_BLOCK_SIZE; in sc_alloc() 724 reg = ((sci->credits & SC(CTRL_CTXT_DEPTH_MASK)) in sc_alloc() 812 sc->sr_size = sci->credits + 1; in sc_alloc() 828 sc->credits, in sc_alloc() 1427 avail = (unsigned long)sc->credits - (sc->fill - sc->alloc_free); in sc_buffer_alloc() [all …]
|
/drivers/staging/greybus/ |
D | uart.c | 65 unsigned int credits; member 171 gb_tty->credits += incoming_credits; in gb_uart_receive_credits_handler() 172 if (gb_tty->credits > GB_UART_FIRMWARE_CREDITS) { in gb_uart_receive_credits_handler() 173 gb_tty->credits -= incoming_credits; in gb_uart_receive_credits_handler() 193 if (gb_tty->credits == GB_UART_FIRMWARE_CREDITS) in gb_uart_receive_credits_handler() 242 if (send_size > gb_tty->credits) in gb_uart_tx_write_work() 243 send_size = gb_tty->credits; in gb_uart_tx_write_work() 253 gb_tty->credits -= send_size; in gb_uart_tx_write_work() 265 gb_tty->credits += send_size; in gb_uart_tx_write_work() 317 if (gb_tty->credits == GB_UART_FIRMWARE_CREDITS) in gb_uart_wait_for_all_credits() [all …]
|
/drivers/net/ethernet/chelsio/cxgb3/ |
D | sge.c | 192 const struct sge_rspq *q, unsigned int credits) in refill_rspq() argument 196 V_RSPQ(q->cntxt_id) | V_CREDITS(credits)); in refill_rspq() 383 while (q->credits--) { in free_rx_bufs() 486 if (q->pend_cred >= q->credits / 4) { in ring_fl_db() 555 q->credits += count; in refill_fl() 564 refill_fl(adap, fl, min(MAX_RX_REFILL, fl->size - fl->credits), in __refill_fl() 595 q->credits++; in recycle_rx_buf() 789 fl->credits--; in get_packet() 809 if (unlikely(fl->credits < drop_thres) && in get_packet() 810 refill_fl(adap, fl, min(MAX_RX_REFILL, fl->size - fl->credits - 1), in get_packet() [all …]
|
D | cxgb3_ctl_defs.h | 151 unsigned int credits; member 161 unsigned int credits; member
|
/drivers/net/ethernet/mellanox/mlxsw/ |
D | spectrum_acl_tcam.c | 707 int *credits); 714 int credits = MLXSW_SP_ACL_TCAM_VREGION_REHASH_CREDITS; in mlxsw_sp_acl_tcam_vregion_rehash_work() local 716 mlxsw_sp_acl_tcam_vregion_rehash(vregion->mlxsw_sp, vregion, &credits); in mlxsw_sp_acl_tcam_vregion_rehash_work() 717 if (credits < 0) in mlxsw_sp_acl_tcam_vregion_rehash_work() 1198 int *credits) in mlxsw_sp_acl_tcam_ventry_migrate() argument 1206 if (--(*credits) < 0) in mlxsw_sp_acl_tcam_ventry_migrate() 1251 int *credits) in mlxsw_sp_acl_tcam_vchunk_migrate_one() argument 1283 vchunk->chunk, credits); in mlxsw_sp_acl_tcam_vchunk_migrate_one() 1305 } else if (*credits < 0) { in mlxsw_sp_acl_tcam_vchunk_migrate_one() 1323 int *credits) in mlxsw_sp_acl_tcam_vchunk_migrate_all() argument [all …]
|
/drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/ |
D | chcr_ktls.c | 850 int credits; in chcr_ktls_xmit_tcb_cpls() local 858 credits = chcr_txq_avail(&q->q) - ndesc; in chcr_ktls_xmit_tcb_cpls() 859 if (unlikely(credits < 0)) { in chcr_ktls_xmit_tcb_cpls() 864 if (unlikely(credits < ETHTXQ_STOP_THRES)) { in chcr_ktls_xmit_tcb_cpls() 1004 int credits; in chcr_ktls_write_tcp_options() local 1022 credits = chcr_txq_avail(&q->q) - ndesc; in chcr_ktls_write_tcp_options() 1023 if (unlikely(credits < 0)) { in chcr_ktls_write_tcp_options() 1028 if (unlikely(credits < ETHTXQ_STOP_THRES)) { in chcr_ktls_write_tcp_options() 1109 int credits, left, last_desc; in chcr_ktls_xmit_wr_complete() local 1124 credits = chcr_txq_avail(&q->q) - ndesc; in chcr_ktls_xmit_wr_complete() [all …]
|
/drivers/net/wireless/ath/ath10k/ |
D | htc.c | 103 int credits, ret = 0; in ath10k_htc_consume_credit() local 108 credits = DIV_ROUND_UP(len, ep->tx_credit_size); in ath10k_htc_consume_credit() 111 if (ep->tx_credits < credits) { in ath10k_htc_consume_credit() 114 eid, credits, ep->tx_credits, consume); in ath10k_htc_consume_credit() 120 ep->tx_credits -= credits; in ath10k_htc_consume_credit() 123 eid, credits, ep->tx_credits); in ath10k_htc_consume_credit() 136 int credits; in ath10k_htc_release_credit() local 141 credits = DIV_ROUND_UP(len, ep->tx_credit_size); in ath10k_htc_release_credit() 143 ep->tx_credits += credits; in ath10k_htc_release_credit() 146 eid, credits, ep->tx_credits); in ath10k_htc_release_credit() [all …]
|
/drivers/net/wireless/ath/ath9k/ |
D | htc_hst.h | 68 __be16 credits; member 77 u8 credits; member 126 u16 credits; member
|
/drivers/net/ethernet/chelsio/inline_crypto/chtls/ |
D | chtls_io.c | 341 int dlen, int tls_immd, u32 credits, in tls_tx_data_wr() argument 387 FW_TLSTX_DATA_WR_LEN16_V(credits)); in tls_tx_data_wr() 480 int tls_tx_imm, int tls_len, u32 credits) in make_tlstx_data_wr() argument 504 tls_tx_data_wr(sk, skb, tls_len, tls_tx_imm, credits, expn_sz, pdus); in make_tlstx_data_wr() 510 u32 credits, u32 compl) in make_tx_data_wr() argument 525 FW_WR_LEN16_V(credits)); in make_tx_data_wr() 1370 static u32 send_rx_credits(struct chtls_sock *csk, u32 credits) in send_rx_credits() argument 1385 req->credit_dack = cpu_to_be32(RX_CREDITS_V(credits) | in send_rx_credits() 1388 return credits; in send_rx_credits() 1404 u32 credits; in chtls_cleanup_rbuf() local [all …]
|
/drivers/net/ethernet/chelsio/inline_crypto/ch_ipsec/ |
D | chcr_ipsec.c | 554 int credits, in ch_ipsec_crypto_wreq() argument 599 if (unlikely(credits < ETHTXQ_STOP_THRES)) { in ch_ipsec_crypto_wreq() 711 int qidx, left, credits; in ch_ipsec_xmit() local 738 credits = txq_avail(&q->q) - ndesc; in ch_ipsec_xmit() 740 if (unlikely(credits < 0)) { in ch_ipsec_xmit() 744 dev->name, qidx, credits, ndesc, txq_avail(&q->q), in ch_ipsec_xmit() 766 credits, sa_entry); in ch_ipsec_xmit()
|
/drivers/net/wwan/iosm/ |
D | iosm_ipc_mux_codec.c | 616 int credits = 0; in ipc_mux_ul_bytes_credits_check() local 619 credits = session->ul_flow_credits; in ipc_mux_ul_bytes_credits_check() 620 if (credits <= 0) { in ipc_mux_ul_bytes_credits_check() 628 credits = IPC_MEM_MUX_UL_FLOWCTRL_HIGH_B - in ipc_mux_ul_bytes_credits_check() 630 if (credits <= 0) { in ipc_mux_ul_bytes_credits_check() 647 if (!(credits >= skb->len && pkts_to_send < max_nr_of_pkts)) in ipc_mux_ul_bytes_credits_check() 649 credits -= skb->len; in ipc_mux_ul_bytes_credits_check()
|
/drivers/net/ethernet/rocker/ |
D | rocker_main.c | 415 u32 credits) in rocker_dma_ring_credits_set() argument 417 if (credits) in rocker_dma_ring_credits_set() 418 rocker_write32(rocker, DMA_DESC_CREDITS(info->type), credits); in rocker_dma_ring_credits_set() 882 u32 credits = 0; in rocker_cmd_irq_handler() local 892 credits++; in rocker_cmd_irq_handler() 895 rocker_dma_ring_credits_set(rocker, &rocker->cmd_ring, credits); in rocker_cmd_irq_handler() 1002 u32 credits = 0; in rocker_event_irq_handler() local 1018 credits++; in rocker_event_irq_handler() 1020 rocker_dma_ring_credits_set(rocker, &rocker->event_ring, credits); in rocker_event_irq_handler() 2396 u32 credits = 0; in rocker_port_poll_tx() local [all …]
|
/drivers/net/ethernet/chelsio/cxgb4/ |
D | sge.c | 1508 int len, qidx, credits, ret, left; in cxgb4_eth_xmit() local 1564 credits = txq_avail(&q->q) - ndesc; in cxgb4_eth_xmit() 1566 if (unlikely(credits < 0)) { in cxgb4_eth_xmit() 1593 if (unlikely(credits < ETHTXQ_STOP_THRES)) { in cxgb4_eth_xmit() 1834 int qidx, credits, ret; in cxgb4_vf_eth_xmit() local 1869 credits = txq_avail(&txq->q) - ndesc; in cxgb4_vf_eth_xmit() 1871 if (unlikely(credits < 0)) { in cxgb4_vf_eth_xmit() 1903 if (unlikely(credits < ETHTXQ_STOP_THRES)) { in cxgb4_vf_eth_xmit() 2668 int ret, i = 0, pkt_len, credits; in cxgb4_selftest_lb_pkt() local 2688 credits = txq_avail(&q->q) - ndesc; in cxgb4_selftest_lb_pkt() [all …]
|