linux/drivers/iio/light
Zheyu Ma 06674fc7c0 iio: light: isl29028: Fix the warning in isl29028_remove()
The driver use the non-managed form of the register function in
isl29028_remove(). To keep the release order as mirroring the ordering
in probe, the driver should use non-managed form in probe, too.

The following log reveals it:

[   32.374955] isl29028 0-0010: remove
[   32.376861] general protection fault, probably for non-canonical address 0xdffffc0000000006: 0000 [#1] PREEMPT SMP KASAN PTI
[   32.377676] KASAN: null-ptr-deref in range [0x0000000000000030-0x0000000000000037]
[   32.379432] RIP: 0010:kernfs_find_and_get_ns+0x28/0xe0
[   32.385461] Call Trace:
[   32.385807]  sysfs_unmerge_group+0x59/0x110
[   32.386110]  dpm_sysfs_remove+0x58/0xc0
[   32.386391]  device_del+0x296/0xe50
[   32.386959]  cdev_device_del+0x1d/0xd0
[   32.387231]  devm_iio_device_unreg+0x27/0xb0
[   32.387542]  devres_release_group+0x319/0x3d0
[   32.388162]  i2c_device_remove+0x93/0x1f0

Fixes: 2db5054ac2 ("staging: iio: isl29028: add runtime power management support")
Signed-off-by: Zheyu Ma <zheyuma97@gmail.com>
Link: https://lore.kernel.org/r/20220717004241.2281028-1-zheyuma97@gmail.com
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2022-07-19 09:42:11 +01:00
..
acpi-als.c
adjd_s311.c
adux1020.c
al3010.c iio: light: al3010: Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr() 2022-07-18 18:48:18 +01:00
al3320a.c iio: light: al3320a: Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr() 2022-07-18 18:48:18 +01:00
apds9300.c
apds9960.c iio: core: Simplify the registration of kfifo buffers 2022-04-10 16:25:46 +01:00
as73211.c iio: light: as73211: Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr() 2022-07-18 18:48:18 +01:00
bh1750.c iio: light: bh1750: Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr() 2022-07-18 18:48:18 +01:00
bh1780.c iio:light:bh1780: Remove duplicated error reporting in .remove() 2022-06-11 14:35:25 +01:00
cm3232.c
cm3323.c
cm3605.c iio: light: cm3605: Switch to DEFINE_SIMPLE_DEV_PM_OPS() and pm_sleep_ptr() 2022-07-18 18:48:18 +01:00
cm32181.c iio: light: cm32181: Add PM support 2022-07-07 17:50:04 +01:00
cm36651.c
cros_ec_light_prox.c iio: cros: Register FIFO callback after sensor is registered 2022-07-18 18:29:13 +01:00
gp2ap002.c iio: light: gp2ap002: Switch to DEFINE_RUNTIME_DEV_PM_OPS and pm_ptr() 2022-07-18 18:48:19 +01:00
gp2ap020a00f.c
hid-sensor-als.c
hid-sensor-prox.c
iqs621-als.c
isl29018.c
isl29028.c iio: light: isl29028: Fix the warning in isl29028_remove() 2022-07-19 09:42:11 +01:00
isl29125.c
jsa1212.c iio:light:jsa1212: Remove duplicated error reporting in .remove() 2022-06-11 14:35:25 +01:00
Kconfig iio: light: cm3605: Drop dependency on OF 2022-04-28 19:22:55 +01:00
lm3533-als.c
ltr501.c
lv0104cs.c
Makefile
max44000.c
max44009.c
noa1305.c
opt3001.c iio:light:opt3001: Remove duplicated error reporting in .remove() 2022-06-11 14:35:25 +01:00
pa12203001.c iio:light:pa12203001: Improve error reporting for problems during .remove() 2022-06-11 14:35:27 +01:00
rpr0521.c iio:light:rpr0521: Switch from CONFIG_PM guards to pm_ptr() etc 2022-02-21 19:33:04 +00:00
si1133.c
si1145.c
st_uvis25.h
st_uvis25_core.c
st_uvis25_i2c.c
st_uvis25_spi.c
stk3310.c iio:light:stk3310: Remove duplicated error reporting in .remove() 2022-06-11 14:35:25 +01:00
tcs3414.c
tcs3472.c
tsl2563.c iio:light:tsl2563: Replace cancel_delayed_work() with cancel_delayed_work_sync(). 2022-06-18 14:56:25 +01:00
tsl2583.c iio: light: tsl2583: Use DEFINE_RUNTIME_DEV_PM_OPS and pm_ptr() 2022-07-18 18:48:19 +01:00
tsl2591.c iio: light: tsl2591: Use DEFINE_RUNTIME_DEV_PM_OPS() and pm_ptr() 2022-07-18 18:48:19 +01:00
tsl2772.c iio: light: tsl2772: Make use of device properties 2022-04-28 19:22:55 +01:00
tsl4531.c
us5182d.c iio: light: us5182: Switch from CONFIG_PM guards to pm_ptr() etc 2022-07-18 18:48:18 +01:00
vcnl4000.c iio: light: vcnl4000: Use DEFINE_RUNTIME_DEV_PM_OPS() and pm_ptr() macros 2022-07-18 18:48:19 +01:00
vcnl4035.c iio: light: vcnl4035: Use DEFINE_RUNTIME_DEV_PM_OPS() and pm_ptr() macros 2022-07-18 18:48:19 +01:00
veml6030.c iio: light: veml6030: Use DEFINE_RUNTIME_DEV_PM_OPS() and pm_ptr() macros 2022-07-18 18:48:19 +01:00
veml6070.c
vl6180.c
zopt2201.c