irqchip/gic-v3-its: Balance initial LPI affinity across CPUs
stable inclusion from stable-v5.8-rc1 commit c5d6082d category: perf bugzilla: https://gitee.com/src-openeuler/kernel/issues/I6UVFG CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=linux-5.10.y&id=c5d6082d35e0bcc20a26a067ffcfddcb5257e580 -------------------------------- When mapping a LPI, the ITS driver picks the first possible affinity, which is in most cases CPU0, assuming that if that's not suitable, someone will come and set the affinity to something more interesting. It apparently isn't the case, and people complain of poor performance when many interrupts are glued to the same CPU. So let's place the interrupts by finding the "least loaded" CPU (that is, the one that has the fewer LPIs mapped to it). So called 'managed' interrupts are an interesting case where the affinity is actually dictated by the kernel itself, and we should honor this. Reported-by:John Garry <john.garry@huawei.com> Signed-off-by:
Marc Zyngier <maz@kernel.org> Tested-by:
John Garry <john.garry@huawei.com> Link: https://lore.kernel.org/r/1575642904-58295-1-git-send-email-john.garry@huawei.com Link: https://lore.kernel.org/r/20200515165752.121296-3-maz@kernel.org Signed-off-by:
Ruan Jinjie <ruanjinjie@huawei.com> Reviewed-by:
Zhang Jianhua <chris.zjh@huawei.com> Signed-off-by:
Zhang Changzhong <zhangchangzhong@huawei.com>
Loading
Please sign in to comment