提交 a92e1bb6 编写于 作者: M Maciej Fijalkowski 提交者: Jeff Kirsher

ice: Validate ring existence and its q_vector per VSI

When stopping Tx rings, we use 'i' as an ring array index for looking up
whether the ice_ring exists and have assigned a q_vector. This checks
rings only within a given TC and we need to go through every ring in
VSI. Use 'q_idx' instead.
Signed-off-by: NMaciej Fijalkowski <maciej.fijalkowski@intel.com>
Signed-off-by: NAnirudh Venkataramanan <anirudh.venkataramanan@intel.com>
Tested-by: NAndrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: NJeff Kirsher <jeffrey.t.kirsher@intel.com>
上级 1553f4f7
......@@ -2072,7 +2072,8 @@ ice_vsi_stop_tx_rings(struct ice_vsi *vsi, enum ice_disq_rst_src rst_src,
for (i = 0; i < vsi->tc_cfg.tc_info[tc].qcount_tx; i++) {
u16 v_idx;
if (!rings || !rings[i] || !rings[i]->q_vector) {
if (!rings || !rings[q_idx] ||
!rings[q_idx]->q_vector) {
err = -EINVAL;
goto err_out;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册