android_kernel_sony_sdm845/drivers/clk/hisilicon
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Gustavo A. R. Silva e200279bb8 reset: hisilicon: fix potential NULL pointer dereference
commit e9a2310fb689151166df7fd9971093362d34bd79 upstream.

There is a potential execution path in which function
platform_get_resource() returns NULL. If this happens,
we will end up having a NULL pointer dereference.

Fix this by replacing devm_ioremap with devm_ioremap_resource,
which has the NULL check and the memory region request.

This code was detected with the help of Coccinelle.

Cc: stable@vger.kernel.org
Fixes: 97b7129cd2 ("reset: hisilicon: change the definition of hisi_reset_init")
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-11-21 09:26:00 +01:00
..
clk-hi3519.c clk: hisilicon: hi3519: add driver remove path and fix some issues 2016-06-30 12:35:20 -07:00
clk-hi3620.c clk: hisilicon: Remove CLK_IS_ROOT 2016-03-02 17:43:32 -08:00
clk-hi6220-stub.c clk: hisilicon: Remove CLK_IS_ROOT 2016-03-02 17:43:32 -08:00
clk-hi6220.c clk: hi6220: mark clock cs_atb_syspll as critical 2017-12-20 10:07:30 +01:00
clk-hip04.c clk: hisilicon: Remove CLK_IS_ROOT 2016-03-02 17:43:32 -08:00
clk-hix5hd2.c clk: hisilicon: Remove CLK_IS_ROOT 2016-03-02 17:43:32 -08:00
clk.c clk: hisilicon: add error processing for hisi_clk_register_* functions 2016-06-30 12:35:11 -07:00
clk.h clk: hisilicon: add hisi_clk_unregister_* functions 2016-06-30 12:35:18 -07:00
clkdivider-hi6220.c clk: hi6220: fix missing clk.h include 2016-06-20 17:45:13 -07:00
clkgate-separated.c clk: hisilicon: Remove clk.h include 2015-07-20 10:53:06 -07:00
Kconfig clk: hisilicon: add CRG driver for hi3519 soc 2016-05-06 11:13:32 -07:00
Makefile clk: hisilicon: add CRG driver for hi3519 soc 2016-05-06 11:13:32 -07:00
reset.c reset: hisilicon: fix potential NULL pointer dereference 2018-11-21 09:26:00 +01:00
reset.h reset: hisilicon: change the definition of hisi_reset_init 2016-06-30 12:33:22 -07:00