]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/64s: Machine check handle ifetch from foreign real address for POWER9
authorNicholas Piggin <npiggin@gmail.com>
Mon, 29 May 2017 06:26:44 +0000 (16:26 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 6 Jun 2017 11:17:15 +0000 (21:17 +1000)
commit4a037917120d5fc6d45c18376ef477d9410db23c
tree03452ca88f703bb7423a27a98ec08c3b95f9aad6
parente9643a492d7d2e28f6acbc2b3fc3ca7513662af3
powerpc/64s: Machine check handle ifetch from foreign real address for POWER9

The i-side 0111b machine check, which is "Instruction Fetch to foreign
address space", was missed by 3877610a43 ("powerpc/64s: POWER9 machine
check handler").

    The POWER9 processor core considers host real addresses with a
    nonzero value in RA(8:12) as foreign address space, accessible only
    by the copy and paste instructions. The copy and paste instruction
    pair can be used to invoke the Nest accelerators via the Virtual
    Accelerator Switchboard (VAS).

It is an error for any regular load/store or ifetch to go to a foreign
addresses. When relocation is on, this causes an MMU exception. When
relocation is off, a machine check exception. It is possible to trigger
this machine check by branching to a foreign address with MSR[IR]=0.

Fixes: 3877610a434b ("powerpc/64s: POWER9 machine check handler")
Reported-by: Mahesh Salgaonkar <mahesh@linux.vnet.ibm.com>
Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/include/asm/mce.h
arch/powerpc/kernel/mce.c
arch/powerpc/kernel/mce_power.c