All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Cc: alsa-devel@alsa-project.org,
	David Rhodes <david.rhodes@cirrus.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	kernel@pengutronix.de, James Schulman <james.schulman@cirrus.com>
Subject: Re: [PATCH] ASoC: cs42l51: improve error handling in cs42l51_remove()
Date: Fri, 22 Oct 2021 13:14:52 +0100	[thread overview]
Message-ID: <YXKrPPpfYMoRr/LQ@sirena.org.uk> (raw)
In-Reply-To: <20211022071217.462qrfutxvufqssc@pengutronix.de>

[-- Attachment #1: Type: text/plain, Size: 945 bytes --]

On Fri, Oct 22, 2021 at 09:12:17AM +0200, Uwe Kleine-König wrote:
> On Thu, Oct 21, 2021 at 10:31:56PM +0100, Mark Brown wrote:

> > The warning is fine so long as there's no action on it but use regular
> > regulator_bulk_disable() since as you youself said force disable is not
> > appropriate here.

> It's just the documentation of regulator_bulk_force_disable() that
> irritates me. It's behaviour is exactly fine. If a user of several
> regulators goes away, it should try to disable all regulators and if one
> fails to disable it's better to the others instead of keeping all
> enabled.

Well, you definitely don't want force disable since it ignores
refcounting and might impact something else sharing the regulator.
You'd want to add a separate function that just ignored errors, though
bear in mind that a lot of datasheets recommend against having the
device partially powered, warning that it may damage the part.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

      reply	other threads:[~2021-10-22 12:16 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-21 10:36 [PATCH] ASoC: cs42l51: improve error handling in cs42l51_remove() Uwe Kleine-König
2021-10-21 18:38 ` Mark Brown
2021-10-21 20:58   ` Uwe Kleine-König
2021-10-21 21:31     ` Mark Brown
2021-10-22  7:12       ` Uwe Kleine-König
2021-10-22 12:14         ` Mark Brown [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=YXKrPPpfYMoRr/LQ@sirena.org.uk \
    --to=broonie@kernel.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=david.rhodes@cirrus.com \
    --cc=james.schulman@cirrus.com \
    --cc=kernel@pengutronix.de \
    --cc=lgirdwood@gmail.com \
    --cc=u.kleine-koenig@pengutronix.de \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.