diff options
author | Takashi Iwai <tiwai@suse.de> | 2010-10-25 03:56:32 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2010-10-25 03:56:32 -0400 |
commit | 79fc84c7e0d2fe89c4e82f3a26fd8b0d13c31703 (patch) | |
tree | e32a4c267dc1b5950012e18c1e71d8057140f1f5 /sound/core/init.c | |
parent | f6f94e2ab1b33f0082ac22d71f66385a60d8157f (diff) | |
parent | 97c44b2dbd0060e2e6bd56236eb638ab02ec7f30 (diff) |
Merge branch 'topic/misc' into for-linus
Diffstat (limited to 'sound/core/init.c')
-rw-r--r-- | sound/core/init.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sound/core/init.c b/sound/core/init.c index ec4a50ce5656..2de45fbd70fb 100644 --- a/sound/core/init.c +++ b/sound/core/init.c | |||
@@ -607,11 +607,16 @@ card_id_store_attr(struct device *dev, struct device_attribute *attr, | |||
607 | return -EEXIST; | 607 | return -EEXIST; |
608 | } | 608 | } |
609 | for (idx = 0; idx < snd_ecards_limit; idx++) { | 609 | for (idx = 0; idx < snd_ecards_limit; idx++) { |
610 | if (snd_cards[idx] && !strcmp(snd_cards[idx]->id, buf1)) | 610 | if (snd_cards[idx] && !strcmp(snd_cards[idx]->id, buf1)) { |
611 | goto __exist; | 611 | if (card == snd_cards[idx]) |
612 | goto __ok; | ||
613 | else | ||
614 | goto __exist; | ||
615 | } | ||
612 | } | 616 | } |
613 | strcpy(card->id, buf1); | 617 | strcpy(card->id, buf1); |
614 | snd_info_card_id_change(card); | 618 | snd_info_card_id_change(card); |
619 | __ok: | ||
615 | mutex_unlock(&snd_card_mutex); | 620 | mutex_unlock(&snd_card_mutex); |
616 | 621 | ||
617 | return count; | 622 | return count; |