powerpc/boot: Handle allocation failure in simple_realloc()
[ Upstream commit 69b0194ccec033c208b071e019032c1919c2822d ] simple_malloc() will return NULL when there is not enough memory left. Check pointer 'new' before using it to copy the old data. Signed-off-by:Li zeming <zeming@nfschina.com> [mpe: Reword subject, use change log from Christophe] Signed-off-by:
Michael Ellerman <mpe@ellerman.id.au> Link: https://msgid.link/20221219021816.3012-1-zeming@nfschina.com Signed-off-by:
Sasha Levin <sashal@kernel.org>
Loading
Please register or sign in to comment