octeontx2-pf: Add check for devm_kcalloc
authorJiasheng Jiang <jiasheng@iscas.ac.cn>
Tue, 22 Nov 2022 05:54:49 +0000 (13:54 +0800)
committerPaolo Abeni <pabeni@redhat.com>
Thu, 24 Nov 2022 07:34:45 +0000 (08:34 +0100)
commitcd07eadd5147ffdae11b6fd28b77a3872f2a2484
tree9b386480c67e1e1cf185147b806f25ae87b281f3
parent290b5fe096e7dd0aad730d1af4f7f2d9fea43e11
octeontx2-pf: Add check for devm_kcalloc

As the devm_kcalloc may return NULL pointer,
it should be better to add check for the return
value, as same as the others.

Fixes: e8e095b3b370 ("octeontx2-af: cn10k: Bandwidth profiles config support")
Signed-off-by: Jiasheng Jiang <jiasheng@iscas.ac.cn>
Reviewed-by: Maciej Fijalkowski <maciej.fijalkowski@intel.com>
Link: https://lore.kernel.org/r/20221122055449.31247-1-jiasheng@iscas.ac.cn
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c