OSDN Git Service

net: hns3: fix loop condition of hns3_get_tx_timeo_queue_info()
authorJian Shen <shenjian15@huawei.com>
Fri, 19 Apr 2019 03:05:41 +0000 (11:05 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 27 Jan 2020 13:50:40 +0000 (14:50 +0100)
commit360dd5a7649ff18fc387104959542197cd530dad
treec26f937ee1cf6e3392925d23a2825349300c9a04
parent938251ee1e23e91b51c5d2a2a31601fa487f85d7
net: hns3: fix loop condition of hns3_get_tx_timeo_queue_info()

[ Upstream commit fa6c4084b98b82c98cada0f0d5c9f8577579f962 ]

In function hns3_get_tx_timeo_queue_info(), it should use
netdev->num_tx_queues, instead of netdve->real_num_tx_queues
as the loop limitation.

Fixes: 424eb834a9be ("net: hns3: Unified HNS3 {VF|PF} Ethernet Driver for hip08 SoC")
Signed-off-by: Jian Shen <shenjian15@huawei.com>
Signed-off-by: Peng Li <lipeng321@huawei.com>
Signed-off-by: Huazhong Tan <tanhuazhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/hisilicon/hns3/hns3_enet.c