All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lars-Peter Clausen <lars@metafoo.de>
To: Helen Koike <helen.koike@collabora.co.uk>,
	Sebastian Reichel <sre@kernel.org>
Cc: lgirdwood@gmail.com, broonie@kernel.org, peter.ujfalusi@ti.com,
	jarkko.nikula@bitmer.com, k.kozlowski@samsung.com,
	alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org,
	linux-omap@vger.kernel.org, perex@perex.cz, tiwai@suse.com,
	cphealy@gmail.com
Subject: Re: [PATCH v2 4/5] ASoC: tpa6130a2: Add DAPM support
Date: Mon, 20 Jun 2016 21:44:21 +0200	[thread overview]
Message-ID: <57684795.8050705@metafoo.de> (raw)
In-Reply-To: <bbddafe634bde1d12288862e02622d15c9b7c25c.1466441036.git.helen.koike@collabora.co.uk>

> +	/* before widget power up */
> +	if (SND_SOC_DAPM_EVENT_ON(event)) {
> +		/* Turn on the chip */
> +		tpa6130a2_power(data, true);
> +		/* Sync the registers */
> +		ret = regcache_sync(data->regmap);
> +		if (ret < 0) {
> +			dev_err(c->dev, "Failed to initialize chip\n");
> +			tpa6130a2_power(data, false);
> +			return ret;
> +		}
> +	/* after widget power down */
> +	} else
> +		tpa6130a2_power(data, false);

checkpatch.pl should complain about this. Kernel code style is if one branch
has branches the other has to have it as well.

WARNING: multiple messages have this Message-ID (diff)
From: Lars-Peter Clausen <lars@metafoo.de>
To: Helen Koike <helen.koike@collabora.co.uk>,
	Sebastian Reichel <sre@kernel.org>
Cc: alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org,
	tiwai@suse.com, k.kozlowski@samsung.com, lgirdwood@gmail.com,
	peter.ujfalusi@ti.com, broonie@kernel.org, cphealy@gmail.com,
	linux-omap@vger.kernel.org, jarkko.nikula@bitmer.com
Subject: Re: [PATCH v2 4/5] ASoC: tpa6130a2: Add DAPM support
Date: Mon, 20 Jun 2016 21:44:21 +0200	[thread overview]
Message-ID: <57684795.8050705@metafoo.de> (raw)
In-Reply-To: <bbddafe634bde1d12288862e02622d15c9b7c25c.1466441036.git.helen.koike@collabora.co.uk>

> +	/* before widget power up */
> +	if (SND_SOC_DAPM_EVENT_ON(event)) {
> +		/* Turn on the chip */
> +		tpa6130a2_power(data, true);
> +		/* Sync the registers */
> +		ret = regcache_sync(data->regmap);
> +		if (ret < 0) {
> +			dev_err(c->dev, "Failed to initialize chip\n");
> +			tpa6130a2_power(data, false);
> +			return ret;
> +		}
> +	/* after widget power down */
> +	} else
> +		tpa6130a2_power(data, false);

checkpatch.pl should complain about this. Kernel code style is if one branch
has branches the other has to have it as well.

  parent reply	other threads:[~2016-06-20 19:44 UTC|newest]

