All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: ASoC: dapm: Allow regulators to bypass as well as disable when idle
@ 2012-09-27 19:57 Dan Carpenter
  2012-09-28 10:42 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2012-09-27 19:57 UTC (permalink / raw)
  To: broonie; +Cc: alsa-devel

Hi Mark,

I had a question about patch c05b84d14b23: "ASoC: dapm: Allow regulators
to bypass as well as disable when idle" from Sep 7, 2012.

  1022          if (SND_SOC_DAPM_EVENT_ON(event)) {
  1023                  if (w->invert & SND_SOC_DAPM_REGULATOR_BYPASS) {
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

  1024                          ret = regulator_allow_bypass(w->regulator, true);
  1025                          if (ret != 0)
  1026                                  dev_warn(w->dapm->dev,
  1027                                           "Failed to bypass %s: %d\n",
  1028                                           w->name, ret);
  1029                  }
  1030  
  1031                  return regulator_enable(w->regulator);
  1032          } else {
  1033                  if (w->invert & SND_SOC_DAPM_REGULATOR_BYPASS) {
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Right now ->invert is a single bit bitfield.  We mostly test
"if (w->invert) {...".  Are we planning to add some more bits in there?

  1034                          ret = regulator_allow_bypass(w->regulator, false);
  1035                          if (ret != 0)
  1036                                  dev_warn(w->dapm->dev,
  1037                                           "Failed to unbypass %s: %d\n",
  1038                                           w->name, ret);
  1039                  }

regards,
dan carpenter

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: ASoC: dapm: Allow regulators to bypass as well as disable when idle
  2012-09-27 19:57 ASoC: dapm: Allow regulators to bypass as well as disable when idle Dan Carpenter
@ 2012-09-28 10:42 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2012-09-28 10:42 UTC (permalink / raw)
  To: Dan Carpenter; +Cc: alsa-devel

On Thu, Sep 27, 2012 at 10:57:58PM +0300, Dan Carpenter wrote:

> Right now ->invert is a single bit bitfield.  We mostly test
> "if (w->invert) {...".  Are we planning to add some more bits in there?

There aren't any plans at present, but it's possible we might add some.
When we do the definition of invert will have to change as you point
out.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-09-28 10:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-09-27 19:57 ASoC: dapm: Allow regulators to bypass as well as disable when idle Dan Carpenter
2012-09-28 10:42 ` Mark Brown

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.