Thread (9 messages) 9 messages, 2 authors, 2025-12-10

Re: [PATCH net 2/3] net: hns3: using the num_tqps to check whether tqp_index is out of range when vf get ring info from mbx

From: Simon Horman <horms@kernel.org>
Date: 2025-12-09 16:59:52
Also in: lkml

On Tue, Dec 09, 2025 at 09:38:24PM +0800, Jijie Shao wrote:
From: Jian Shen <shenjian15@huawei.com>

Currently, rss_size = num_tqps / tc_num. If tc_num is 1, then num_tqps
equals rss_size. However, if the tc_num is greater than 1, then rss_size
will be less than num_tqps, causing the tqp_index check for subsequent TCs
using rss_size to always fail.

This patch uses the num_tqps to check whether tqp_index is out of range,
instead of rss_size.

Fixes: 326334aad024 ("net: hns3: add a check for tqp_index in hclge_get_ring_chain_from_mbx()")
Signed-off-by: Jian Shen <shenjian15@huawei.com>
Signed-off-by: Jijie Shao <shaojijie@huawei.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help