FAILED: patch "[PATCH] iio: imu: inv_icm42600: fix odr switch when turning buffer" failed to apply to 5.10-stable tree
Subsystems (3)
[email protected]
maintainerThe patch below does not apply to the 5.10-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.
To reproduce the conflict and resubmit, you may use the following commands:
git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-5.10.y
git checkout FETCH_HEAD
git cherry-pick -x ffd32db8263d2d785a2c419486a450dc80693235
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2026031737-trophy-prison-d009@gregkh' --subject-prefix 'PATCH 5.10.y' HEAD^..
Possible dependencies:
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From ffd32db8263d2d785a2c419486a450dc80693235 Mon Sep 17 00:00:00 2001
From: Jean-Baptiste Maneyrol <[email protected]>
Date: Fri, 30 Jan 2026 17:10:23 +0100
Subject: [PATCH] iio: imu: inv_icm42600: fix odr switch when turning buffer
off
ODR switch is done in 2 steps when FIFO is on : change the ODR register value and acknowledge change when reading the FIFO ODR change flag. When we are switching odr and turning buffer off just afterward, we are losing the FIFO ODR change flag and ODR switch is blocked.
Fix the issue by force applying any waiting ODR change when turning buffer off.
drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c +4 -0
@@ -371,6 +371,8 @@ static int inv_icm42600_buffer_predisable(struct iio_dev *indio_dev)static int inv_icm42600_buffer_postdisable (struct iio_dev *indio_dev) {struct inv_icm42600_state *st =iio_device_get_drvdata (indio_dev); +struct inv_icm42600_sensor_state *sensor_st =iio_priv (indio_dev); +struct inv_sensors_timestamp *ts = &sensor_st->ts;struct device *dev =regmap_get_device (st->map);unsigned int sensor;unsigned int *watermark;
@@ -392,6 +394,8 @@ static int inv_icm42600_buffer_postdisable(struct iio_dev *indio_dev)mutex_lock (&st->lock); +inv_sensors_timestamp_apply_odr (ts,0 ,0 ,0 ); + ret =inv_icm42600_buffer_set_fifo_en (st, st->fifo.en & ~sensor);if (ret) goto out_unlock;
PATCH 1/1 iio: imu: inv_icm42600: fix odr switch when turning buffer off
From: Jean-Baptiste Maneyrol <[email protected]>
ODR switch is done in 2 steps when FIFO is on : change the ODR register value and acknowledge change when reading the FIFO ODR change flag. When we are switching odr and turning buffer off just afterward, we are losing the FIFO ODR change flag and ODR switch is blocked.
Fix the issue by force applying any waiting ODR change when turning buffer off.
--- drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c +3 -0
@@ -377,6 +377,7 @@ static int inv_icm42600_buffer_predisable(struct iio_dev *indio_dev)static int inv_icm42600_buffer_postdisable (struct iio_dev *indio_dev) {struct inv_icm42600_state *st =iio_device_get_drvdata (indio_dev); +struct inv_icm42600_timestamp *ts =iio_priv (indio_dev);struct device *dev =regmap_get_device (st->map);unsigned int sensor;unsigned int *watermark;
@@ -398,6 +399,8 @@ static int inv_icm42600_buffer_postdisable(struct iio_dev *indio_dev)mutex_lock (&st->lock); +inv_icm42600_timestamp_apply_odr (ts,0 ,0 ,0 ); + ret =inv_icm42600_buffer_set_fifo_en (st, st->fifo.en & ~sensor);if (ret) goto out_unlock;
Signature · 1 line
2.25.1
Re: [PATCH 5.10.y] iio: imu: inv_icm42600: fix odr switch when turning buffer off
Quoted 43 lines · On Tue, Mar 17, 2026 at 03:39:43PM +0000, [email protected] wrote:
From: Jean-Baptiste Maneyrol <[email protected]>
ODR switch is done in 2 steps when FIFO is on : change the ODR register value and acknowledge change when reading the FIFO ODR change flag. When we are switching odr and turning buffer off just afterward, we are losing the FIFO ODR change flag and ODR switch is blocked.
Fix the issue by force applying any waiting ODR change when turning buffer off.
Fixes ec74ae9fd37c ("iio: imu: inv_icm42600: add accurate timestamping")Signed-off-by Jean-Baptiste Maneyrol <[email protected]>Signed-off-by Jonathan Cameron <[email protected]>--- drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c | 3 +++ 1 file changed, 3 insertions(+)drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c +3
-0@@ -377,6 +377,7 @@ static int inv_icm42600_buffer_predisable(struct iio_dev *indio_dev)static int inv_icm42600_buffer_postdisable (struct iio_dev *indio_dev) {struct inv_icm42600_state *st =iio_device_get_drvdata (indio_dev); +struct inv_icm42600_timestamp *ts =iio_priv (indio_dev);struct device *dev =regmap_get_device (st->map);unsigned int sensor;unsigned int *watermark;@@ -398,6 +399,8 @@ static int inv_icm42600_buffer_postdisable(struct iio_dev *indio_dev)mutex_lock (&st->lock); +inv_icm42600_timestamp_apply_odr (ts,0 ,0 ,0 ); + ret =inv_icm42600_buffer_set_fifo_en (st, st->fifo.en & ~sensor);if (ret) goto out_unlock;Signature · 1 line
2.25.1
You forgot to put the git id in the body :(
PATCH 1/1 iio: imu: inv_icm42600: fix odr switch when turning buffer off
In reply to [email protected]From: Jean-Baptiste Maneyrol <[email protected]>
ODR switch is done in 2 steps when FIFO is on : change the ODR register value and acknowledge change when reading the FIFO ODR change flag. When we are switching odr and turning buffer off just afterward, we are losing the FIFO ODR change flag and ODR switch is blocked.
Fix the issue by force applying any waiting ODR change when turning buffer off.
--- drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c +3 -0
@@ -377,6 +377,7 @@ static int inv_icm42600_buffer_predisable(struct iio_dev *indio_dev)static int inv_icm42600_buffer_postdisable (struct iio_dev *indio_dev) {struct inv_icm42600_state *st =iio_device_get_drvdata (indio_dev); +struct inv_icm42600_timestamp *ts =iio_priv (indio_dev);struct device *dev =regmap_get_device (st->map);unsigned int sensor;unsigned int *watermark;
@@ -398,6 +399,8 @@ static int inv_icm42600_buffer_postdisable(struct iio_dev *indio_dev)mutex_lock (&st->lock); +inv_icm42600_timestamp_apply_odr (ts,0 ,0 ,0 ); + ret =inv_icm42600_buffer_set_fifo_en (st, st->fifo.en & ~sensor);if (ret) goto out_unlock;
Signature · 1 line
2.25.1
PATCH 1/1 iio: imu: inv_icm42600: fix odr switch when turning buffer off
In reply to [email protected]From: Jean-Baptiste Maneyrol <[email protected]>
[ Upstream commit ffd32db8263d2d785a2c419486a450dc80693235 ]
ODR switch is done in 2 steps when FIFO is on : change the ODR register value and acknowledge change when reading the FIFO ODR change flag. When we are switching odr and turning buffer off just afterward, we are losing the FIFO ODR change flag and ODR switch is blocked.
Fix the issue by force applying any waiting ODR change when turning buffer off.
--- drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c +3 -0
@@ -377,6 +377,7 @@ static int inv_icm42600_buffer_predisable(struct iio_dev *indio_dev)static int inv_icm42600_buffer_postdisable (struct iio_dev *indio_dev) {struct inv_icm42600_state *st =iio_device_get_drvdata (indio_dev); +struct inv_icm42600_timestamp *ts =iio_priv (indio_dev);struct device *dev =regmap_get_device (st->map);unsigned int sensor;unsigned int *watermark;
@@ -398,6 +399,8 @@ static int inv_icm42600_buffer_postdisable(struct iio_dev *indio_dev)mutex_lock (&st->lock); +inv_icm42600_timestamp_apply_odr (ts,0 ,0 ,0 ); + ret =inv_icm42600_buffer_set_fifo_en (st, st->fifo.en & ~sensor);if (ret) goto out_unlock;
Signature · 1 line
2.25.1