Re: [PATCH] MIPS: Loongson: Fix potential NULL dereference in loongson3_platform_init()

From: Paul Burton
Date: Mon Jan 13 2020 - 14:11:09 EST


Hello,

Tiezhu Yang wrote:
> If kzalloc fails, it should return -ENOMEM, otherwise may trigger a NULL
> pointer dereference.

Applied to mips-next.

> commit 72d052e28d1d
> https://git.kernel.org/mips/c/72d052e28d1d
>
> Fixes: 3adeb2566b9b ("MIPS: Loongson: Improve LEFI firmware interface")
> Signed-off-by: Tiezhu Yang <yangtiezhu@xxxxxxxxxxx>
> Signed-off-by: Paul Burton <paulburton@xxxxxxxxxx>

Thanks,
Paul

[ This message was auto-generated; if you believe anything is incorrect
then please email paulburton@xxxxxxxxxx to report it. ]