From: Joshua Crofts <joshua.crofts1@gmail.com>
To: "Li Youhong" <dayou5941@163.com>
Cc: wafgo01@gmail.com, jic23@kernel.org, maxwell@maxwelld.cc,
dlechner@baylibre.com, nuno.sa@analog.com, andy@kernel.org,
linux-iio@vger.kernel.org, Li Youhong <liyouhong@kylinos.cn>
Subject: Re: [PATCH v2] iio: flow: slf3s: disable regulator if measurement restart fails
Date: Fri, 4 Sep 2026 10:00:54 +0200 [thread overview]
Message-ID: <20260904100054.00004a58@gmail.com> (raw)
In-Reply-To: <20260904010902.1481157-1-dayou5941@163.com>
On Fri, 4 Sep 2026 09:09:02 +0800
"Li Youhong" <dayou5941@163.com> wrote:
> From: Li Youhong <liyouhong@kylinos.cn>
>
> slf3s_resume() enables the vdd regulator and then starts continuous
> measurement. If slf3s_start_meas() fails, resume returns an error
> while leaving the regulator enabled.
>
> After a failed resume the device stays suspended until another resume
> attempt. That later resume will call regulator_enable() again. Without
> a matching disable on the failed path, the regulator enable count is
> skewed and the supply can remain on even after a successful suspend.
>
> Disable vdd when slf3s_start_meas() fails so the enable/disable pairing
> stays balanced across resume retries.
>
> Fixes: d240b0b8a1ce ("iio: flow: add Sensirion SLF3S liquid flow sensor driver")
> Signed-off-by: Li Youhong <liyouhong@kylinos.cn>
> ---
LGTM.
Reviewed-by: Joshua Crofts <joshua.crofts1@gmail.com>
--
Kind regards,
Joshua Crofts
prev parent reply other threads:[~2026-09-04 8:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-04 1:09 [PATCH v2] iio: flow: slf3s: disable regulator if measurement restart fails Li Youhong
2026-09-04 8:00 ` Joshua Crofts [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260904100054.00004a58@gmail.com \
--to=joshua.crofts1@gmail.com \
--cc=andy@kernel.org \
--cc=dayou5941@163.com \
--cc=dlechner@baylibre.com \
--cc=jic23@kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=liyouhong@kylinos.cn \
--cc=maxwell@maxwelld.cc \
--cc=nuno.sa@analog.com \
--cc=wafgo01@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox