[dpdk-dev] [PATCH v7 32/42] pipeline: add SWX pipeline specification file

Dumitrescu, Cristian cristian.dumitrescu at intel.com
Sun Oct 4 20:28:58 CEST 2020



> -----Original Message-----
> From: Raslan Darawsheh <rasland at nvidia.com>
> Sent: Sunday, October 4, 2020 8:51 AM
> To: Dumitrescu, Cristian <cristian.dumitrescu at intel.com>; dev at dpdk.org
> Cc: NBU-Contact-Thomas Monjalon <thomas at monjalon.net>;
> david.marchand at redhat.com
> Subject: RE: [dpdk-dev] [PATCH v7 32/42] pipeline: add SWX pipeline
> specification file
> 
> Hi,
> 
> Resending to reply on the correct version,
> 
> > -----Original Message-----
> > From: dev <dev-bounces at dpdk.org> On Behalf Of Cristian Dumitrescu
> > Sent: Wednesday, September 30, 2020 9:34 AM
> > To: dev at dpdk.org
> > Cc: NBU-Contact-Thomas Monjalon <thomas at monjalon.net>;
> > david.marchand at redhat.com
> > Subject: [dpdk-dev] [PATCH v6 32/42] pipeline: add SWX pipeline
> > specification file
> >
> > Add support for building the SWX pipeline based on specification file
> > with syntax aligned to the P4 language. The specification file may be
> > generated by the P4C compiler in the future.
> >
> > Signed-off-by: Cristian Dumitrescu <cristian.dumitrescu at intel.com>
> > ---
> >  lib/librte_pipeline/meson.build              |    1 +
> >  lib/librte_pipeline/rte_pipeline_version.map |    1 +
> >  lib/librte_pipeline/rte_swx_pipeline.h       |   26 +
> >  lib/librte_pipeline/rte_swx_pipeline_spec.c  | 1439
> ++++++++++++++++++
> >  4 files changed, 1467 insertions(+)
> >  create mode 100644 lib/librte_pipeline/rte_swx_pipeline_spec.c
> >
> > diff --git a/lib/librte_pipeline/meson.build
> b/lib/librte_pipeline/meson.build
> > index be1d9c3a4..65c1a8d6a 100644
> > --- a/lib/librte_pipeline/meson.build
> > +++ b/lib/librte_pipeline/meson.build
> 
> Seems like this patch introduced a new failure in compilation as following:
> 
> ./../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c:216:15: error:
> implicit declaration of function 'reallocarray'; did you mean 'realloc'? [-
> Werror=implicit-function-declaration]
>   new_fields = reallocarray(s->fields,
>                ^~~~~~~~~~~~
>                realloc
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c:216:15: error:
> nested extern declaration of 'reallocarray' [-Werror=nested-externs]
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c:216:13: error:
> assignment makes pointer from integer without a cast [-Werror=int-
> conversion]
>   new_fields = reallocarray(s->fields,
>              ^
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c: In function
> 'action_block_parse':
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c:455:19: error:
> assignment makes pointer from integer without a cast [-Werror=int-
> conversion]
>   new_instructions = reallocarray(s->instructions,
>                    ^
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c: In function
> 'table_key_block_parse':
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c:623:13: error:
> assignment makes pointer from integer without a cast [-Werror=int-
> conversion]
>   new_fields = reallocarray(s->params.fields,
>              ^
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c: In function
> 'table_actions_block_parse':
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c:703:19: error:
> assignment makes pointer from integer without a cast [-Werror=int-
> conversion]
>   new_action_names = reallocarray(s->params.action_names,
>                    ^
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c: In function
> 'apply_block_parse':
> ../../root/dpdk/lib/librte_pipeline/rte_swx_pipeline_spec.c:1022:19: error:
> assignment makes pointer from integer without a cast [-Werror=int-
> conversion]
>   new_instructions = reallocarray(s->instructions,
>                    ^
> cc1: all warnings being treated as errors
> [502/2328] Compiling C object
> lib/librte_vhost.a.p/librte_vhost_vhost_crypto.c.o
> ninja: build stopped: subcommand failed.
> 
> This is reproducible in the following environment:
>         ARCH: aarch64
>         CC: gcc
>         OS: Fedora 32 (Container Image)
>         Kernel: 4.4.0-104-generic
>         GCC(aarch64): aarch64-linux-gnu-gcc (Linaro GCC 7.1-2017.08) 7.1.1
> 20170707
> 
> Can you kindly help with providing a fix for it ?
> 
> Kindest regards
> Raslan Darawsheh
> [Raslan Darawsheh]

Hi Raslan,

This issue was already fixed by David's patch [1] which was already applied last Fri. Please update to the latest code and let us know if any issues.

This issue is taking place when glibc version is older than 2.26, i.e. older than 2017.

Regards,
Cristian

[1] http://patches.dpdk.org/patch/79525/



More information about the dev mailing list