kernel-fxtec-pro1x/drivers/pinctrl
Wei Yongjun c29e9da56b pinctrl: nsp: Fix potential NULL dereference
platform_get_resource() may fail and return NULL, so we should
better check it's return value to avoid a NULL pointer dereference
a bit later in the code.

This is detected by Coccinelle semantic patch.

@@
expression pdev, res, n, t, e, e1, e2;
@@

res = platform_get_resource(pdev, t, n);
+ if (!res)
+   return -EINVAL;
... when != res == NULL
e = devm_ioremap_nocache(e1, res->start, e2);

Fixes: cc4fa83f66 ("pinctrl: nsp: add pinmux driver support for Broadcom NSP SoC")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Reviewed-by: Ray Jui <ray.jui@broadcom.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2018-07-14 12:47:04 +02:00
..
actions pinctrl: actions: Fix uninitialized error in owl_pin_config_set() 2018-06-18 07:55:56 +02:00
aspeed
bcm pinctrl: nsp: Fix potential NULL dereference 2018-07-14 12:47:04 +02:00
berlin treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
freescale treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
intel This is the bulk of pin control changes for v4.18. 2018-06-07 13:56:45 -07:00
mediatek pinctrl: mt7622: fix a kernel panic when gpio-hog is being applied 2018-07-14 12:47:04 +02:00
meson This is the bulk of pin control changes for v4.18. 2018-06-07 13:56:45 -07:00
mvebu treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
nomadik
pxa
qcom pinctrl: msm: fix gpio-hog related boot issues 2018-05-24 10:03:51 +02:00
samsung treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
sh-pfc pinctrl: sh-pfc: r8a77970: remove SH_PFC_PIN_CFG_DRIVE_STRENGTH flag 2018-07-14 12:47:04 +02:00
sirf treewide: kzalloc() -> kcalloc() 2018-06-12 16:19:22 -07:00
spear treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
sprd treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
stm32 pinctrl/stm32: Add irq_eoi for stm32gpio irqchip 2018-05-24 12:38:22 +01:00
sunxi treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
tegra treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
ti treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
uniphier This is the bulk of pin control changes for v4.18. 2018-06-07 13:56:45 -07:00
vt8500 treewide: kzalloc() -> kcalloc() 2018-06-12 16:19:22 -07:00
zte treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
core.c
core.h
devicetree.c pinctrl: devicetree: Fix pctldev pointer overwrite 2018-06-18 07:55:56 +02:00
devicetree.h
Kconfig pinctrl: actions: Add Actions S900 pinctrl driver 2018-05-02 14:36:08 +02:00
Makefile pinctrl: actions: Add Actions S900 pinctrl driver 2018-05-02 14:36:08 +02:00
pinconf-generic.c
pinconf.c
pinconf.h
pinctrl-amd.c
pinctrl-amd.h
pinctrl-artpec6.c
pinctrl-as3722.c
pinctrl-at91-pio4.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-at91.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-at91.h
pinctrl-axp209.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-coh901.c
pinctrl-coh901.h
pinctrl-da850-pupd.c
pinctrl-digicolor.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-falcon.c
pinctrl-gemini.c
pinctrl-ingenic.c pinctrl: ingenic: Fix inverted direction for < JZ4770 2018-07-14 12:47:04 +02:00
pinctrl-lantiq.c treewide: kzalloc() -> kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-lantiq.h
pinctrl-lpc18xx.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-max77620.c
pinctrl-mcp23s08.c
pinctrl-ocelot.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-oxnas.c
pinctrl-palmas.c
pinctrl-pic32.c
pinctrl-pic32.h
pinctrl-pistachio.c
pinctrl-rk805.c
pinctrl-rockchip.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-rza1.c
pinctrl-single.c pinctrl: single: Add allocation failure checking of saved_vals 2018-06-18 07:55:56 +02:00
pinctrl-st.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-sx150x.c
pinctrl-tb10x.c
pinctrl-u300.c
pinctrl-utils.c
pinctrl-utils.h
pinctrl-xway.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
pinctrl-zynq.c
pinmux.c
pinmux.h