i40e: move check of full Tx ring to outside of send loop
authorMagnus Karlsson <magnus.karlsson@intel.com>
Tue, 23 Jun 2020 09:44:18 +0000 (11:44 +0200)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Wed, 1 Jul 2020 21:31:41 +0000 (14:31 -0700)
commit1fd972ebe5230eb0585642f2172c9dd2b86ea381
tree2abfe20899e8594347c9e5223990be553e94af3f
parent4b5539c01ddf838ea6f5b67d00ee035231c8248a
i40e: move check of full Tx ring to outside of send loop

Move the check if the HW Tx ring is full to outside the send
loop. Currently it is checked for every single descriptor that we
send. Instead, tell the send loop to only process a maximum number of
packets equal to the number of available slots in the Tx ring. This
way, we can remove the check inside the send loop to and gain some
performance.

Suggested-by: Sridhar Samudrala <sridhar.samudrala@intel.com>
Signed-off-by: Magnus Karlsson <magnus.karlsson@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/i40e/i40e_xsk.c