net/i40e: fix TM hierarchy commit check
authorWenzhuo Lu <wenzhuo.lu@intel.com>
Wed, 26 Jul 2017 14:43:39 +0000 (22:43 +0800)
committerThomas Monjalon <thomas@monjalon.net>
Mon, 31 Jul 2017 17:16:23 +0000 (19:16 +0200)
If there's no Traffic Management node added. Not
necessary to check if TM is committed.

Fixes: cac29c3c00a4 ("net/i40e: support committing TM hierarchy")

Signed-off-by: Wenzhuo Lu <wenzhuo.lu@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
drivers/net/i40e/i40e_ethdev.c

index 9fcccda..042bcc1 100644 (file)
@@ -2033,7 +2033,7 @@ i40e_dev_start(struct rte_eth_dev *dev)
 
        i40e_filter_restore(pf);
 
-       if (!pf->tm_conf.committed)
+       if (pf->tm_conf.root && !pf->tm_conf.committed)
                PMD_DRV_LOG(WARNING,
                            "please call hierarchy_commit() "
                            "before starting the port");