]> git.karo-electronics.de Git - karo-tx-linux.git/commit
x86/mce: Fix siginfo_t->si_addr value for non-recoverable memory faults
authorTony Luck <tony.luck@intel.com>
Wed, 11 Jul 2012 17:20:47 +0000 (10:20 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 9 Aug 2012 15:22:51 +0000 (08:22 -0700)
commit1a556b7cf880f1bc1edc7d8617c6ac53274e9e02
tree7fb46bb87263ee231467d80f03076d6412650800
parent7d5fdbb9069bbdc679a24cd6ca634c0dc2d66442
x86/mce: Fix siginfo_t->si_addr value for non-recoverable memory faults

commit 6751ed65dc6642af64f7b8a440a75563c8aab7ae upstream.

In commit dad1743e5993f1 ("x86/mce: Only restart instruction after machine
check recovery if it is safe") we fixed mce_notify_process() to force a
signal to the current process if it was not restartable (RIPV bit not
set in MCG_STATUS). But doing it here means that the process doesn't
get told the virtual address of the fault via siginfo_t->si_addr. This
would prevent application level recovery from the fault.

Make a new MF_MUST_KILL flag bit for memory_failure() et al. to use so
that we will provide the right information with the signal.

Signed-off-by: Tony Luck <tony.luck@intel.com>
Acked-by: Borislav Petkov <borislav.petkov@amd.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/x86/kernel/cpu/mcheck/mce.c
include/linux/mm.h
mm/memory-failure.c