X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=doc%2Fguides%2Fsample_app_ug%2Fskeleton.rst;h=959561716fed48aed1e75527ccfad9614f7f4332;hb=40401c5bcfa1f9709608a7c1b472100a76bbfb52;hp=d3a3712f41bd71868443b72ee1c437f2d6ef84b3;hpb=8728ccf37615904cf23fb8763895b05c9a3c6b0c;p=dpdk.git diff --git a/doc/guides/sample_app_ug/skeleton.rst b/doc/guides/sample_app_ug/skeleton.rst index d3a3712f41..959561716f 100644 --- a/doc/guides/sample_app_ug/skeleton.rst +++ b/doc/guides/sample_app_ug/skeleton.rst @@ -119,7 +119,7 @@ Forwarding application is shown below: int retval; uint16_t q; - if (port >= rte_eth_dev_count()) + if (!rte_eth_dev_is_valid_port(port)) return -1; /* Configure the Ethernet device. */ @@ -192,7 +192,6 @@ looks like the following: static __attribute__((noreturn)) void lcore_main(void) { - const uint16_t nb_ports = rte_eth_dev_count(); uint16_t port; /*