On Thu, Jul 2, 2020 at 10:20 AM Ori Kam <or...@mellanox.com> wrote:

> Hi Stephen,
>
> > -----Original Message-----
> > From: Stephen Hemminger <step...@networkplumber.org>
> > Sent: Thursday, July 2, 2020 3:24 AM
> > To: Andrey Vesnovaty <andrey.vesnov...@gmail.com>
> > Cc: Thomas Monjalon <tho...@monjalon.net>; Ferruh Yigit
> > <ferruh.yi...@intel.com>; Andrew Rybchenko <arybche...@solarflare.com>;
> > Ori Kam <or...@mellanox.com>; dev@dpdk.org; Andrey Vesnovaty
> > <andr...@mellanox.com>
> > Subject: Re: [dpdk-dev] [RFC v2 1/1] add flow shared action API
> >
> > On Sat, 20 Jun 2020 16:32:57 +0300
> > Andrey Vesnovaty <andrey.vesnov...@gmail.com> wrote:
> >
> > > +
> > > +void *
> > > +rte_flow_shared_action_create(uint16_t port_id,
> > > +           const struct rte_flow_action *action,
> > > +           struct rte_flow_error *error)
> > > +{
> >
> > NAK
> >
> > API's that return void * (opaque pointer) are dangerous and should
> > not be added to DPDK.
> >
> > To do data hiding. Define a structure but don't expose the internals
> > of what that structure are.
>
> I'll add `struct rte_flow_shared_action` to upcoming patches. Thanks.


> I agree with you it is better not to use void *
> So I suggest to use new struct rte_action_ctx or something like this. That
> will be implemented differently for each driver just like rte_flow.
> What do you think?
>
> Best,
> Ori
>
>

Reply via email to