]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/mce: hookup memory_failure for UE errors
authorBalbir Singh <bsingharora@gmail.com>
Fri, 29 Sep 2017 04:26:55 +0000 (14:26 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Mon, 16 Oct 2017 12:12:02 +0000 (23:12 +1100)
commite2e727090f40ababfdd4d2a6d57f86fdf0b34676
treeb710e2e735d8359e3d7b8a2e6cd82d4ab5647432
parent6ae7c5d8ca3c96c24c86b2f7c00c2f507d354bc0
powerpc/mce: hookup memory_failure for UE errors

If we are in user space and hit a UE error, we now have the
basic infrastructure to walk the page tables and find out
the effective address that was accessed, since the DAR
is not valid.

We use a work_queue content to hookup the bad pfn, any
other context causes problems, since memory_failure itself
can call into schedule() via lru_drain_ bits.

We could probably poison the struct page to avoid a race
between detection and taking corrective action.

Signed-off-by: Balbir Singh <bsingharora@gmail.com>
Reviewed-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/kernel/mce.c