]> git.baikalelectronics.ru Git - kernel.git/commit
net: hns3: fix misuse vf id and vport id in some logs
authorJiaran Zhang <zhangjiaran@huawei.com>
Wed, 15 Sep 2021 13:52:08 +0000 (21:52 +0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 20 Sep 2021 12:28:39 +0000 (13:28 +0100)
commit070af49b60ce61d7d934063d646a0109f1b838b9
treedea5a5eb032135f8419694854eb108cc62392bc1
parent32405ae1ada853595d73e760d60ccfd5e0ed6717
net: hns3: fix misuse vf id and vport id in some logs

vport_id include PF and VFs, vport_id = 0 means PF, other values mean VFs.
So the actual vf id is equal to vport_id minus 1.

Some VF print logs are actually vport, and logs of vf id actually use
vport id, so this patch fixes them.

Fixes: d2b36c04638e ("net: hns3: change print level of RAS error log from warning to error")
Fixes: d143a4dedad4 ("net: hns3: cleanup some print format warning")
Signed-off-by: Jiaran Zhang <zhangjiaran@huawei.com>
Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_err.c
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_main.c
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_mbx.c
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_tm.c