diff options
| author | Surendra Singh Chouhan <kr494167@gmail.com> | 2026-07-24 08:28:02 +0530 |
|---|---|---|
| committer | Jonathan Cameron <jonathan.cameron@oss.qualcomm.com> | 2026-08-31 02:58:30 +0100 |
| commit | c23bfe6e22104c463f37da3770e17ec72fc73f86 (patch) | |
| tree | ab88cf4f0f70f246ccdc0b2d86e183e1160cbc1f /scripts/Makefile.thinlto | |
| parent | 575acf622d30edfc9a0c63041991698ec907c869 (diff) | |
| download | linux-next-c23bfe6e22104c463f37da3770e17ec72fc73f86.tar.gz linux-next-c23bfe6e22104c463f37da3770e17ec72fc73f86.zip | |
iio: light: apds9999: register standby action after enabling device
apds9999_init() called devm_add_action_or_reset() at the start
of the function, before register configuration and before enabling the
device via APDS9999_MAIN_CTRL_LS_EN.
If register initialization failed during apds9999_init() (e.g. SMBus
write failures on LS_MEAS_RATE or LS_GAIN), devm_add_action_or_reset()
immediately triggered apds9999_standby(), writing to the control
register on a device that failed initialization and was never enabled.
Fix this by registering devm_add_action_or_reset() only after
APDS9999_MAIN_CTRL_LS_EN is successfully written to the control
register.
Signed-off-by: Surendra Singh Chouhan <kr494167@gmail.com>
Signed-off-by: Jonathan Cameron <jonathan.cameron@oss.qualcomm.com>
Diffstat (limited to 'scripts/Makefile.thinlto')
0 files changed, 0 insertions, 0 deletions
