[dpdk-dev] [RFC] mbuf: new flag when vlan is stripped

John Daley (johndale) johndale at cisco.com
Thu May 12 22:36:36 CEST 2016


Hi Olivier,

> ...
> This is a draft patch that implements what was previously discussed, except
> the packet_type, which does not exist for vlan today (and I think it is not
> mandatory for now, let's do it in another patch).
> 
> After doing this patch, it appeared that ixgbe was the only driver that had a
> different behavior for the PKT_RX_VLAN_PKT flag. An alternative to this
> patch would be to only change the behavior of the ixgbe driver, and just
> document better document the PKT_RX_VLAN_PKT flags in rte_mbuf.h
> without adding new flags. I think this is a better option.
> 
> Comments are welcome.
>
There are applications depending on the current behavior of PKT_RX_VLAN_PKT as confusing as it may be.  I know of one that has VLAN stripping disabled and uses the flag to determine if the packet delivered to the app has a VLAN tag. This is actually how the flag behaves for ixgbe, and they patched enic and maybe other drivers to act accordingly. To avoid breaking the app (and any others like it), I think we should keep the flag behavior the same and add the new flag PKT_RX_VLAN_STRIPPED .

We should follow on with the new packet type since it enables a nice performance improvement by not forcing apps to break open the packet just to see if there is a VLAN tag.

Thanks,
john



More information about the dev mailing list