Thread overview: 56+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-18  3:26 [PATCH 0/4] ASoC: tpa6130a2: Add support for multiple instances Helen Koike
2016-06-18  3:26 ` [PATCH 1/4] ASoC: tpa6130a2: Register component Helen Koike
2016-06-18 22:28   ` Sebastian Reichel
2016-06-18  3:26 ` [PATCH 2/4] ASoC: tap6130a2: Use regmap Helen Koike
2016-06-18 22:33   ` Sebastian Reichel
2016-06-23 14:38   ` Applied "ASoC: tap6130a2: Use regmap" to the asoc tree Mark Brown
2016-06-23 14:38     ` Mark Brown
2016-06-18  3:26 ` [PATCH 3/4] ASoC: tpa6130a2: Use snd soc volsw functions Helen Koike
2016-06-18 22:34   ` Sebastian Reichel
2016-06-18  3:26 ` [PATCH 4/4] ASoC: tpa6130a2: Add DAPM support Helen Koike
2016-06-18 23:21   ` Sebastian Reichel
2016-06-19  9:39     ` Lars-Peter Clausen
2016-06-19  9:39       ` Lars-Peter Clausen
2016-06-19 20:03       ` Sebastian Reichel
2016-06-20  8:34   ` Peter Ujfalusi
2016-06-20  8:34     ` Peter Ujfalusi
2016-06-18 10:40 ` [PATCH 0/4] ASoC: tpa6130a2: Add support for multiple instances Sebastian Reichel
2016-06-18 21:33   ` Sebastian Reichel
2016-06-18 21:33     ` Sebastian Reichel
2016-06-20 17:12   ` [PATCH v2 0/5] " Helen Koike
2016-06-20 17:12     ` Helen Koike
2016-06-20 17:12     ` [PATCH v2 1/5] ASoC: tpa6130a2: Register component Helen Koike
2016-06-20 17:12       ` Helen Koike
2016-06-23 14:38       ` Applied "ASoC: tpa6130a2: Register component" to the asoc tree Mark Brown
2016-06-23 14:38         ` Mark Brown
2016-06-20 17:12     ` [PATCH v2 2/5] ASoC: tap6130a2: Use regmap Helen Koike
2016-06-20 17:12       ` Helen Koike
2016-06-21  1:41       ` Sebastian Reichel
2016-06-20 17:12     ` [PATCH v2 3/5] ASoC: tpa6130a2: Use snd soc volsw functions Helen Koike
2016-06-20 17:12       ` Helen Koike
2016-06-21  1:41       ` Sebastian Reichel
2016-06-23 14:38       ` Applied "ASoC: tpa6130a2: Use snd soc volsw functions" to the asoc tree Mark Brown
2016-06-23 14:38         ` Mark Brown
2016-06-20 17:12     ` [PATCH v2 4/5] ASoC: tpa6130a2: Add DAPM support Helen Koike
2016-06-20 17:12       ` Helen Koike
2016-06-20 19:06       ` Helen Koike
2016-06-20 19:06         ` Helen Koike
2016-06-21  1:45         ` Sebastian Reichel
2016-06-21  1:45           ` Sebastian Reichel
2016-06-20 19:44       ` Lars-Peter Clausen [this message]
2016-06-20 19:44         ` Lars-Peter Clausen
2016-06-20 20:12         ` Helen Koike
2016-06-20 20:12           ` Helen Koike
2016-06-20 17:12     ` [PATCH v2 5/5] ASoC: tpa6130a2: Remove goto err_gpio Helen Koike
2016-06-20 17:12       ` Helen Koike
2016-06-21  1:42       ` Sebastian Reichel
2016-06-26 12:02       ` Applied "ASoC: tpa6130a2: Remove goto err_gpio" to the asoc tree Mark Brown
2016-06-26 12:02         ` Mark Brown
2016-06-23 19:23     ` [PATCH v3 0/2] ASoC: tpa6130a2: Add support for multiple instances Helen Koike
2016-06-23 19:23       ` Helen Koike
2016-06-23 19:23       ` [PATCH v3 1/2] ASoC: tpa6130a2: Add DAPM support Helen Koike
2016-06-26 12:02         ` Applied "ASoC: tpa6130a2: Add DAPM support" to the asoc tree Mark Brown
2016-06-26 12:02           ` Mark Brown
2016-06-23 19:23       ` [PATCH v3 2/2] ASoC: tpa6130a2: Remove goto err_gpio Helen Koike
2016-06-19 20:14 ` [PATCH 0/4] ASoC: tpa6130a2: Add support for multiple instances Sebastian Reichel
2016-06-19 20:14   ` Sebastian Reichel

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=57684795.8050705@metafoo.de \
    --to=lars@metafoo.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=cphealy@gmail.com \
    --cc=helen.koike@collabora.co.uk \
    --cc=jarkko.nikula@bitmer.com \
    --cc=k.kozlowski@samsung.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=peter.ujfalusi@ti.com \
    --cc=sre@kernel.org \
    --cc=tiwai@suse.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 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.