Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-07-04 Thread Ananyev, Konstantin
> > On Fri, Jul 3, 2020 at 6:40 PM Ananyev, Konstantin > wrote: > > what are the advantages of current approach (forbid MP support on the fly) > > over explicit start-up parameters (either --proc-type=single or > > --lcore-allow=...)? > > Why do you think it is a better one? > > I don't want t

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-07-04 Thread David Marchand
On Fri, Jul 3, 2020 at 6:40 PM Ananyev, Konstantin wrote: > what are the advantages of current approach (forbid MP support on the fly) > over explicit start-up parameters (either --proc-type=single or > --lcore-allow=...)? > Why do you think it is a better one? I don't want to perpetuate the "pl

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-07-03 Thread Ananyev, Konstantin
> > > If the final users finally hit the situation you describe, it means > > > that the multiprocess had been in use so far and was known to be in > > > use (*hopefully*). > > > > Yes. > > > > > So is it not a problem of design/non-regression testing when > > > integrating the new API in the fir

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-07-03 Thread Thomas Monjalon
02/07/2020 15:06, David Marchand: > On Wed, Jul 1, 2020 at 1:58 PM Ananyev, Konstantin > wrote: > > > If the final users finally hit the situation you describe, it means > > > that the multiprocess had been in use so far and was known to be in > > > use (*hopefully*). > > > > Yes. > > > > > So is

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-07-02 Thread David Marchand
On Wed, Jul 1, 2020 at 1:58 PM Ananyev, Konstantin wrote: > > If the final users finally hit the situation you describe, it means > > that the multiprocess had been in use so far and was known to be in > > use (*hopefully*). > > Yes. > > > So is it not a problem of design/non-regression testing wh

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-07-01 Thread Ananyev, Konstantin
> > On Tue, Jun 30, 2020 at 8:57 PM Ananyev, Konstantin > wrote: > > Imagine the situation - there is a primary proc (supposed to run forever) > > that does rte_thread_register/rte_thread_unregister during its lifetime. > > Plus from time to time user runs some secondary process to collect > >

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-07-01 Thread David Marchand
On Tue, Jun 30, 2020 at 8:57 PM Ananyev, Konstantin wrote: > Imagine the situation - there is a primary proc (supposed to run forever) > that does rte_thread_register/rte_thread_unregister during its lifetime. > Plus from time to time user runs some secondary process to collect stats/debug > the

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-30 Thread Ananyev, Konstantin
> > On Tue, Jun 30, 2020 at 12:07:32PM +, Ananyev, Konstantin wrote: > > > > > > 26/06/2020 16:43, David Marchand: > > > > On Wed, Jun 24, 2020 at 1:59 PM Ananyev, Konstantin > > > > wrote: > > > > > > > Do you mean - make this new dynamic-lcore API return an error if > > > > > > > callied >

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-30 Thread Ananyev, Konstantin
> 30/06/2020 14:07, Ananyev, Konstantin: > > > 26/06/2020 16:43, David Marchand: > > > > On Wed, Jun 24, 2020 at 1:59 PM Ananyev, Konstantin > > > > wrote: > > > > > > > Do you mean - make this new dynamic-lcore API return an error if > > > > > > > callied > > > > > > > from secondary process

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-30 Thread Thomas Monjalon
30/06/2020 14:44, Olivier Matz: > On Tue, Jun 30, 2020 at 12:07:32PM +, Ananyev, Konstantin wrote: > > I think it is better than nothing, but probably not the best one. > > Apart from possible non-consistent behaviour, it is quite restrictive: > > dynamic lcore_id wouldn't be available on any D

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-30 Thread Thomas Monjalon
30/06/2020 14:07, Ananyev, Konstantin: > > 26/06/2020 16:43, David Marchand: > > > On Wed, Jun 24, 2020 at 1:59 PM Ananyev, Konstantin > > > wrote: > > > > > > Do you mean - make this new dynamic-lcore API return an error if > > > > > > callied > > > > > > from secondary process? > > > > > > > >

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-30 Thread Olivier Matz
On Tue, Jun 30, 2020 at 12:07:32PM +, Ananyev, Konstantin wrote: > > > > 26/06/2020 16:43, David Marchand: > > > On Wed, Jun 24, 2020 at 1:59 PM Ananyev, Konstantin > > > wrote: > > > > > > Do you mean - make this new dynamic-lcore API return an error if > > > > > > callied > > > > > > from

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-30 Thread Ananyev, Konstantin
> > 26/06/2020 16:43, David Marchand: > > On Wed, Jun 24, 2020 at 1:59 PM Ananyev, Konstantin > > wrote: > > > > > Do you mean - make this new dynamic-lcore API return an error if > > > > > callied > > > > > from secondary process? > > > > > > > > Yes, and prohibiting from attaching a secondary

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-30 Thread Thomas Monjalon
26/06/2020 16:43, David Marchand: > On Wed, Jun 24, 2020 at 1:59 PM Ananyev, Konstantin > wrote: > > > > Do you mean - make this new dynamic-lcore API return an error if callied > > > > from secondary process? > > > > > > Yes, and prohibiting from attaching a secondary process if dynamic > > > lco

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-26 Thread David Marchand
On Wed, Jun 24, 2020 at 1:59 PM Ananyev, Konstantin wrote: > > > Do you mean - make this new dynamic-lcore API return an error if callied > > > from secondary process? > > > > > > > Yes, and prohibiting from attaching a secondary process if dynamic > > lcore API has been used in primary. > > I int

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-24 Thread Ananyev, Konstantin
> > On Wed, Jun 24, 2020 at 12:40 PM Ananyev, Konstantin > wrote: > > > Supporting lcore allocation in MP requires exchanges between > > > primary/secondary processes like what we have for memory allocations. > > > It will be quite a beast to get to work fine, while not even knowing > > > if peo

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-24 Thread David Marchand
On Wed, Jun 24, 2020 at 12:40 PM Ananyev, Konstantin wrote: > > Supporting lcore allocation in MP requires exchanges between > > primary/secondary processes like what we have for memory allocations. > > It will be quite a beast to get to work fine, while not even knowing > > if people actually wan

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-24 Thread Ananyev, Konstantin
> > 24/06/2020 11:56, Bruce Richardson: > > On Wed, Jun 24, 2020 at 11:23:55AM +0200, David Marchand wrote: > > > On Tue, Jun 23, 2020 at 3:16 PM Ananyev, Konstantin > > > wrote: > > > > > Even before this series, MP has no protection on lcore placing between > > > > > primary and secondary proce

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-24 Thread Ananyev, Konstantin
n > ; Mcnamara, John > ; Kovacevic, Marko ; > Burakov, Anatoly ; Olivier > Matz ; Andrew Rybchenko ; > Neil Horman > Subject: Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores > > On Tue, Jun 23, 2020 at 3:16 PM Ananyev, Konstantin > wrote: > &

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-24 Thread Thomas Monjalon
24/06/2020 11:56, Bruce Richardson: > On Wed, Jun 24, 2020 at 11:23:55AM +0200, David Marchand wrote: > > On Tue, Jun 23, 2020 at 3:16 PM Ananyev, Konstantin > > wrote: > > > > Even before this series, MP has no protection on lcore placing between > > > > primary and secondary processes. > > > > >

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-24 Thread Bruce Richardson
On Wed, Jun 24, 2020 at 11:23:55AM +0200, David Marchand wrote: > On Tue, Jun 23, 2020 at 3:16 PM Ananyev, Konstantin > wrote: > > > Even before this series, MP has no protection on lcore placing between > > > primary and secondary processes. > > > > Agree, it is not a new problem, it has been the

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-24 Thread David Marchand
On Tue, Jun 23, 2020 at 3:16 PM Ananyev, Konstantin wrote: > > Even before this series, MP has no protection on lcore placing between > > primary and secondary processes. > > Agree, it is not a new problem, it has been there for a while. > Though making lcore assignment dynamic will make it more n

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-23 Thread Andrew Rybchenko
On 6/22/20 4:25 PM, David Marchand wrote: > DPDK allows calling some part of its API from a non-EAL thread but this > has some limitations. > OVS (and other applications) has its own thread management but still > want to avoid such limitations by hacking RTE_PER_LCORE(_lcore_id) and > faking EAL th

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-23 Thread Ananyev, Konstantin
Hi David, > > > diff --git a/lib/librte_eal/common/eal_common_lcore.c > > > b/lib/librte_eal/common/eal_common_lcore.c > > > index 86d32a3dd7..7db05428e7 100644 > > > --- a/lib/librte_eal/common/eal_common_lcore.c > > > +++ b/lib/librte_eal/common/eal_common_lcore.c > > > @@ -220,3 +221,38 @@ rte

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-23 Thread David Marchand
On Tue, Jun 23, 2020 at 11:14 AM Bruce Richardson wrote: > > On Tue, Jun 23, 2020 at 09:49:18AM +0200, David Marchand wrote: > > Hello Konstantin, > > > > On Mon, Jun 22, 2020 at 5:49 PM Ananyev, Konstantin > > wrote: > > > > diff --git a/lib/librte_eal/common/eal_common_lcore.c > > > > b/lib/li

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-23 Thread Bruce Richardson
On Tue, Jun 23, 2020 at 09:49:18AM +0200, David Marchand wrote: > Hello Konstantin, > > On Mon, Jun 22, 2020 at 5:49 PM Ananyev, Konstantin > wrote: > > > diff --git a/lib/librte_eal/common/eal_common_lcore.c > > > b/lib/librte_eal/common/eal_common_lcore.c > > > index 86d32a3dd7..7db05428e7 100

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-23 Thread David Marchand
Hello Konstantin, On Mon, Jun 22, 2020 at 5:49 PM Ananyev, Konstantin wrote: > > diff --git a/lib/librte_eal/common/eal_common_lcore.c > > b/lib/librte_eal/common/eal_common_lcore.c > > index 86d32a3dd7..7db05428e7 100644 > > --- a/lib/librte_eal/common/eal_common_lcore.c > > +++ b/lib/librte_ea

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-22 Thread Ananyev, Konstantin
> > Hi David, > > > diff --git a/lib/librte_eal/common/eal_common_lcore.c > > b/lib/librte_eal/common/eal_common_lcore.c > > index 86d32a3dd7..7db05428e7 100644 > > --- a/lib/librte_eal/common/eal_common_lcore.c > > +++ b/lib/librte_eal/common/eal_common_lcore.c > > @@ -6,12 +6,13 @@ > > #inc

Re: [dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-22 Thread Ananyev, Konstantin
Hi David, > diff --git a/lib/librte_eal/common/eal_common_lcore.c > b/lib/librte_eal/common/eal_common_lcore.c > index 86d32a3dd7..7db05428e7 100644 > --- a/lib/librte_eal/common/eal_common_lcore.c > +++ b/lib/librte_eal/common/eal_common_lcore.c > @@ -6,12 +6,13 @@ > #include > #include >

[dpdk-dev] [PATCH v3 6/9] eal: register non-EAL threads as lcores

2020-06-22 Thread David Marchand
DPDK allows calling some part of its API from a non-EAL thread but this has some limitations. OVS (and other applications) has its own thread management but still want to avoid such limitations by hacking RTE_PER_LCORE(_lcore_id) and faking EAL threads potentially unknown of some DPDK component. I