On Mon, 29 Apr 2024 12:52:25 -0700
Stephen Hemminger <step...@networkplumber.org> wrote:

> Some lcores maybe restricted from being used by DPDK by cgroups.
> This should be detected at startup and only those cpu's allowed
> to be used by the process should be marked as enabled.
> 
> This is a lightly tested patch, and parsing the cpuset info here
> probably needs more checking. It is a response to the problem
> reported with error handling.
> 
> Signed-off-by: Stephen Hemminger <step...@networkplumber.org>

This won't work right because Cpus_allowed reflects the state of the
current affinity mask, which might be reduced for the case of process
spawned by another. It shows up as test failure for when EAL main thread
(with affinity to cpu 0) spawns another process as a test. The test
inherits the affinity of 0 and cpus_allowed is 1 (vs all cpus ff).

Need to find a better way to read the cgroup allowed cpus list
for case where process is running with restricted cpus.

Reply via email to