net: hns3: store rx VLAN tag offload state for VF
authorJian Shen <shenjian15@huawei.com>
Wed, 30 Apr 2025 09:30:49 +0000 (17:30 +0800)
committerJakub Kicinski <kuba@kernel.org>
Thu, 1 May 2025 14:19:47 +0000 (07:19 -0700)
commitef2383d078edcbe3055032436b16cdf206f26de2
tree15584103778cafeeeab1c0605c0dfc7e3ee66062
parentc60e7877d00af3aeda5708bfac38cd43ceead3d0
net: hns3: store rx VLAN tag offload state for VF

The VF driver missed to store the rx VLAN tag strip state when
user change the rx VLAN tag offload state. And it will default
to enable the rx vlan tag strip when re-init VF device after
reset. So if user disable rx VLAN tag offload, and trig reset,
then the HW will still strip the VLAN tag from packet nad fill
into RX BD, but the VF driver will ignore it for rx VLAN tag
offload disabled. It may cause the rx VLAN tag dropped.

Fixes: b2641e2ad456 ("net: hns3: Add support of hardware rx-vlan-offload to HNS3 VF driver")
Signed-off-by: Jian Shen <shenjian15@huawei.com>
Signed-off-by: Jijie Shao <shaojijie@huawei.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/20250430093052.2400464-2-shaojijie@huawei.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.c
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_main.h