net/ena: linearize Tx mbuf
authorRafal Kozik <rk@semihalf.com>
Thu, 7 Jun 2018 09:43:10 +0000 (11:43 +0200)
committerFerruh Yigit <ferruh.yigit@intel.com>
Thu, 14 Jun 2018 17:27:50 +0000 (19:27 +0200)
commit2061fe41f212a804ec76b9afedc12c8c982dc96d
treed653aae2651fe1847be50bc81471b75aeb568d19
parentc2034976673dfac9afc72bf1bcde35989ac909de
net/ena: linearize Tx mbuf

Function ena_check_and_linearize_mbuf check Tx mbuf for number of
segments and linearize (defragment) it if necessary. It is called
before sending each packet.

Information about maximum number of segments is stored per each ring.

Maximum number of segments supported by NIC is taken from ENA COM in
ena_calc_queue_size function and stored in adapter structure.

Signed-off-by: Rafal Kozik <rk@semihalf.com>
Acked-by: Michal Krawczyk <mk@semihalf.com>
drivers/net/ena/ena_ethdev.c
drivers/net/ena/ena_ethdev.h