summaryrefslogtreecommitdiff
path: root/sound/sparc/dbri.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2021-06-08 16:05:32 +0200
committerTakashi Iwai <tiwai@suse.de>2021-06-09 17:30:29 +0200
commitbdab9e5c3eb3a633903ae423587fa9bf67555b69 (patch)
treec3d8de6ab01c21b942c288c4d106f3d0abb1669e /sound/sparc/dbri.c
parent2073fa449d6d2ac52d511fad4bce121fd284a7f3 (diff)
ALSA: sparc: Fix assignment in if condition
SPARC drivers contain a few assignments in if condition, which is a bad coding style that may confuse readers and occasionally lead to bugs. This patch is merely for coding-style fixes, no functional changes. Link: https://lore.kernel.org/r/20210608140540.17885-59-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/sparc/dbri.c')
-rw-r--r--sound/sparc/dbri.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/sound/sparc/dbri.c b/sound/sparc/dbri.c
index b055f5839578..6b84f66e4af4 100644
--- a/sound/sparc/dbri.c
+++ b/sound/sparc/dbri.c
@@ -2226,11 +2226,12 @@ static int snd_dbri_pcm(struct snd_card *card)
struct snd_pcm *pcm;
int err;
- if ((err = snd_pcm_new(card,
- /* ID */ "sun_dbri",
- /* device */ 0,
- /* playback count */ 1,
- /* capture count */ 1, &pcm)) < 0)
+ err = snd_pcm_new(card,
+ /* ID */ "sun_dbri",
+ /* device */ 0,
+ /* playback count */ 1,
+ /* capture count */ 1, &pcm);
+ if (err < 0)
return err;
snd_pcm_set_ops(pcm, SNDRV_PCM_STREAM_PLAYBACK, &snd_dbri_ops);