public inbox for io-uring@vger.kernel.org
 help / color / mirror / Atom feed
* How to use iouring zcrx with NIC teaming?
@ 2025-09-11  3:46 Chao Shi
  2025-09-15 20:20 ` David Wei
  0 siblings, 1 reply; 3+ messages in thread
From: Chao Shi @ 2025-09-11  3:46 UTC (permalink / raw)
  To: io-uring

Hello,

I'm running into a issue when using iouring zcrx with NIC teaming.  I'm glad if anyone can help.

I wrote a program that uses iouring-zcrx to receive TCP packets. The program works well when only a single net interface is up (by manually `ifconfig down` the other interface). The server uses Broadcom P2100G Dual-Port 100G NIC, and is configured link aggregation with teaming.  Teaming works at L2, i.e. TCP packets (of single or multiple connections) may come from arbitrary port. I'm using kernel 6.16.4.

To illustrate this issue, consider the belowing example:

The server program registered **two** zcrx IFQs (2 data buffers and 2 refill rings), one for each NIC port. It accepts an incoming TCP connection.  The server receives packets from that connection, by submiting RECV_ZC sqes. Here comes the problem.  The field `zcrx_ifq_idx` of sqe is used to specify which IFQ will be used.  However, which IFQ to use is not known before packets are received. If `zcrx_ifq_idx` specifies the wrong IFQ, the kernel will fallback to copying.  In a rare but possible situation, packets of a single TCP connection may received from both ports.

I'm looking forward if anyone can help.  I'm new here, so correct me if I am wrong.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-09-17 14:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-11  3:46 How to use iouring zcrx with NIC teaming? Chao Shi
2025-09-15 20:20 ` David Wei
2025-09-17 14:28   ` 回复:How " 石超

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox