mbox series

[0/2] KVM: arm64: Address soft lockups due to I-cache CMOs

Message ID 20230920080133.944717-1-oliver.upton@linux.dev (mailing list archive)
Headers show
Series KVM: arm64: Address soft lockups due to I-cache CMOs | expand

Message

Oliver Upton Sept. 20, 2023, 8:01 a.m. UTC
Small series to address the soft lockups that Gavin hits when running
KVM guests w/ hugepages on an Ampere Altra Max machine. While I
absolutely loathe "fixing" the issue of slow I-cache CMOs in this way,
I can't really think of an alternative.

Oliver Upton (2):
  arm64: tlbflush: Rename MAX_TLBI_OPS
  KVM: arm64: Avoid soft lockups due to I-cache maintenance

 arch/arm64/include/asm/kvm_mmu.h  | 37 ++++++++++++++++++++++++++-----
 arch/arm64/include/asm/tlbflush.h |  8 +++----
 2 files changed, 35 insertions(+), 10 deletions(-)


base-commit: ce9ecca0238b140b88f43859b211c9fdfd8e5b70

Comments

Marc Zyngier Sept. 21, 2023, 7:39 a.m. UTC | #1
On Wed, 20 Sep 2023 09:01:31 +0100,
Oliver Upton <oliver.upton@linux.dev> wrote:
> 
> Small series to address the soft lockups that Gavin hits when running
> KVM guests w/ hugepages on an Ampere Altra Max machine. While I
> absolutely loathe "fixing" the issue of slow I-cache CMOs in this way,
> I can't really think of an alternative.

I don't think there is any, unfortunately. I don't think this change
is inherently bad (we should have added something like this a long
while ago), but it scares me that these systems can apparently be
DoS'd from userspace or a guest...

Anyway:

Reviewed-by: Marc Zyngier <maz@kernel.org>

	M.
Oliver Upton Sept. 22, 2023, 5:56 p.m. UTC | #2
On Wed, 20 Sep 2023 08:01:31 +0000, Oliver Upton wrote:
> Small series to address the soft lockups that Gavin hits when running
> KVM guests w/ hugepages on an Ampere Altra Max machine. While I
> absolutely loathe "fixing" the issue of slow I-cache CMOs in this way,
> I can't really think of an alternative.
> 
> Oliver Upton (2):
>   arm64: tlbflush: Rename MAX_TLBI_OPS
>   KVM: arm64: Avoid soft lockups due to I-cache maintenance
> 
> [...]

Applied to kvmarm/next, thanks!

[1/2] arm64: tlbflush: Rename MAX_TLBI_OPS
      https://git.kernel.org/kvmarm/kvmarm/c/ec1c3b9ff160
[2/2] KVM: arm64: Avoid soft lockups due to I-cache maintenance
      https://git.kernel.org/kvmarm/kvmarm/c/909b583f81b5

--
Best,
Oliver