]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - sound/core/init.c
rt2x00: Fix rt2x00queue_kick_tx_queue arguments
[mirror_ubuntu-bionic-kernel.git] / sound / core / init.c
index f7c3df8b521b2c85db5771a68acf27f981084aae..57b792e2439a0f9b939c5789d7c23678ff8377bc 100644 (file)
@@ -604,11 +604,16 @@ card_id_store_attr(struct device *dev, struct device_attribute *attr,
                return -EEXIST;
        }
        for (idx = 0; idx < snd_ecards_limit; idx++) {
-               if (snd_cards[idx] && !strcmp(snd_cards[idx]->id, buf1))
-                       goto __exist;
+               if (snd_cards[idx] && !strcmp(snd_cards[idx]->id, buf1)) {
+                       if (card == snd_cards[idx])
+                               goto __ok;
+                       else
+                               goto __exist;
+               }
        }
        strcpy(card->id, buf1);
        snd_info_card_id_change(card);
+__ok:
        mutex_unlock(&snd_card_mutex);
 
        return count;