Skip to content

Commit e8e8bab

Browse files
zonquetiwai
authored andcommitted
ALSA: snd-usb: re-order code
Move code from endpoint.c into a new file called stream.c and rename functions so that their names actually reflect what they're doing. This way, endpoint.c will be available to functions that hold all the endpoint logic. Signed-off-by: Daniel Mack <zonque@gmail.com> Acked-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
1 parent 358e2bd commit e8e8bab

7 files changed

Lines changed: 472 additions & 444 deletions

File tree

‎sound/usb/Makefile‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ snd-usb-audio-objs := card.o \
1212
pcm.o \
1313
proc.o \
1414
quirks.o \
15+
stream.o \
1516
urb.o
1617

1718
snd-usbmidi-lib-objs := midi.o

‎sound/usb/card.c‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
#include "urb.h"
6969
#include "format.h"
7070
#include "power.h"
71+
#include "stream.h"
7172

7273
MODULE_AUTHOR("Takashi Iwai <tiwai@suse.de>");
7374
MODULE_DESCRIPTION("USB Audio");
@@ -185,7 +186,7 @@ static int snd_usb_create_stream(struct snd_usb_audio *chip, int ctrlif, int int
185186
return -EINVAL;
186187
}
187188

188-
if (! snd_usb_parse_audio_endpoints(chip, interface)) {
189+
if (! snd_usb_parse_audio_interface(chip, interface)) {
189190
usb_set_interface(dev, interface, 0); /* reset the current interface */
190191
usb_driver_claim_interface(&usb_audio_driver, iface, (void *)-1L);
191192
return -EINVAL;

0 commit comments

Comments
 (0)