[dpdk-dev] [PATCH v2 01/13] ethdev: change promiscuous mode controllers to return errors
Ferruh Yigit
ferruh.yigit at intel.com
Fri Sep 13 17:35:58 CEST 2019
On 9/9/2019 12:58 PM, Andrew Rybchenko wrote:
> From: Ivan Ilchenko <Ivan.Ilchenko at oktetlabs.ru>
>
> Change rte_eth_promiscuous_enable()/rte_eth_promiscuous_disable()
> return value from void to int and return negative errno values
> in case of error conditions.
> Modify usage of these functions across the ethdev according
> to new return type.
>
> Signed-off-by: Ivan Ilchenko <Ivan.Ilchenko at oktetlabs.ru>
> Signed-off-by: Andrew Rybchenko <arybchenko at solarflare.com>
<...>
> diff --git a/doc/guides/sample_app_ug/flow_filtering.rst b/doc/guides/sample_app_ug/flow_filtering.rst
> index 02fc675506..de3e4ab0b6 100644
> --- a/doc/guides/sample_app_ug/flow_filtering.rst
> +++ b/doc/guides/sample_app_ug/flow_filtering.rst
> @@ -193,7 +193,13 @@ application is shown below:
> }
> }
>
> - rte_eth_promiscuous_enable(port_id);
> + ret = rte_eth_promiscuous_enable(port_id);
> + if (ret != 0) {
> + rte_exit(EXIT_FAILURE,
> + ":: cannot enable promiscuous mode: err=%d, port=%u\n",
> + ret, port_id);
> + }
> +
Not for this patch, for future, I am for not putting code into the documents...
More information about the dev
mailing list