diff options
author | Takashi Iwai <tiwai@suse.de> | 2015-12-22 10:58:35 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2015-12-22 10:58:35 +0100 |
commit | 0654c623481bc7eed2553983efed2bfadd561868 (patch) | |
tree | 341f1c52905f0d4165511ba6283ce25c7e1f55e9 | |
parent | 826c3f3cf78e94932d0798b74d58cf74aff9d14f (diff) | |
parent | f67d71ae8bb18137eb1909a588879b33e06cc4c4 (diff) | |
download | sound-unstable-0654c623481bc7eed2553983efed2bfadd561868.tar.gz |
Merge branch 'for-next'
-rw-r--r-- | sound/usb/stream.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sound/usb/stream.c b/sound/usb/stream.c index 8ee14f2365e74..c4dc577ab1bd3 100644 --- a/sound/usb/stream.c +++ b/sound/usb/stream.c @@ -125,11 +125,9 @@ static int usb_chmap_ctl_info(struct snd_kcontrol *kcontrol, static bool have_dup_chmap(struct snd_usb_substream *subs, struct audioformat *fp) { - struct list_head *p; + struct audioformat *prev = fp; - for (p = fp->list.prev; p != &subs->fmt_list; p = p->prev) { - struct audioformat *prev; - prev = list_entry(p, struct audioformat, list); + list_for_each_entry_continue_reverse(prev, &subs->fmt_list, list) { if (prev->chmap && !memcmp(prev->chmap, fp->chmap, sizeof(*fp->chmap))) return true; |