mbuf: add function to generate raw Tx offload value
authorKonstantin Ananyev <konstantin.ananyev@intel.com>
Tue, 2 Apr 2019 08:34:36 +0000 (09:34 +0100)
committerAkhil Goyal <akhil.goyal@nxp.com>
Tue, 2 Apr 2019 14:50:24 +0000 (16:50 +0200)
commit8d9c2c3a1f01d58bc70dc0ba95656208ac3d47a4
treeae38038458a7c131ef41aa9637de361fd4600d73
parent27cee41700946e98baf32a474bf819152c4dc54c
mbuf: add function to generate raw Tx offload value

Operations to set/update bit-fields often cause compilers
to generate suboptimal code.
To help avoid such situation for tx_offload fields:
introduce new enum for tx_offload bit-fields lengths and offsets,
and new function to generate raw tx_offload value.
Add new test-case into UT for introduced function.

Signed-off-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
Acked-by: Akhil Goyal <akhil.goyal@nxp.com>
Acked-by: Olivier Matz <olivier.matz@6wind.com>
app/test/test_mbuf.c
lib/librte_mbuf/rte_mbuf.h