[RFC PATCH 3/3] ethdev: rename parameter in API to get FEC
Denis Pryazhennikov
Denis.Pryazhennikov at arknetworks.am
Thu May 4 09:13:30 CEST 2023
I think my patch isn't correct.
I would say that
- fec_capa is a set of bits produced by 'RTE_ETH_FEC_MODE_TO_CAPA()';
- fec_mode is an element of 'enum rte_eth_fec_mode'.
Based on this definition, replacing 'fec_capa' with 'fec_mode' should
involve changing the parameter type.
Probably I shouldn't change the name, but I should add a more detailed
comment.
> Independent from being single FEC mode or not, I think both
'rte_eth_fec_get()' & 'rte_eth_fec_set()' should get 'fec_mode' as
param, what do you think?
Andrew Rybchenko asked to replace 'mode' with 'fec_capa' for
'rte_eth_fec_set()' in
https://inbox.dpdk.org/dev/aa745bd1-a564-fa8c-c77b-2d99c97690aa@solarflare.com/
I don't think we need to change it for rte_eth_fec_set().
On 5/2/23 7:02 PM, Ferruh Yigit wrote:
> On 4/28/2023 11:27 AM, Denis Pryazhennikov wrote:
>> Only one valid FEC mode can be get by rte_eth_fec_get().
>> The previous name implied that more than one FEC mode
>> can be obtained.
> +1 and patch looks good.
>
> But isn't this valid for 'rte_eth_fec_set()', it gets 'fec_mode'. FEC
> capability has its own type "struct rte_eth_fec_capa".
>
> Independent from being single FEC mode or not, I think both
> 'rte_eth_fec_get()' & 'rte_eth_fec_set()' should get 'fec_mode' as
> param, what do you think?
>
>> Documentation was updated accordingly.
>>
>> Signed-off-by: Denis Pryazhennikov <denis.pryazhennikov at arknetworks.am>
>> Acked-by: Ivan Malov <ivan.malov at arknetworks.am>
>> Acked-by: Viacheslav Galaktionov <viacheslav.galaktionov at arknetworks.am>
> <...>
>
More information about the dev
mailing list