ALSA: usb-audio: Add support for Focusrite Saffire 6 USB
PATCH 1/1 ALSA: usb-audio: Add support for Focusrite Saffire 6 USB
--- sound/usb/quirks-table.h | 40 ++++++++++++++++++++++++++++++++++++++++ sound/usb/quirks.c | 9 +++++---- 2 files changed, 45 insertions(+), 4 deletions(-)
sound/usb/quirks-table.h +40 -0
@@ -2569,6 +2569,46 @@ YAMAHA_DEVICE(0x7010, "UB99"), .type = QUIRK_MIDI_NOVATION } }, +{ + USB_DEVICE(0x1235, 0x0010), + .driver_info = (unsigned long ) &(const struct snd_usb_audio_quirk ) { + .vendor_name ="Focusrite" , + .product_name ="Saffire 6 USB" , + .ifnum =QUIRK_ANY_INTERFACE , + .type =QUIRK_COMPOSITE , + .data = (const struct snd_usb_audio_quirk []) { + { + .ifnum =0 , + .type =QUIRK_AUDIO_FIXED_ENDPOINT , + .data = &(const struct audioformat ) { + .formats =SNDRV_PCM_FMTBIT_S24_3LE , + .channels =4 , + .iface =0 , + .altsetting =1 , + .altset_idx =1 , + .attributes =UAC_EP_CS_ATTR_SAMPLE_RATE , + .endpoint =0x01 , + .ep_attr =USB_ENDPOINT_XFER_ISOC , + .rates =SNDRV_PCM_RATE_44100 | +SNDRV_PCM_RATE_48000 , + .rate_min =44100 , + .rate_max =48000 , + .nr_rates =2 , + .rate_table = (unsigned int []) { +44100 ,48000 + } + } + }, + { + .ifnum =1 , + .type =QUIRK_MIDI_RAW_BYTES + }, + { + .ifnum =-1 + } + } + } +}, /* Access Music devices */ {
sound/usb/quirks.c +5 -4
@@ -662,8 +662,9 @@ static int snd_usb_cm6206_boot_quirk(struct usb_device *dev)/* * Novation Twitch DJ controller +* Focusrite Novation Saffire 6 USB audio card */ -static int snd_usb_twitch_boot_quirk (struct usb_device *dev) +static int snd_usb_novation_boot_quirk (struct usb_device *dev) {/* preemptively set up the device because otherwise the * raw MIDI endpoints are not active */
@@ -972,9 +973,9 @@ int snd_usb_apply_boot_quirk(struct usb_device *dev,/* Digidesign Mbox 2 */ return snd_usb_mbox2_boot_quirk (dev); -case USB_ID (0x1235 ,0x0018 ): -/* Focusrite Novation Twitch */ -return snd_usb_twitch_boot_quirk (dev); +case USB_ID (0x1235 ,0x0010 ):/* Focusrite Novation Saffire 6 USB */ +case USB_ID (0x1235 ,0x0018 ):/* Focusrite Novation Twitch */ +return snd_usb_novation_boot_quirk (dev);case USB_ID (0x133e ,0x0815 ):/* Access Music VirusTI Desktop */
Signature · 1 line
1.8.5.2
Quoted 1 line · Eduard Gilmutdinov
Signed-off-by Eduard Gilmutdinov <[email protected]>
Looks good to me, except for the fact that the ordering of the quirk entry is not optimal (0x0010 should be above 0x0018).
But I see that there's another misplaced item (Focusrite Scarlett 18i6), so I'll fix both in a new patch on top of this one.
Thanks for your submission again!
Daniel
Quoted 85 lines
--- sound/usb/quirks-table.h | 40 ++++++++++++++++++++++++++++++++++++++++ sound/usb/quirks.c | 9 +++++---- 2 files changed, 45 insertions(+), 4 deletions(-)sound/usb/quirks-table.h +40
-0@@ -2569,6 +2569,46 @@ YAMAHA_DEVICE(0x7010, "UB99"), .type = QUIRK_MIDI_NOVATION } }, +{ + USB_DEVICE(0x1235, 0x0010), + .driver_info = (unsigned long ) &(const struct snd_usb_audio_quirk ) { + .vendor_name ="Focusrite" , + .product_name ="Saffire 6 USB" , + .ifnum =QUIRK_ANY_INTERFACE , + .type =QUIRK_COMPOSITE , + .data = (const struct snd_usb_audio_quirk []) { + { + .ifnum =0 , + .type =QUIRK_AUDIO_FIXED_ENDPOINT , + .data = &(const struct audioformat ) { + .formats =SNDRV_PCM_FMTBIT_S24_3LE , + .channels =4 , + .iface =0 , + .altsetting =1 , + .altset_idx =1 , + .attributes =UAC_EP_CS_ATTR_SAMPLE_RATE , + .endpoint =0x01 , + .ep_attr =USB_ENDPOINT_XFER_ISOC , + .rates =SNDRV_PCM_RATE_44100 | +SNDRV_PCM_RATE_48000 , + .rate_min =44100 , + .rate_max =48000 , + .nr_rates =2 , + .rate_table = (unsigned int []) { +44100 ,48000 + } + } + }, + { + .ifnum =1 , + .type =QUIRK_MIDI_RAW_BYTES + }, + { + .ifnum =-1 + } + } + } +}, /* Access Music devices */ {sound/usb/quirks.c +5
-4@@ -662,8 +662,9 @@ static int snd_usb_cm6206_boot_quirk(struct usb_device *dev)/* * Novation Twitch DJ controller +* Focusrite Novation Saffire 6 USB audio card */ -static int snd_usb_twitch_boot_quirk (struct usb_device *dev) +static int snd_usb_novation_boot_quirk (struct usb_device *dev) {/* preemptively set up the device because otherwise the * raw MIDI endpoints are not active */ @@ -972,9 +973,9 @@ int snd_usb_apply_boot_quirk(struct usb_device *dev,/* Digidesign Mbox 2 */ return snd_usb_mbox2_boot_quirk (dev); -case USB_ID (0x1235 ,0x0018 ): -/* Focusrite Novation Twitch */ -return snd_usb_twitch_boot_quirk (dev); +case USB_ID (0x1235 ,0x0010 ):/* Focusrite Novation Saffire 6 USB */ +case USB_ID (0x1235 ,0x0018 ):/* Focusrite Novation Twitch */ +return snd_usb_novation_boot_quirk (dev);case USB_ID (0x133e ,0x0815 ):/* Access Music VirusTI Desktop */
Quoted 11 lines · Daniel Mack
Quoted 1 line · Eduard Gilmutdinov
Signed-off-by Eduard Gilmutdinov <[email protected]>Looks good to me, except for the fact that the ordering of the quirk entry is not optimal (
0x0010should be above0x0018).But I see that there's another misplaced item (Focusrite Scarlett 18i6), so I'll fix both in a new patch on top of this one.
Thanks for your submission again!
Takashi, could you queue this in your tree? I'll send a fixup patch for the reording after that.
Thanks,
Daniel
Quoted 90 lines
Quoted 75 lines
--- sound/usb/quirks-table.h | 40 ++++++++++++++++++++++++++++++++++++++++ sound/usb/quirks.c | 9 +++++---- 2 files changed, 45 insertions(+), 4 deletions(-)sound/usb/quirks-table.h +40
-0@@ -2569,6 +2569,46 @@ YAMAHA_DEVICE(0x7010, "UB99"), .type = QUIRK_MIDI_NOVATION } }, +{ + USB_DEVICE(0x1235, 0x0010), + .driver_info = (unsigned long ) &(const struct snd_usb_audio_quirk ) { + .vendor_name ="Focusrite" , + .product_name ="Saffire 6 USB" , + .ifnum =QUIRK_ANY_INTERFACE , + .type =QUIRK_COMPOSITE , + .data = (const struct snd_usb_audio_quirk []) { + { + .ifnum =0 , + .type =QUIRK_AUDIO_FIXED_ENDPOINT , + .data = &(const struct audioformat ) { + .formats =SNDRV_PCM_FMTBIT_S24_3LE , + .channels =4 , + .iface =0 , + .altsetting =1 , + .altset_idx =1 , + .attributes =UAC_EP_CS_ATTR_SAMPLE_RATE , + .endpoint =0x01 , + .ep_attr =USB_ENDPOINT_XFER_ISOC , + .rates =SNDRV_PCM_RATE_44100 | +SNDRV_PCM_RATE_48000 , + .rate_min =44100 , + .rate_max =48000 , + .nr_rates =2 , + .rate_table = (unsigned int []) { +44100 ,48000 + } + } + }, + { + .ifnum =1 , + .type =QUIRK_MIDI_RAW_BYTES + }, + { + .ifnum =-1 + } + } + } +}, /* Access Music devices */ {sound/usb/quirks.c +2
-1@@ -662,8 +662,9 @@ static int snd_usb_cm6206_boot_quirk(struct usb_device *dev)/* * Novation Twitch DJ controller +* Focusrite Novation Saffire 6 USB audio card */ -static int snd_usb_twitch_boot_quirk (struct usb_device *dev) +static int snd_usb_novation_boot_quirk (struct usb_device *dev) {/* preemptively set up the device because otherwise the * raw MIDI endpoints are not active */ @@ -972,9 +973,9 @@ int snd_usb_apply_boot_quirk(struct usb_device *dev,/* Digidesign Mbox 2 */ return snd_usb_mbox2_boot_quirk (dev);sound/usb/quirks.c int snd_usb_apply_boot_quirk(struct usb_device *dev, · line 981
Quoted 10 lines
sound/usb/quirks.c +3
-3-case USB_ID (0x1235 ,0x0018 ): -/* Focusrite Novation Twitch */ -return snd_usb_twitch_boot_quirk (dev); +case USB_ID (0x1235 ,0x0010 ):/* Focusrite Novation Saffire 6 USB */ +case USB_ID (0x1235 ,0x0018 ):/* Focusrite Novation Twitch */ +return snd_usb_novation_boot_quirk (dev);case USB_ID (0x133e ,0x0815 ):/* Access Music VirusTI Desktop */ _______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
At Tue, 14 Jan 2014 13:41:59 +0100,
Quoted 8 lines · Daniel Mack
Quoted 6 lines · Daniel Mack
Quoted 1 line · Eduard Gilmutdinov
Signed-off-by Eduard Gilmutdinov <[email protected]>Looks good to me, except for the fact that the ordering of the quirk entry is not optimal (
0x0010should be above0x0018).
Quoted 8 lines
Quoted 5 lines
But I see that there's another misplaced item (Focusrite Scarlett 18i6), so I'll fix both in a new patch on top of this one.
Thanks for your submission again!
Takashi, could you queue this in your tree? I'll send a fixup patch for the reording after that.
OK, now I applied it and pushed out.
Takashi
Quoted 97 lines
Thanks,
DanielQuoted 90 lines
Quoted 75 lines
--- sound/usb/quirks-table.h | 40 ++++++++++++++++++++++++++++++++++++++++ sound/usb/quirks.c | 9 +++++---- 2 files changed, 45 insertions(+), 4 deletions(-)sound/usb/quirks-table.h +40
-0@@ -2569,6 +2569,46 @@ YAMAHA_DEVICE(0x7010, "UB99"), .type = QUIRK_MIDI_NOVATION } }, +{ + USB_DEVICE(0x1235, 0x0010), + .driver_info = (unsigned long ) &(const struct snd_usb_audio_quirk ) { + .vendor_name ="Focusrite" , + .product_name ="Saffire 6 USB" , + .ifnum =QUIRK_ANY_INTERFACE , + .type =QUIRK_COMPOSITE , + .data = (const struct snd_usb_audio_quirk []) { + { + .ifnum =0 , + .type =QUIRK_AUDIO_FIXED_ENDPOINT , + .data = &(const struct audioformat ) { + .formats =SNDRV_PCM_FMTBIT_S24_3LE , + .channels =4 , + .iface =0 , + .altsetting =1 , + .altset_idx =1 , + .attributes =UAC_EP_CS_ATTR_SAMPLE_RATE , + .endpoint =0x01 , + .ep_attr =USB_ENDPOINT_XFER_ISOC , + .rates =SNDRV_PCM_RATE_44100 | +SNDRV_PCM_RATE_48000 , + .rate_min =44100 , + .rate_max =48000 , + .nr_rates =2 , + .rate_table = (unsigned int []) { +44100 ,48000 + } + } + }, + { + .ifnum =1 , + .type =QUIRK_MIDI_RAW_BYTES + }, + { + .ifnum =-1 + } + } + } +}, /* Access Music devices */ {sound/usb/quirks.c +2
-1@@ -662,8 +662,9 @@ static int snd_usb_cm6206_boot_quirk(struct usb_device *dev)/* * Novation Twitch DJ controller +* Focusrite Novation Saffire 6 USB audio card */ -static int snd_usb_twitch_boot_quirk (struct usb_device *dev) +static int snd_usb_novation_boot_quirk (struct usb_device *dev) {/* preemptively set up the device because otherwise the * raw MIDI endpoints are not active */ @@ -972,9 +973,9 @@ int snd_usb_apply_boot_quirk(struct usb_device *dev,/* Digidesign Mbox 2 */ return snd_usb_mbox2_boot_quirk (dev);sound/usb/quirks.c int snd_usb_apply_boot_quirk(struct usb_device *dev, · line 981
Quoted 10 lines
sound/usb/quirks.c +3
-3-case USB_ID (0x1235 ,0x0018 ): -/* Focusrite Novation Twitch */ -return snd_usb_twitch_boot_quirk (dev); +case USB_ID (0x1235 ,0x0010 ):/* Focusrite Novation Saffire 6 USB */ +case USB_ID (0x1235 ,0x0018 ):/* Focusrite Novation Twitch */ +return snd_usb_novation_boot_quirk (dev);case USB_ID (0x133e ,0x0815 ):/* Access Music VirusTI Desktop */ _______________________________________________
Alsa-devel mailing list
[email protected]
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel