Skip to content

Commit

Permalink
net/iavf: fix VLAN insertion
Browse files Browse the repository at this point in the history
[ upstream commit 0d58caa ]

When the driver tells the VF to insert VLAN tag using the L2TAG2 field,
vector Tx path does not use Tx context descriptor and would cause VLAN tag
inserted into the wrong location.

This commit is to fix issue by using normal Tx path to handle L2TAG2 case.

Fixes: 3aa9573 ("net/iavf: fix VLAN insert")

Signed-off-by: Yiding Zhou <yidingx.zhou@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
  • Loading branch information
yiding-zhou authored and kevintraynor committed Oct 11, 2022
1 parent 301e4cc commit fe9ea36
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions drivers/net/iavf/iavf_rxtx_vec_common.h
Expand Up @@ -250,6 +250,9 @@ iavf_tx_vec_queue_default(struct iavf_tx_queue *txq)
if (txq->offloads & IAVF_TX_NO_VECTOR_FLAGS)
return -1;

if (txq->vlan_flag == IAVF_TX_FLAGS_VLAN_TAG_LOC_L2TAG2)
return -1;

if (txq->offloads & IAVF_TX_VECTOR_OFFLOAD)
return IAVF_VECTOR_OFFLOAD_PATH;

Expand Down

0 comments on commit fe9ea36

Please sign in to comment.