[alsa-devel] [PATCH 2/5] ASoC: max9867: Fix power management

Mark Brown broonie at kernel.org
Mon Nov 26 13:57:19 CET 2018


On Fri, Nov 23, 2018 at 03:27:29PM +0100, Ladislav Michl wrote:

> Move device enable to probe function. Doing that from prepare
> callback allows only DAC to be enabled.

This seems like it'll be a power consumption regression - instead of
managing the power at runtime we'll just leave the power on all the
time.  The normal place to do this would be either directly through DAPM
or via set_bias_level() - the latter seems a better fit here.

> While here move suspend and resume functions to more common place.

It would be better to split this out from the rest of the change as it's
a fairly large bit of code motion relative to the rest of the patch.

> @@ -491,19 +458,40 @@ static int max9867_i2c_probe(struct i2c_client *i2c,
>  	}
>  	ret = regmap_read(max9867->regmap, MAX9867_REVISION, &reg);
>  	if (ret < 0) {
> -		dev_err(&i2c->dev, "Failed to read: %d\n", ret);
> +		dev_err(&i2c->dev, "Failed to read revision: %d\n", ret);
>  		return ret;
>  	}

This is a cosmetic change unrelated to the rest of the patch, it should
be sent separately.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20181126/7af4126b/attachment.sig>


More information about the Alsa-devel mailing list