Skip to content

Commit

Permalink
media: solo6x10: fix missing snd_card_free in error handling case
Browse files Browse the repository at this point in the history
[ Upstream commit dcdff74 ]

Fix to goto snd_error in error handling case when fails
to do snd_ctl_add, as done elsewhere in this function.

Fixes: 28cae86 ("[media] solo6x10: move out of staging into drivers/media/pci.")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Qinglang Miao authored and gregkh committed Dec 30, 2020
1 parent e1a709e commit a622848
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/media/pci/solo6x10/solo6x10-g723.c
Expand Up @@ -385,7 +385,7 @@ int solo_g723_init(struct solo_dev *solo_dev)

ret = snd_ctl_add(card, snd_ctl_new1(&kctl, solo_dev));
if (ret < 0)
return ret;
goto snd_error;

ret = solo_snd_pcm_init(solo_dev);
if (ret < 0)
Expand Down

0 comments on commit a622848

Please sign in to comment.