From: Wenzhuo Lu Date: Tue, 17 Oct 2017 05:50:40 +0000 (+0800) Subject: net/i40e: fix parent when adding TM node X-Git-Tag: spdx-start~1164 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=49b6b461afa1418c6fc53237447e456a5242d95d;p=dpdk.git net/i40e: fix parent when adding TM node Queue's parent is TC not port. It's wrong to always set the parent to root. Fixes: e0ff4d304ccf ("net/ixgbe: support adding TM node") Cc: stable@dpdk.org Signed-off-by: Wenzhuo Lu Acked-by: Cristian Dumitrescu --- diff --git a/drivers/net/i40e/i40e_tm.c b/drivers/net/i40e/i40e_tm.c index 882bccf219..44316f645e 100644 --- a/drivers/net/i40e/i40e_tm.c +++ b/drivers/net/i40e/i40e_tm.c @@ -621,7 +621,7 @@ i40e_node_add(struct rte_eth_dev *dev, uint32_t node_id, tm_node->priority = priority; tm_node->weight = weight; tm_node->reference_count = 0; - tm_node->parent = pf->tm_conf.root; + tm_node->parent = parent_node; tm_node->shaper_profile = shaper_profile; rte_memcpy(&tm_node->params, params, sizeof(struct rte_tm_node_params));