Lets say the device tx ring is full and you do a normal C non blocking write(fd, buff) to enqueue data in the TCP SND buffer.
What happens when this fails? In UDP - the packet would be dropped but what happens in TCP?
Here is the context:
I have a tester which sends data to a bunch of TCP sockets sequentially in non blocking. It sends enough data to fill the SND BUFF.
The condition I am testing for is one where after filling the SND BUFF; I will not receive a OPS_WRITE event from the non blocking poll for several seconds for a handful out of 500 connections. It happens, sometimes up to 2-3 seconds I will get nada from poll.
I increased my TX RING from 512 to 2048 and now it never happens unless the nic is at capacity for 10 seconds or more.