[dpdk-dev] [PATCH v13 1/7] fib: make lookup function type configurable

David Marchand david.marchand at redhat.com
Thu Oct 22 13:52:48 CEST 2020


On Mon, Oct 19, 2020 at 5:05 PM Vladimir Medvedkin
<vladimir.medvedkin at intel.com> wrote:
>
> Add type argument to dir24_8_get_lookup_fn()
> Now it supports 3 different lookup implementations:
>  RTE_FIB_DIR24_8_SCALAR_MACRO
>  RTE_FIB_DIR24_8_SCALAR_INLINE
>  RTE_FIB_DIR24_8_SCALAR_UNI
>
> Add new rte_fib_set_lookup_fn() - user can change lookup
> function type runtime.
>
> Signed-off-by: Vladimir Medvedkin <vladimir.medvedkin at intel.com>
> Acked-by: Konstantin Ananyev <konstantin.ananyev at intel.com>

We create a fib object with a type: either RTE_FIB_DUMMY or
RTE_FIB_DIR24_8 (separate topic, we probably do not need
RTE_FIB_TYPE_MAX).

This lookup API is dir24_8 specific.
If we won't abstract the lookup selection type, why not change this
API as dir24_8 specific?
I.e. s/rte_fib_set_lookup_fn/rte_fib_dir24_8_set_lookup_fn/g

The same would apply to FIB6 trie implementation.

-- 
David Marchand



More information about the dev mailing list