diff options
author | Daniel Mack <daniel@caiaq.de> | 2010-02-22 23:49:13 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2010-02-23 08:51:56 +0100 |
commit | de48c7bc6f93c6c8e0be8612c9d72a2dc92eaa01 (patch) | |
tree | f27b2849a4f78959f7c448eaaafd7bca8cb8f8ac /sound/usb/usx2y | |
parent | ALSA: usbmixer: bail out early when parsing audio class v2 descriptors (diff) | |
download | linux-de48c7bc6f93c6c8e0be8612c9d72a2dc92eaa01.tar.xz linux-de48c7bc6f93c6c8e0be8612c9d72a2dc92eaa01.zip |
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 @@ * Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ +#include <linux/usb.h> +#include <linux/usb/audio.h> #include <sound/core.h> #include <sound/hwdep.h> #include <sound/pcm.h> @@ -315,9 +317,9 @@ static int us122l_set_sample_rate(struct usb_device *dev, int rate) data[0] = rate; data[1] = rate >> 8; data[2] = rate >> 16; - err = us122l_ctl_msg(dev, usb_sndctrlpipe(dev, 0), SET_CUR, + err = us122l_ctl_msg(dev, usb_sndctrlpipe(dev, 0), UAC_SET_CUR, USB_TYPE_CLASS|USB_RECIP_ENDPOINT|USB_DIR_OUT, - SAMPLING_FREQ_CONTROL << 8, ep, data, 3, 1000); + UAC_EP_CS_ATTR_SAMPLE_RATE << 8, ep, data, 3, 1000); if (err < 0) snd_printk(KERN_ERR "%d: cannot set freq %d to ep 0x%x\n", dev->devnum, rate, ep); |