Re: [PATCH v2] app/testpmd: fix quit testpmd with vfs and pf

2022-06-22 Thread Thomas Monjalon
Adding more about this patch: testpmd is a test application. It allows you to find some issues in some scenarios. It seems you found an issue and you decided to hide it in the test application. That's really wrong! This kind of issue should be solved in the API or in the driver. In this case, I b

Re: [PATCH v2] app/testpmd: fix quit testpmd with vfs and pf

2022-06-22 Thread Thomas Monjalon
Sorry, this patch looks really wrong, I cannot pull it into the main branch. See below for an explanation. 21/06/2022 12:43, Ferruh Yigit: > On 6/21/2022 10:24 AM, Ke Zhang wrote: > > When testpmd startups with pf and vfs,this error occurs when quitting, > > results in pf is released before vfs ,

Re: [PATCH v2] app/testpmd: fix quit testpmd with vfs and pf

2022-06-21 Thread Ferruh Yigit
On 6/21/2022 10:24 AM, Ke Zhang wrote: When testpmd startups with pf and vfs,this error occurs when quitting, results in pf is released before vfs ,so the vf would access an freed heap memory. The solution is two steps: 1. Fetch the valid port value from RTE_ETH_FOREACH_DEV. 2. free the port in

[PATCH v2] app/testpmd: fix quit testpmd with vfs and pf

2022-06-21 Thread Ke Zhang
When testpmd startups with pf and vfs,this error occurs when quitting, results in pf is released before vfs ,so the vf would access an freed heap memory. The solution is two steps: 1. Fetch the valid port value from RTE_ETH_FOREACH_DEV. 2. free the port in reverse order. Fixes: 08fd782b8454 ("app

Re: [PATCH v2] app/testpmd: fix quit testpmd with vfs and pf

2022-06-21 Thread Ferruh Yigit
On 6/21/2022 10:03 AM, Ke Zhang wrote: When testpmd startups with pf and vfs,this error occurs when quitting, results in pf is released before vfs ,so the vf would access an freed heap memory. The solution is two steps: 1. Fetch the valid port value from RTE_ETH_FOREACH_DEV. 2. free the port in

[PATCH v2] app/testpmd: fix quit testpmd with vfs and pf

2022-06-21 Thread Ke Zhang
When testpmd startups with pf and vfs,this error occurs when quitting, results in pf is released before vfs ,so the vf would access an freed heap memory. The solution is two steps: 1. Fetch the valid port value from RTE_ETH_FOREACH_DEV. 2. free the port in reverse order. Fixes: 08fd782b8454 ("app