diff options
author | Daniel Mack <daniel@caiaq.de> | 2010-02-22 17:49:13 -0500 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2010-02-23 02:51:56 -0500 |
commit | de48c7bc6f93c6c8e0be8612c9d72a2dc92eaa01 (patch) | |
tree | f27b2849a4f78959f7c448eaaafd7bca8cb8f8ac /sound/usb/usx2y | |
parent | 7b8a043f2686af9f41e313a78ed5e98233e5fded (diff) |
ALSA: usbaudio: consolidate header files
Use the definitions from linux/usb/audio.h all over the ALSA USB audio
driver and add some missing definitions there as well.
Use the endpoint attribute macros from linux/usb/ch9 and remove the own
things from sound/usb/usbaudio.h.
Now things are also nicely prefixed which makes understanding the code
easier.
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb/usx2y')
-rw-r--r-- | sound/usb/usx2y/us122l.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sound/usb/usx2y/us122l.c b/sound/usb/usx2y/us122l.c index 91bb29666d26..44deb21b1777 100644 --- a/sound/usb/usx2y/us122l.c +++ b/sound/usb/usx2y/us122l.c | |||
@@ -16,6 +16,8 @@ | |||
16 | * Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | 16 | * Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
17 | */ | 17 | */ |
18 | 18 | ||
19 | #include <linux/usb.h> | ||
20 | #include <linux/usb/audio.h> | ||
19 | #include <sound/core.h> | 21 | #include <sound/core.h> |
20 | #include <sound/hwdep.h> | 22 | #include <sound/hwdep.h> |
21 | #include <sound/pcm.h> | 23 | #include <sound/pcm.h> |
@@ -315,9 +317,9 @@ static int us122l_set_sample_rate(struct usb_device *dev, int rate) | |||
315 | data[0] = rate; | 317 | data[0] = rate; |
316 | data[1] = rate >> 8; | 318 | data[1] = rate >> 8; |
317 | data[2] = rate >> 16; | 319 | data[2] = rate >> 16; |
318 | err = us122l_ctl_msg(dev, usb_sndctrlpipe(dev, 0), SET_CUR, | 320 | err = us122l_ctl_msg(dev, usb_sndctrlpipe(dev, 0), UAC_SET_CUR, |
319 | USB_TYPE_CLASS|USB_RECIP_ENDPOINT|USB_DIR_OUT, | 321 | USB_TYPE_CLASS|USB_RECIP_ENDPOINT|USB_DIR_OUT, |
320 | SAMPLING_FREQ_CONTROL << 8, ep, data, 3, 1000); | 322 | UAC_EP_CS_ATTR_SAMPLE_RATE << 8, ep, data, 3, 1000); |
321 | if (err < 0) | 323 | if (err < 0) |
322 | snd_printk(KERN_ERR "%d: cannot set freq %d to ep 0x%x\n", | 324 | snd_printk(KERN_ERR "%d: cannot set freq %d to ep 0x%x\n", |
323 | dev->devnum, rate, ep); | 325 | dev->devnum, rate, ep); |