]> git.droids-corp.org - dpdk.git/commitdiff
net/hns3: fix PTP interrupt logging
authorHuisong Li <lihuisong@huawei.com>
Fri, 24 Jun 2022 08:59:47 +0000 (16:59 +0800)
committerAndrew Rybchenko <andrew.rybchenko@oktetlabs.ru>
Fri, 24 Jun 2022 12:27:35 +0000 (14:27 +0200)
PMD driver will receive a PTP interrupt when receive a PTP packet.
But driver doesn't distinguish it. As a result, many unknown events
are printed when many PTP packets are received on the link. The PTP
interrupt is normal, so this patch doesn't log and ignores it.

Fixes: 38b539d96eb6 ("net/hns3: support IEEE 1588 PTP")
Cc: stable@dpdk.org
Signed-off-by: Huisong Li <lihuisong@huawei.com>
Signed-off-by: Dongdong Liu <liudongdong3@huawei.com>
drivers/net/hns3/hns3_ethdev.c

index b17a3e8669bcd5d0d3d4bed19c0d858ef1c3df59..e84cf51d07b9102e38340e943055ddd2235cf4fb 100644 (file)
@@ -317,7 +317,7 @@ hns3_interrupt_handler(void *param)
                hns3_schedule_reset(hns);
        } else if (event_cause == HNS3_VECTOR0_EVENT_MBX) {
                hns3_dev_handle_mbx_msg(hw);
-       } else {
+       } else if (event_cause != HNS3_VECTOR0_EVENT_PTP) {
                hns3_warn(hw, "received unknown event: vector0_int_stat:0x%x "
                          "ras_int_stat:0x%x cmdq_int_stat:0x%x",
                          vector0_int, ras_int, cmdq_int);