diff options
author | Lars-Peter Clausen <[email protected]> | 2023-04-13 18:37:52 -0700 |
---|---|---|
committer | Jonathan Cameron <[email protected]> | 2023-05-13 17:54:56 +0100 |
commit | 265c82ea8b172129cb6d4eff41af856c3aff6168 (patch) | |
tree | 970c7a048c904397d61c7d787db397453b5421f8 /lib/mpi/mpiutil.c | |
parent | 00ffdd6fa90298522d45ca0c348b23485584dcdc (diff) |
iio: tmag5273: Fix runtime PM leak on measurement error
The tmag5273 gets a runtime PM reference before reading a measurement and
releases it when done. But if the measurement fails the tmag5273_read_raw()
function exits before releasing the reference.
Make sure that this error path also releases the runtime PM reference.
Fixes: 866a1389174b ("iio: magnetometer: add ti tmag5273 driver")
Signed-off-by: Lars-Peter Clausen <[email protected]>
Acked-by: Gerald Loacker <[email protected]>
Reviewed-by: Nuno Sa <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Cc: <[email protected]>
Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'lib/mpi/mpiutil.c')
0 files changed, 0 insertions, 0 deletions