net/ice: optimize FlexiMD hardware check
The Flexible Metadata #4 and #5 in the Rx Flex Descriptor are defined to
extract the protocol specified fields or its offset. Its function relays
on the DDP package support in hardware.
Optimize to only check the hardware support when the user specifies the
'proto_xtr' devargs. And not require all the types need to be support in
hardware, otherwise if new protocol extraction type is introduced, it is
hard to maintain the compatibility. Just check the type support in need.
And the protocol IDs are 8 bits length, so the uint8_t is the right type
to be used. Also introduce the 'opcode' variable to specify the metadata
extraction type: it can be protocol fields or offset report.
Signed-off-by: Haiyue Wang <haiyue.wang@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>