diff options
Diffstat (limited to 'sound/usb/stream.c')
-rw-r--r-- | sound/usb/stream.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sound/usb/stream.c b/sound/usb/stream.c index 6b7d7a2b7baa..083ed81160e5 100644 --- a/sound/usb/stream.c +++ b/sound/usb/stream.c | |||
@@ -97,6 +97,7 @@ static void snd_usb_init_substream(struct snd_usb_stream *as, | |||
97 | subs->formats |= fp->formats; | 97 | subs->formats |= fp->formats; |
98 | subs->num_formats++; | 98 | subs->num_formats++; |
99 | subs->fmt_type = fp->fmt_type; | 99 | subs->fmt_type = fp->fmt_type; |
100 | subs->ep_num = fp->endpoint; | ||
100 | } | 101 | } |
101 | 102 | ||
102 | /* | 103 | /* |
@@ -119,9 +120,7 @@ int snd_usb_add_audio_stream(struct snd_usb_audio *chip, | |||
119 | if (as->fmt_type != fp->fmt_type) | 120 | if (as->fmt_type != fp->fmt_type) |
120 | continue; | 121 | continue; |
121 | subs = &as->substream[stream]; | 122 | subs = &as->substream[stream]; |
122 | if (!subs->data_endpoint) | 123 | if (subs->ep_num == fp->endpoint) { |
123 | continue; | ||
124 | if (subs->data_endpoint->ep_num == fp->endpoint) { | ||
125 | list_add_tail(&fp->list, &subs->fmt_list); | 124 | list_add_tail(&fp->list, &subs->fmt_list); |
126 | subs->num_formats++; | 125 | subs->num_formats++; |
127 | subs->formats |= fp->formats; | 126 | subs->formats |= fp->formats; |
@@ -134,7 +133,7 @@ int snd_usb_add_audio_stream(struct snd_usb_audio *chip, | |||
134 | if (as->fmt_type != fp->fmt_type) | 133 | if (as->fmt_type != fp->fmt_type) |
135 | continue; | 134 | continue; |
136 | subs = &as->substream[stream]; | 135 | subs = &as->substream[stream]; |
137 | if (subs->data_endpoint) | 136 | if (subs->ep_num) |
138 | continue; | 137 | continue; |
139 | err = snd_pcm_new_stream(as->pcm, stream, 1); | 138 | err = snd_pcm_new_stream(as->pcm, stream, 1); |
140 | if (err < 0) | 139 | if (err < 0) |