Lines Matching +full:per +full:- +full:queue

1 /* SPDX-License-Identifier: (GPL-2.0-only OR BSD-3-Clause) */
13 /* Size of device headers per Tx packet */
16 /* Number of gather list entries per Tx descriptor */
40 #define FUNETH_CQE_INFO_OFFSET (FUNETH_CQE_SIZE - sizeof(struct fun_cqe_info))
55 /* Per packet tailroom. Present only for 1-frag packets. */
58 /* Per packet headroom for XDP. Preferred over XDP_PACKET_HEADROOM to
59 * accommodate two packets per buffer for 4K pages and 1500B MTUs.
63 /* Initialization state of a queue. */
65 FUN_QSTATE_DESTROYED, /* what queue? */
80 struct funeth_txq_stats { /* per Tx queue SW counters */
84 u64 tx_tso; /* # of non-encapsulated TSO super-packets */
85 u64 tx_encap_tso; /* # of encapsulated TSO super-packets */
86 u64 tx_uso; /* # of non-encapsulated UDP LSO super-packets */
88 u64 tx_nstops; /* # of times the queue has stopped */
89 u64 tx_nrestarts; /* # of times the queue has restarted */
93 u64 tx_tls_bytes; /* Tx bytes of HW-handled TLS payload */
98 struct funeth_tx_info { /* per Tx descriptor state */
107 u32 mask; /* queue depth - 1 */
108 u32 hw_qid; /* device ID of the queue */
112 volatile __be64 *hw_wb; /* HW write-back location */
117 u16 qidx; /* queue index within net_device */
127 u8 init_state; /* queue initialization state */
131 struct funeth_rxq_stats { /* per Rx queue SW counters */
148 struct funeth_rxbuf { /* per Rx buffer state */
152 int node; /* page node, or -1 if it is PF_MEMALLOC */
155 struct funeth_rx_cache { /* cache of DMA-mapped previously used buffers */
159 unsigned int mask; /* depth - 1 */
162 /* An Rx queue consists of a CQ and an SQ used to provide Rx buffers. */
171 unsigned int cq_mask; /* CQ depth - 1 */
173 u16 qidx; /* queue index within net_device */
180 unsigned int rq_mask; /* RQ depth - 1 */
183 u8 init_state; /* queue initialization state */
184 u16 headroom; /* per packet headroom */
194 u32 hw_cqid; /* device ID of the queue's CQ */
195 u32 hw_sqid; /* device ID of the queue's SQ */
203 u64_stats_update_begin(&(q)->syncp); \
204 (q)->stats.counter++; \
205 u64_stats_update_end(&(q)->syncp); \
210 seq = u64_stats_fetch_begin(&(q)->syncp); \
211 stats_copy = (q)->stats; \
212 } while (u64_stats_fetch_retry(&(q)->syncp, (seq)))
221 u16 irq_idx; /* index of MSI-X interrupt */
228 /* Return the start address of the idx-th Tx descriptor. */
232 return q->desc + idx * FUNETH_SQE_SIZE; in fun_tx_desc_addr()
237 unsigned int tail = q->prod_cnt & q->mask; in fun_txq_wr_db()
239 writel(tail, q->db); in fun_txq_wr_db()
244 return cpu_to_mem(cpumask_first(&p->affinity_mask)); in fun_irq_node()