Re: [PATCH] iio: gyro: mpu3050: Fix runtime PM leak in mpu3050_drdy_trigger_set_state()

From: Linus Walleij

Date: Wed Sep 16 2026 - 15:11:44 EST


On Wed, Sep 16, 2026 at 6:30 PM Wentao Liang <vulab@xxxxxxxxxxx> wrote:

> The enable path of the trigger state callback called
> pm_runtime_get_sync() and returned early on every following register
> access failure without releasing the runtime PM reference, leaving
> the device powered permanently. Use pm_runtime_resume_and_get() to
> propagate resume errors without bumping the usage count, and release
> the reference on all error paths before returning.
>
> Fixes: 3904b28efb2c ("iio: gyro: Add driver for the MPU-3050 gyroscope")
> Cc: stable@xxxxxxxxxxxxxxx

No stable material.

> Signed-off-by: Wentao Liang <vulab@xxxxxxxxxxx>

Reviewed-by: Linus Walleij <linusw@xxxxxxxxxx>

Yours,
Linus Walleij