From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 0C04E45B37; Mon, 14 Oct 2024 13:03:38 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id E076C40678; Mon, 14 Oct 2024 13:03:08 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.16]) by mails.dpdk.org (Postfix) with ESMTP id 432AF4065E for ; Mon, 14 Oct 2024 13:03:03 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1728903784; x=1760439784; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=DM1bs1wpWFmaA4ZxrrUoJvi/27SIRrK4MGvmfaL9ZB0=; b=IG/x5dKp1w2n9EEITB4vFGR2gJiF/p46OftWx5myyoJRbyBVVNn7t6BB A2JmH+lh2vyk+j0PkXBIZknpFAaEaBgstXh5yrVmtz2lYGru3ItZGP6H0 i8huUGcE4rBj+3GvuKDiF69PpU+NDaK0nmNJhUDEJ08HqWSXKoVkukuKS Qhvizf947ZsWCfgBuz3KY1APPazqTa87Ha39LIrbBK4f56H8PTD2I2Pmx 72h5NBrcLAkDkrpHWzA2IdKBsVSwwUqovYyf5gMP9e+MBX52c+Udkv2t4 YjgWV4E1/IE4InvAHsfLtXLkJpC7BW5JSMEHPaE8VIH/Sf1B/ThmMBG9a A==; X-CSE-ConnectionGUID: Z7D9W/xbTY2cGlP3NASbPA== X-CSE-MsgGUID: HfCagNI/Ska/paOJ8FyVpQ== X-IronPort-AV: E=McAfee;i="6700,10204,11222"; a="28340340" X-IronPort-AV: E=Sophos;i="6.11,199,1725346800"; d="scan'208";a="28340340" Received: from fmviesa006.fm.intel.com ([10.60.135.146]) by orvoesa108.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Oct 2024 04:03:03 -0700 X-CSE-ConnectionGUID: gRH7uWcpTGi2LctSVZxz4w== X-CSE-MsgGUID: yD4poYNhSy2tuF6xJorlOA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.11,202,1725346800"; d="scan'208";a="77167118" Received: from unknown (HELO silpixa00401385.ir.intel.com) ([10.237.214.25]) by fmviesa006.fm.intel.com with ESMTP; 14 Oct 2024 04:03:01 -0700 From: Bruce Richardson To: dev@dpdk.org Cc: Bruce Richardson Subject: [PATCH v2 05/10] net/ice/base: set VSI index on newly created nodes Date: Mon, 14 Oct 2024 12:02:09 +0100 Message-ID: <20241014110250.2314727-6-bruce.richardson@intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20241014110250.2314727-1-bruce.richardson@intel.com> References: <20241011164459.1987538-1-bruce.richardson@intel.com> <20241014110250.2314727-1-bruce.richardson@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org The ice_sched_node type has got a field for the vsi to which the node belongs. This field was not getting set in "ice_sched_add_node", so add a line configuring this field for each node from its parent node. Similarly, when searching for a qgroup node, we can check for each node that the VSI information is correct. Signed-off-by: Bruce Richardson --- drivers/net/ice/base/ice_sched.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/net/ice/base/ice_sched.c b/drivers/net/ice/base/ice_sched.c index 1d6dd2af82..45934f9152 100644 --- a/drivers/net/ice/base/ice_sched.c +++ b/drivers/net/ice/base/ice_sched.c @@ -200,6 +200,7 @@ ice_sched_add_node(struct ice_port_info *pi, u8 layer, node->in_use = true; node->parent = parent; node->tx_sched_layer = layer; + node->vsi_handle = parent->vsi_handle; parent->children[parent->num_children++] = node; node->info = elem; return 0; @@ -1575,7 +1576,7 @@ ice_sched_get_free_qparent(struct ice_port_info *pi, u16 vsi_handle, u8 tc, /* make sure the qgroup node is part of the VSI subtree */ if (ice_sched_find_node_in_subtree(pi->hw, vsi_node, qgrp_node)) if (qgrp_node->num_children < max_children && - qgrp_node->owner == owner) + qgrp_node->owner == owner && qgrp_node->vsi_handle == vsi_handle) break; qgrp_node = qgrp_node->sibling; } -- 2.43.0