From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Yauhen Kharuzhy <jekhor@gmail.com>
Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
Hans de Goede <hansg@kernel.org>
Subject: Re: [PATCH v2 4/5] input: drv260x: Fix unbalanced regulator_disable() call
Date: Tue, 24 Feb 2026 14:45:51 -0800 [thread overview]
Message-ID: <aZ4qB-bw4olcPKSD@google.com> (raw)
In-Reply-To: <aZbg2w2lIahy_sM9@jekhomev>
On Thu, Feb 19, 2026 at 12:11:47PM +0200, Yauhen Kharuzhy wrote:
> On Wed, Feb 18, 2026 at 06:43:30PM -0800, Dmitry Torokhov wrote:
> > Hi Yauhen,
> >
> > On Sun, Feb 15, 2026 at 04:14:34PM +0200, Yauhen Kharuzhy wrote:
> > > +static void drv260x_remove(struct i2c_client *client)
> > > +{
> > > + struct drv260x_data *haptics = i2c_get_clientdata(client);
> > > +
> > > + regulator_disable(haptics->regulator);
> > > }
> >
> > This will result in power being shut off the first thing during
> > unbinding, which is too early.
> >
> > I switched this to devm_add_action_or_reset() and applied.
>
> Do you mean that, in this case, regulator_disable() may be called before any
> devm_* registered actions? Good point, thanks.
>
Yes, all devm* actions are run after remove() completes.
Thanks.
--
Dmitry
next prev parent reply other threads:[~2026-02-24 22:45 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-15 14:14 [PATCH v2 0/5] DRV260x: Support ACPI-enumerated devices Yauhen Kharuzhy
2026-02-15 14:14 ` [PATCH v2 1/5] input: drv260x: Add I2C IDs for all device variants Yauhen Kharuzhy
2026-02-15 14:14 ` [PATCH v2 2/5] input: drv260x: Sort all #include alphabetically Yauhen Kharuzhy
2026-02-15 14:14 ` [PATCH v2 3/5] input: drv260x: Add support for ACPI-enumerated devices Yauhen Kharuzhy
2026-02-15 14:14 ` [PATCH v2 4/5] input: drv260x: Fix unbalanced regulator_disable() call Yauhen Kharuzhy
2026-02-19 2:43 ` Dmitry Torokhov
2026-02-19 10:11 ` Yauhen Kharuzhy
2026-02-24 22:45 ` Dmitry Torokhov [this message]
2026-02-15 14:14 ` [PATCH v2 5/5] input: drv260x: Handle calibration timeout Yauhen Kharuzhy
2026-02-19 2:44 ` [PATCH v2 0/5] DRV260x: Support ACPI-enumerated devices Dmitry Torokhov
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=aZ4qB-bw4olcPKSD@google.com \
--to=dmitry.torokhov@gmail.com \
--cc=hansg@kernel.org \
--cc=jekhor@gmail.com \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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