On Fri, 24 Sep 2021 14:44:45 +0300
Tudor Cornea <tudor.cor...@gmail.com> wrote:

> +Features and Limitations of the af_packet PMD
> +---------------------------------------------
> +
> +Since the following commit, the Linux kernel strips the vlan tag
> +
> +.. code-block:: console
> +
> +    commit bcc6d47903612c3861201cc3a866fb604f26b8b2
> +    Author: Jiri Pirko <jpirko@xxxxxxxxxx>
> +    Date:   Thu Apr 7 19:48:33 2011 +0000
> +
> +     net: vlan: make non-hw-accel rx path similar to hw-accel
> +
> +Running on such a kernel results in receiving untagged frames while using
> +the af_packet PMD. Fortunately, the stripped information is still available
> +for use in ``mbuf->vlan_tci``, and applications could check 
> ``PKT_RX_VLAN_STRIPPED``.
> +
> +However, we currently don't have a way to describe offloads which can't be
> +disabled by PMDs, and this creates an inconsistency with the way applications
> +expect the PMD offloads to work, and requires them to be aware of which
> +underlying driver they use.
> +
> +Since release 21.11 the af_packet PMD will implement support for the
> +``DEV_RX_OFFLOAD_VLAN_STRIP`` offload, and users can control the desired vlan
> +stripping behavior.
> +
> +It's important to note that the default case will change. If previously,
> +the vlan tag was stripped, if the application now requires the same behavior,
> +it will need to configure ``rxmode.offloads`` with 
> ``DEV_RX_OFFLOAD_VLAN_STRIP``.
> +
> +The PMD driver will re-insert the vlan tag transparently to the application
> +if the kernel strips it, as long as the ``DEV_RX_OFFLOAD_VLAN_STRIP`` is not
> +enabled.

This seems like the wrong place for this text.
It is not a new feature, it is a bug fix.

If you want to describe it as an enhancement, the text should be succinct and 
describe
the situation from user point of view. Something like:

    Af_packet PMD now works with VLAN's on Linux

Reply via email to