android_kernel_samsung_sm8650/drivers/clk/microchip
Hui Tang 95e90bcc93 clk: microchip: check for null return of devm_kzalloc()
[ Upstream commit e2e6a217a84d09785848a82599729c9a41566e3a ]

Because of the possible failure of devm_kzalloc(), name might be NULL and
will cause null pointer dereference later.

Therefore, it might be better to check it and directly return -ENOMEM.

Fixes: d39fb17276 ("clk: microchip: add PolarFire SoC fabric clock support")
Signed-off-by: Hui Tang <tanghui20@huawei.com>
Reviewed-by: Conor Dooley <conor.dooley@microchip.com>
[claudiu.beznea: s/refrence/reference/, s/possilble/possible]
Signed-off-by: Claudiu Beznea <claudiu.beznea@microchip.com>
Link: https://lore.kernel.org/r/20221119054858.178629-1-tanghui20@huawei.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-12-31 13:32:15 +01:00
..
clk-core.c clk: let init callback return an error code 2019-12-23 18:53:13 -08:00
clk-core.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 445 2019-06-05 17:37:18 +02:00
clk-mpfs-ccc.c clk: microchip: check for null return of devm_kzalloc() 2022-12-31 13:32:15 +01:00
clk-mpfs.c clk: microchip: mpfs: update module authorship & licencing 2022-09-14 10:57:07 +03:00
clk-pic32mzda.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 445 2019-06-05 17:37:18 +02:00
Kconfig clk: microchip: mpfs: add reset controller 2022-09-14 10:55:17 +03:00
Makefile clk: microchip: add PolarFire SoC fabric clock support 2022-09-14 10:57:07 +03:00