OSDN Git Service

powerpc/64s/exception: KVM Fix for host DSI being taken in HPT guest MMU context
authorNicholas Piggin <npiggin@gmail.com>
Tue, 17 Nov 2020 13:56:17 +0000 (23:56 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 18 Nov 2020 02:02:05 +0000 (13:02 +1100)
commitcd81acc600a9684ea4b4d25a47900d38a3890eab
tree2ae01066c1301041bfbeae00f10f4590fa011a02
parente02152ba2810f7c88cb54e71cda096268dfa9241
powerpc/64s/exception: KVM Fix for host DSI being taken in HPT guest MMU context

Commit 2284ffea8f0c ("powerpc/64s/exception: Only test KVM in SRR
interrupts when PR KVM is supported") removed KVM guest tests from
interrupts that do not set HV=1, when PR-KVM is not configured.

This is wrong for HV-KVM HPT guest MMIO emulation case which attempts
to load the faulting instruction word with MSR[DR]=1 and MSR[HV]=1 with
the guest MMU context loaded. This can cause host DSI, DSLB interrupts
which must test for KVM guest. Restore this and add a comment.

Fixes: 2284ffea8f0c ("powerpc/64s/exception: Only test KVM in SRR interrupts when PR KVM is supported")
Cc: stable@vger.kernel.org # v5.7+
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20201117135617.3521127-1-npiggin@gmail.com
arch/powerpc/kernel/exceptions-64s.S