mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2025-01-24 05:29:39 +07:00
d0a588a57c
During probe the driver allocates dummy I2C devices (i2c_new_dummy()) but they aren't unregistered during driver remove or probe failure. Additionally driver does not check the return value of i2c_new_dummy(). In case of error (i2c_new_device(): memory allocation failure or I2C address cannot be used) this function returns NULL which is later dereferenced by i2c_smbus_{read,write}_data() functions. Fix issues by properly checking for i2c_new_dummy() return value and unregistering I2C devices on driver remove or probe failure. Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Beomho Seo <beomho.seo@samsung.com> Cc: stable@vger.kernel.org Signed-off-by: Jonathan Cameron <jic23@kernel.org> |
||
---|---|---|
.. | ||
adjd_s311.c | ||
apds9300.c | ||
cm32181.c | ||
cm36651.c | ||
gp2ap020a00f.c | ||
hid-sensor-als.c | ||
Kconfig | ||
lm3533-als.c | ||
Makefile | ||
tcs3472.c | ||
tsl2563.c | ||
tsl4531.c | ||
vcnl4000.c |