diff options
author | Hao Lan <lanhao@huawei.com> | 2023-07-20 10:05:08 +0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2023-07-24 09:36:23 +0100 |
commit | 6d2336120aa6e1a8a64fa5d6ee5c3f3d0809fe9b (patch) | |
tree | 3012fed8b81217a6e040bc2472bd258c4e859ebd /drivers/net/ethernet/hisilicon/hns3/hnae3.h | |
parent | b27d0232e8897f7c896dc8ad80c9907dd57fd3f3 (diff) | |
download | lwn-6d2336120aa6e1a8a64fa5d6ee5c3f3d0809fe9b.tar.gz lwn-6d2336120aa6e1a8a64fa5d6ee5c3f3d0809fe9b.zip |
net: hns3: add tm flush when setting tm
When the tm module is configured with traffic, traffic
may be abnormal. This patch fixes this problem.
Before the tm module is configured, traffic processing
should be stopped. After the tm module is configured,
traffic processing is enabled.
Signed-off-by: Hao Lan <lanhao@huawei.com>
Signed-off-by: Jijie Shao <shaojijie@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/hisilicon/hns3/hnae3.h')
-rw-r--r-- | drivers/net/ethernet/hisilicon/hns3/hnae3.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/ethernet/hisilicon/hns3/hnae3.h b/drivers/net/ethernet/hisilicon/hns3/hnae3.h index 7de167329b1e..514a20bce4f4 100644 --- a/drivers/net/ethernet/hisilicon/hns3/hnae3.h +++ b/drivers/net/ethernet/hisilicon/hns3/hnae3.h @@ -102,6 +102,7 @@ enum HNAE3_DEV_CAP_BITS { HNAE3_DEV_SUPPORT_FEC_STATS_B, HNAE3_DEV_SUPPORT_LANE_NUM_B, HNAE3_DEV_SUPPORT_WOL_B, + HNAE3_DEV_SUPPORT_TM_FLUSH_B, }; #define hnae3_ae_dev_fd_supported(ae_dev) \ @@ -173,6 +174,9 @@ enum HNAE3_DEV_CAP_BITS { #define hnae3_ae_dev_wol_supported(ae_dev) \ test_bit(HNAE3_DEV_SUPPORT_WOL_B, (ae_dev)->caps) +#define hnae3_ae_dev_tm_flush_supported(hdev) \ + test_bit(HNAE3_DEV_SUPPORT_TM_FLUSH_B, (hdev)->ae_dev->caps) + enum HNAE3_PF_CAP_BITS { HNAE3_PF_SUPPORT_VLAN_FLTR_MDF_B = 0, }; |