aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sound/usb/card.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/sound/usb/card.c b/sound/usb/card.c
index ed120ca2353d..d8f2bf401458 100644
--- a/sound/usb/card.c
+++ b/sound/usb/card.c
@@ -530,9 +530,11 @@ snd_usb_audio_probe(struct usb_device *dev,
530 return chip; 530 return chip;
531 531
532 __error: 532 __error:
533 if (chip && !chip->num_interfaces) 533 if (chip) {
534 snd_card_free(chip->card); 534 if (!chip->num_interfaces)
535 chip->probing = 0; 535 snd_card_free(chip->card);
536 chip->probing = 0;
537 }
536 mutex_unlock(&register_mutex); 538 mutex_unlock(&register_mutex);
537 __err_val: 539 __err_val:
538 return NULL; 540 return NULL;