summaryrefslogtreecommitdiff
path: root/include/linux/timerqueue.h
diff options
context:
space:
mode:
authorAntoniu Miclaus <antoniu.miclaus@analog.com>2026-02-16 12:57:56 +0300
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2026-02-23 11:24:39 +0300
commitacc3949aab3e8094641a9c7c2768de1958c88378 (patch)
tree5e2b7a92f9a65573facda60dd47f763d04a4ea4f /include/linux/timerqueue.h
parent91f950b4cbb1aa9ea4eb3999f1463e8044b717fb (diff)
downloadlinux-acc3949aab3e8094641a9c7c2768de1958c88378.tar.xz
iio: gyro: mpu3050-core: fix pm_runtime error handling
The return value of pm_runtime_get_sync() is not checked, allowing the driver to access hardware that may fail to resume. The device usage count is also unconditionally incremented. Use pm_runtime_resume_and_get() which propagates errors and avoids incrementing the usage count on failure. In preenable, add pm_runtime_put_autosuspend() on set_8khz_samplerate() failure since postdisable does not run when preenable fails. Fixes: 3904b28efb2c ("iio: gyro: Add driver for the MPU-3050 gyroscope") Reviewed-by: Linus Walleij <linusw@kernel.org> Signed-off-by: Antoniu Miclaus <antoniu.miclaus@analog.com> Cc: <Stable@vger.kernel.org> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'include/linux/timerqueue.h')
0 files changed, 0 insertions, 0 deletions