Hi,
Implement and expose CPU spread API based on the scheduler's
sched_numa_find_closest(). Use it in mlx5 and enic device drivers. This
replaces the binary NUMA preference (local / remote) with an improved one
that minds the actual distances, so that remote NUMAs with short distance
are preferred over farther ones.
This has significant performance implications when using NUMA-aware
memory allocations, improving the throughput and CPU utilization.
Regards,
Tariq
v3:
- Introduce the logic as a common API instead of being mlx5 specific.
- Add implementation to enic device driver.
- Use non-atomic version of __cpumask_clear_cpu.