Skip to content

Commit b15b4da

Browse files
Dan Carpentergregkh
authored andcommitted
staging: greybus: audio: Uninitialized variable in gbaudio_remove_controls()
The "err" variable is not meaningful so there is no need to print it. It's uninitialized on the first iteration through the loop. Fixes: 510e340 ("staging: greybus: audio: Add helper APIs for dynamic audio modules") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Alex Elder <elder@linaro.org> Reviewed-by: Vaibhav Agarwal <vaibhav.sr@gmail.com> Link: https://lore.kernel.org/r/20200804101601.GA392148@mwanda Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 9123e3a commit b15b4da

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/staging/greybus/audio_helper.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,8 +173,7 @@ static int gbaudio_remove_controls(struct snd_card *card, struct device *dev,
173173
id.index = control->index;
174174
kctl = snd_ctl_find_id(card, &id);
175175
if (!kctl) {
176-
dev_err(dev, "%d: Failed to find %s\n", err,
177-
control->name);
176+
dev_err(dev, "Failed to find %s\n", control->name);
178177
continue;
179178
}
180179
err = snd_ctl_remove(card, kctl);

0 commit comments

Comments
 (0)