Netdev List
 help / color / mirror / Atom feed
From: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
To: davem@davemloft.net
Cc: Victor Raj <victor.raj@intel.com>,
	netdev@vger.kernel.org, nhorman@redhat.com, sassmann@redhat.com,
	Bruce Allan <bruce.w.allan@intel.com>,
	Anirudh Venkataramanan <anirudh.venkataramanan@intel.com>,
	Andrew Bowers <andrewx.bowers@intel.com>,
	Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Subject: [net-next 03/16] ice: Fix added in VSI supported nodes calc
Date: Mon, 25 Feb 2019 10:42:53 -0800	[thread overview]
Message-ID: <20190225184306.13505-4-jeffrey.t.kirsher@intel.com> (raw)
In-Reply-To: <20190225184306.13505-1-jeffrey.t.kirsher@intel.com>

From: Victor Raj <victor.raj@intel.com>

VSI supported nodes are calculated in order to add the VSI parent or
intermediate nodes to the scheduler tree. If one of the node in below
layers (from VSI layer) has space to add the new VSI or intermediate node
above that layer then it's not required to continue the calculation further
for below layers.

Signed-off-by: Victor Raj <victor.raj@intel.com>
Reviewed-by: Bruce Allan <bruce.w.allan@intel.com>
Signed-off-by: Anirudh Venkataramanan <anirudh.venkataramanan@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
---
 drivers/net/ethernet/intel/ice/ice_sched.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/intel/ice/ice_sched.c b/drivers/net/ethernet/intel/ice/ice_sched.c
index fb38e8be1e2e..81fb7d19c0fd 100644
--- a/drivers/net/ethernet/intel/ice/ice_sched.c
+++ b/drivers/net/ethernet/intel/ice/ice_sched.c
@@ -1344,9 +1344,14 @@ ice_sched_calc_vsi_support_nodes(struct ice_hw *hw,
 				node = node->sibling;
 			}
 
+			/* tree has one intermediate node to add this new VSI.
+			 * So no need to calculate supported nodes for below
+			 * layers.
+			 */
+			if (node)
+				break;
 			/* all the nodes are full, allocate a new one */
-			if (!node)
-				num_nodes[i]++;
+			num_nodes[i]++;
 		}
 }
 
-- 
2.20.1


  parent reply	other threads:[~2019-02-25 18:43 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-25 18:42 [net-next 00/16][pull request] 100GbE Intel Wired LAN Driver Updates 2019-02-22 Jeff Kirsher
2019-02-25 18:42 ` [net-next 01/16] ice: Mark extack argument as __always_unused Jeff Kirsher
2019-02-26  0:36   ` Stephen Hemminger
2019-02-25 18:42 ` [net-next 02/16] ice: Fix the calculation of ICE_MAX_MTU Jeff Kirsher
2019-02-25 18:42 ` Jeff Kirsher [this message]
2019-02-25 18:42 ` [net-next 04/16] ice: sizeof(<type>) should be avoided Jeff Kirsher
2019-02-25 18:42 ` [net-next 05/16] ice: fix stack hogs from struct ice_vsi_ctx structures Jeff Kirsher
2019-02-25 18:42 ` [net-next 06/16] ice: fix ice_remove_rule_internal vsi_list handling Jeff Kirsher
2019-02-25 18:42 ` [net-next 07/16] ice: fix issue where host reboots on unload when iommu=on Jeff Kirsher
2019-02-25 18:42 ` [net-next 08/16] ice: fix numeric overflow warning Jeff Kirsher
2019-02-25 18:42 ` [net-next 09/16] ice: only use the VF for ICE_VSI_VF in ice_vsi_release Jeff Kirsher
2019-02-25 18:43 ` [net-next 10/16] ice: don't spam VFs with link messages Jeff Kirsher
2019-02-25 18:43 ` [net-next 11/16] ice: clear VF ARQLEN register on reset Jeff Kirsher
2019-02-25 18:43 ` [net-next 12/16] ice: flush Tx pipe on disable queue timeout Jeff Kirsher
2019-02-25 18:43 ` [net-next 13/16] ice: check for a leaf node presence Jeff Kirsher
2019-02-25 18:43 ` [net-next 14/16] ice: use absolute vector ID for VFs Jeff Kirsher
2019-02-25 18:43 ` [net-next 15/16] ice: Fix for FC get rx/tx pause params Jeff Kirsher
2019-02-25 18:43 ` [net-next 16/16] ice: fix overlong string, update stats output Jeff Kirsher
2019-02-25 22:14 ` [net-next 00/16][pull request] 100GbE Intel Wired LAN Driver Updates 2019-02-22 David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190225184306.13505-4-jeffrey.t.kirsher@intel.com \
    --to=jeffrey.t.kirsher@intel.com \
    --cc=andrewx.bowers@intel.com \
    --cc=anirudh.venkataramanan@intel.com \
    --cc=bruce.w.allan@intel.com \
    --cc=davem@davemloft.net \
    --cc=netdev@vger.kernel.org \
    --cc=nhorman@redhat.com \
    --cc=sassmann@redhat.com \
    --cc=victor.raj@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox