1
0
Fork 0
alistair23-linux/drivers/thermal/ti-soc-thermal
Sudip Mukherjee ea78361174 thermal/drivers/ti-soc-thermal: Avoid dereferencing ERR_PTR
[ Upstream commit 7440f518da ]

On error the function ti_bandgap_get_sensor_data() returns the error
code in ERR_PTR() but we only checked if the return value is NULL or
not. And, so we can dereference an error code inside ERR_PTR.
While at it, convert a check to IS_ERR_OR_NULL.

Signed-off-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Reviewed-by: Amit Kucheria <amit.kucheria@linaro.org>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Link: https://lore.kernel.org/r/20200424161944.6044-1-sudipm.mukherjee@gmail.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-06-24 17:50:23 +02:00
..
Kconfig
Makefile
TODO
dra752-bandgap.h
dra752-thermal-data.c
omap3-thermal-data.c
omap4-thermal-data.c
omap4xxx-bandgap.h
omap5-thermal-data.c
omap5xxx-bandgap.h
ti-bandgap.c
ti-bandgap.h
ti-thermal-common.c
ti-thermal.h