powerpc/mm: Prevent unlikely crash in copro_calculate_slb()

Michael Ellerman patch-notifications at ellerman.id.au
Sat Oct 22 09:02:34 AEDT 2016


On Fri, 2016-17-06 at 16:53:28 UTC, Frederic Barrat wrote:
> If a cxl adapter faults on an invalid address for a kernel context, we
> may enter copro_calculate_slb() with a NULL mm pointer (kernel
> context) and an effective address which looks like a user
> address. Which will cause a crash when dereferencing mm. It is clearly
> an AFU bug, but there's no reason to crash either. So return an error,
> so that cxl can ack the interrupt with an address error.
> 
> Signed-off-by: Frederic Barrat <fbarrat at linux.vnet.ibm.com>
> Cc: <stable at vger.kernel.org>
> Acked-by: Ian Munsie <imunsie at au1.ibm.com>

Applied to powerpc fixes, thanks.

https://git.kernel.org/powerpc/c/d2cf909cda5f8c5609cb7ed6cda816

cheers


More information about the Linuxppc-dev mailing list