diff options
author | Ming Lei <ming.lei@redhat.com> | 2019-08-16 05:28:48 +0300 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2019-08-27 17:31:17 +0300 |
commit | 53c1788b7d7720565214a466afffdc818d8c6e5f (patch) | |
tree | 01b97c870e8d6dd73c1b3c3b720ec4b54663d0cc /lib/sort.c | |
parent | b6a32bbd8735def2d0d696ba59205d1874b7800f (diff) | |
download | linux-53c1788b7d7720565214a466afffdc818d8c6e5f.tar.xz |
genirq/affinity: Improve __irq_build_affinity_masks()
One invariant of __irq_build_affinity_masks() is that all CPUs in the
specified masks (cpu_mask AND node_to_cpumask for each node) should be
covered during the spread. Even though all requested vectors have been
reached, it's still required to spread vectors among remained CPUs. A
similar policy has been taken in case of 'numvecs <= nodes' already.
So remove the following check inside the loop:
if (done >= numvecs)
break;
Meantime assign at least 1 vector for remaining nodes if 'numvecs' vectors
have been handled already.
Also, if the specified cpumask for one numa node is empty, simply do not
spread vectors on this node.
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/r/20190816022849.14075-2-ming.lei@redhat.com
Diffstat (limited to 'lib/sort.c')
0 files changed, 0 insertions, 0 deletions