Re: [PATCH 2/3] iio: pressure: dps310: reset the chip at probe

From: Jonathan Cameron

Date: Sat Oct 31 2026 - 21:03:19 EST


On Fri, 30 Oct 2026 00:06:34 +0200
Rupesh Majhi <zoone.rupert@xxxxxxxxx> wrote:

> The chip keeps its registers across a warm reboot, and probe changes
> only the shift bits in CFG_REG. A reboot during a FIFO capture leaves
> FIFO_EN set, so the ready bits never come and every raw read times
> out. The timeout reset does not clear it either, since the CFG_REG
> update that follows writes FIFO_EN back from the register cache.
>
> Reset the chip first, as remove already does.
>
> Fixes: 90f0d1016398 ("iio: pressure: dps310: read buffered samples from the hardware FIFO")
That's not a stable hash because it is recent enough that
it is on the tree I've rebased since then and will do again on
rc1. Given this will go in at same time as the fifo anyway
during next merge cycle, I tend to just drop the fixes tags
in cases like this to avoid having to fix them up.

Other than that, series looks fine to me, but given you asked Paulius
for a test I'll wait on that!

Thanks

Jonathan


> Reported-by: Sashiko <sashiko-bot@xxxxxxxxxx>
> Closes: https://sashiko.dev/#/patchset/20260921183132.233136-1-zoone.rupert%40gmail.com
> Signed-off-by: Rupesh Majhi <zoone.rupert@xxxxxxxxx>
> ---
> Cc: Paulius Zaleckas <paulius.zaleckas@xxxxxxxxx>
>
> drivers/iio/pressure/dps310.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/iio/pressure/dps310.c b/drivers/iio/pressure/dps310.c
> index b6aa5dbe2bcd..29778f25bb33 100644
> --- a/drivers/iio/pressure/dps310.c
> +++ b/drivers/iio/pressure/dps310.c
> @@ -1445,6 +1445,11 @@ static int dps310_probe(struct i2c_client *client)
> if (rc)
> return rc;
>
> + /* The chip keeps its state across a warm reboot */
> + rc = dps310_reset_wait(data);
> + if (rc)
> + return rc;
> +
> rc = dps310_startup(data);
> if (rc)
> return rc;