Commit c63fcb9b authored by Damien Zammit's avatar Damien Zammit Committed by Takashi Iwai

ALSA: usb-audio: Add duplex mode for Digidesign Mbox 1 and enable mixer

This patch provides duplex support for the Digidesign Mbox 1 sound
card and has been a work in progress for about a year.
Users have confirmed on my website that previous versions of this patch
have worked on the hardware and I have been testing extensively.

It also enables the mixer control for providing clock source
selector based on the previous patch.
The sample rate has been hardcoded to 48kHz because it works better with
the S/PDIF sync mode when the sample rate is locked.  This is the
highest rate that the device supports and no loss of functionality
is observed by restricting the sample rate apart from the inability to selec
a lower rate.
Signed-off-by: default avatarDamien Zammit <damien@zamaudio.com>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent d497a82f
...@@ -2944,7 +2944,7 @@ YAMAHA_DEVICE(0x7010, "UB99"), ...@@ -2944,7 +2944,7 @@ YAMAHA_DEVICE(0x7010, "UB99"),
.data = (const struct snd_usb_audio_quirk[]){ .data = (const struct snd_usb_audio_quirk[]){
{ {
.ifnum = 0, .ifnum = 0,
.type = QUIRK_IGNORE_INTERFACE, .type = QUIRK_AUDIO_STANDARD_MIXER,
}, },
{ {
.ifnum = 1, .ifnum = 1,
...@@ -2955,16 +2955,40 @@ YAMAHA_DEVICE(0x7010, "UB99"), ...@@ -2955,16 +2955,40 @@ YAMAHA_DEVICE(0x7010, "UB99"),
.iface = 1, .iface = 1,
.altsetting = 1, .altsetting = 1,
.altset_idx = 1, .altset_idx = 1,
.attributes = UAC_EP_CS_ATTR_SAMPLE_RATE, .attributes = 0x4,
.endpoint = 0x02, .endpoint = 0x02,
.ep_attr = 0x01, .ep_attr = USB_ENDPOINT_XFER_ISOC |
.rates = SNDRV_PCM_RATE_44100 | USB_ENDPOINT_SYNC_SYNC,
SNDRV_PCM_RATE_48000, .maxpacksize = 0x130,
.rate_min = 44100, .rates = SNDRV_PCM_RATE_48000,
.rate_min = 48000,
.rate_max = 48000, .rate_max = 48000,
.nr_rates = 2, .nr_rates = 1,
.rate_table = (unsigned int[]) { .rate_table = (unsigned int[]) {
44100, 48000 48000
}
}
},
{
.ifnum = 1,
.type = QUIRK_AUDIO_FIXED_ENDPOINT,
.data = &(const struct audioformat) {
.formats = SNDRV_PCM_FMTBIT_S24_3BE,
.channels = 2,
.iface = 1,
.altsetting = 1,
.altset_idx = 1,
.attributes = 0x4,
.endpoint = 0x81,
.ep_attr = USB_ENDPOINT_XFER_ISOC |
USB_ENDPOINT_SYNC_ASYNC,
.maxpacksize = 0x130,
.rates = SNDRV_PCM_RATE_48000,
.rate_min = 48000,
.rate_max = 48000,
.nr_rates = 1,
.rate_table = (unsigned int[]) {
48000
} }
} }
}, },
...@@ -2972,7 +2996,6 @@ YAMAHA_DEVICE(0x7010, "UB99"), ...@@ -2972,7 +2996,6 @@ YAMAHA_DEVICE(0x7010, "UB99"),
.ifnum = -1 .ifnum = -1
} }
} }
} }
}, },
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment