]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/powernv: add NULL check after kzalloc
authorChen Zhou <chenzhou10@huawei.com>
Sat, 9 May 2020 02:08:38 +0000 (10:08 +0800)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 20 May 2020 13:39:56 +0000 (23:39 +1000)
commitaf8ecc6615a1dc89132b74a8d201a08f9a3dff78
tree16f9dd517638e98968f9005cc6ee7a39a3b1d349
parent66c47976ef709e41300cbade9de95aac66db847e
powerpc/powernv: add NULL check after kzalloc

Fixes coccicheck warning:

./arch/powerpc/platforms/powernv/opal.c:813:1-5:
alloc with no test, possible model on line 814

Add NULL check after kzalloc.

Signed-off-by: Chen Zhou <chenzhou10@huawei.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200509020838.121660-1-chenzhou10@huawei.com
arch/powerpc/platforms/powernv/opal.c