diff options
author | Marc Zyngier <[email protected]> | 2023-09-27 10:09:10 +0100 |
---|---|---|
committer | Oliver Upton <[email protected]> | 2023-09-30 18:15:44 +0000 |
commit | b5daffb120bb60f974ae1a5589160b05c98e00e5 (patch) | |
tree | a02c55e80db41cfbf3a042730b3ec107827b8f58 /lib/audit.c | |
parent | 54a8006d0b49044d0cb682119686a45de906fe3c (diff) |
KVM: arm64: vgic-v3: Optimize affinity-based SGI injection
Our affinity-based SGI injection code is a bit daft. We iterate
over all the CPUs trying to match the set of affinities that the
guest is trying to reach, leading to some very bad behaviours
if the selected targets are at a high vcpu index.
Instead, we can now use the fact that we have an optimised
MPIDR to vcpu mapping, and only look at the relevant values.
This results in a much faster injection for large VMs, and
in a near constant time, irrespective of the position in the
vcpu index space.
As a bonus, this is mostly deleting a lot of hard-to-read
code. Nobody will complain about that.
Suggested-by: Xu Zhao <[email protected]>
Tested-by: Joey Gouly <[email protected]>
Tested-by: Shameer Kolothum <[email protected]>
Reviewed-by: Zenghui Yu <[email protected]>
Signed-off-by: Marc Zyngier <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Oliver Upton <[email protected]>
Diffstat (limited to 'lib/audit.c')
0 files changed, 0 insertions, 0 deletions