Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-20 Thread David Marchand
On Mon, Oct 18, 2021 at 10:36 AM Olivier Matz wrote: > > On Mon, Oct 18, 2021 at 10:26:35AM +0200, David Marchand wrote: > > As reported by Dmitry, MEMPOOL_F_POOL_CREATED is a flag only manipulated > > internally. > > This flag is not supposed to be requested from an application and would > > prob

Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-19 Thread Andrew Rybchenko
On 10/19/21 4:42 PM, David Marchand wrote: On Mon, Oct 18, 2021 at 10:37 AM Andrew Rybchenko wrote: diff --git a/lib/mempool/rte_mempool.h b/lib/mempool/rte_mempool.h index 88bcbc51ef..d2bf2843f7 100644 --- a/lib/mempool/rte_mempool.h +++ b/lib/mempool/rte_mempool.h @@ -258,6 +258,15 @@ struct

Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-19 Thread David Marchand
On Mon, Oct 18, 2021 at 10:37 AM Andrew Rybchenko wrote: > > diff --git a/lib/mempool/rte_mempool.h b/lib/mempool/rte_mempool.h > > index 88bcbc51ef..d2bf2843f7 100644 > > --- a/lib/mempool/rte_mempool.h > > +++ b/lib/mempool/rte_mempool.h > > @@ -258,6 +258,15 @@ struct rte_mempool { > > #define

Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-18 Thread Andrew Rybchenko
On 10/18/21 3:06 PM, David Marchand wrote: > On Mon, Oct 18, 2021 at 11:05 AM Andrew Rybchenko > wrote: > +/** > + * This macro lists all the mempool flags an application may request. > + */ > +#define MEMPOOL_VALID_USER_FLAGS (MEMPOOL_F_NO_SPREAD \ I think RTE_ prefix is

Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-18 Thread David Marchand
On Mon, Oct 18, 2021 at 11:05 AM Andrew Rybchenko wrote: > >>> +/** > >>> + * This macro lists all the mempool flags an application may request. > >>> + */ > >>> +#define MEMPOOL_VALID_USER_FLAGS (MEMPOOL_F_NO_SPREAD \ > >> > >> I think RTE_ prefix is missing here since it is in a public > >> head

Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-18 Thread Andrew Rybchenko
On 10/18/21 11:58 AM, Olivier Matz wrote: > On Mon, Oct 18, 2021 at 11:37:32AM +0300, Andrew Rybchenko wrote: >> On 10/18/21 11:26 AM, David Marchand wrote: >>> As reported by Dmitry, MEMPOOL_F_POOL_CREATED is a flag only manipulated >>> internally. >>> This flag is not supposed to be requested fro

Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-18 Thread Olivier Matz
On Mon, Oct 18, 2021 at 11:37:32AM +0300, Andrew Rybchenko wrote: > On 10/18/21 11:26 AM, David Marchand wrote: > > As reported by Dmitry, MEMPOOL_F_POOL_CREATED is a flag only manipulated > > internally. > > This flag is not supposed to be requested from an application and would > > probably resul

Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-18 Thread Andrew Rybchenko
On 10/18/21 11:26 AM, David Marchand wrote: > As reported by Dmitry, MEMPOOL_F_POOL_CREATED is a flag only manipulated > internally. > This flag is not supposed to be requested from an application and would > probably result in an incorrect behavior if an application did pass it. > > Other interna

Re: [dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-18 Thread Olivier Matz
On Mon, Oct 18, 2021 at 10:26:35AM +0200, David Marchand wrote: > As reported by Dmitry, MEMPOOL_F_POOL_CREATED is a flag only manipulated > internally. > This flag is not supposed to be requested from an application and would > probably result in an incorrect behavior if an application did pass it

[dpdk-dev] [PATCH] mempool: accept user flags only

2021-10-18 Thread David Marchand
As reported by Dmitry, MEMPOOL_F_POOL_CREATED is a flag only manipulated internally. This flag is not supposed to be requested from an application and would probably result in an incorrect behavior if an application did pass it. Other internal flags may be introduced later. Rework the check and e