From: Joe Perches <joe@perches.com>
To: Colin King <colin.king@canonical.com>,
Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
alsa-devel@alsa-project.org
Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [alsa-devel] [PATCH][next] ASoC: tas2770: clean up an indentation issue
Date: Tue, 12 Nov 2019 11:29:41 -0800 [thread overview]
Message-ID: <dfb2c158308e0e9cb790ad3c17eb2563ac192f2b.camel@perches.com> (raw)
In-Reply-To: <20191112190218.282337-1-colin.king@canonical.com>
On Tue, 2019-11-12 at 19:02 +0000, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
>
> There is a block that is indented too deeply, remove
> the extraneous tabs.
[]
> diff --git a/sound/soc/codecs/tas2770.c b/sound/soc/codecs/tas2770.c
[]
> @@ -761,12 +761,12 @@ static int tas2770_i2c_probe(struct i2c_client *client,
> tas2770->reset_gpio = devm_gpiod_get_optional(tas2770->dev,
> "reset-gpio",
> GPIOD_OUT_HIGH);
> - if (IS_ERR(tas2770->reset_gpio)) {
> - if (PTR_ERR(tas2770->reset_gpio) == -EPROBE_DEFER) {
> - tas2770->reset_gpio = NULL;
> - return -EPROBE_DEFER;
> - }
> + if (IS_ERR(tas2770->reset_gpio)) {
> + if (PTR_ERR(tas2770->reset_gpio) == -EPROBE_DEFER) {
> + tas2770->reset_gpio = NULL;
> + return -EPROBE_DEFER;
> }
> + }
This could remove the IS_ERR and and also remove another indentation level
if (PTR_ERR(tas2770->reset_gpio) == -EPROBE_DEFER) {
tas2770->reset_gpio = NULL;
return -EPROBE_DEFER;
}
or if _really_ desired, (but it seems not really necessary)
but this form is used in a few other sound drivers:
if (IS_ERR(tas2770->reset_gpio) &&
PTR_ERR(tas2770->reset_gpio) == -EPROBE_DEFER) {
tas2770->reset_gpio = NULL;
return -EPROBE_DEFER;
}
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
https://mailman.alsa-project.org/mailman/listinfo/alsa-devel
next prev parent reply other threads:[~2019-11-12 19:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-12 19:02 [alsa-devel] [PATCH][next] ASoC: tas2770: clean up an indentation issue Colin King
2019-11-12 19:29 ` Joe Perches [this message]
2019-11-15 12:25 ` [alsa-devel] Applied "ASoC: tas2770: clean up an indentation issue" to the asoc tree Mark Brown
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=dfb2c158308e0e9cb790ad3c17eb2563ac192f2b.camel@perches.com \
--to=joe@perches.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=colin.king@canonical.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=perex@perex.cz \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).