New upstream version 18.05
[deb_dpdk.git] / doc / guides / sample_app_ug / kernel_nic_interface.rst
index 580d06b..fc11099 100644 (file)
@@ -511,11 +511,6 @@ Application may choose to not implement following callbacks:
         int ret;
         struct rte_eth_conf conf;
 
-        if (port_id >= rte_eth_dev_count()) {
-            RTE_LOG(ERR, APP, "Invalid port id %d\n", port_id);
-            return -EINVAL;
-        }
-
         RTE_LOG(INFO, APP, "Change MTU of port %d to %u\n", port_id, new_mtu);
 
         /* Stop specific port */
@@ -559,11 +554,6 @@ Application may choose to not implement following callbacks:
     {
         int ret = 0;
 
-        if (port_id >= rte_eth_dev_count() || port_id >= RTE_MAX_ETHPORTS) {
-            RTE_LOG(ERR, APP, "Invalid port id %d\n", port_id);
-            return -EINVAL;
-        }
-
         RTE_LOG(INFO, APP, "Configure network interface of %d %s\n",
 
         port_id, if_up ? "up" : "down");