Support for Digidesign Mbox 2 duplex analogue mode.
Subsystems (2)
PATCH 1/1 Support for Digidesign Mbox 2 duplex analogue mode.
From: Damien Zammit <[email protected]>
Added suggestions by Takashi Iwai
(see previous post on Mbox 2).
Some lines are still longer than 80 characters, but all other warnings have been fixed.
Signed-off-by Damien Zammit <[email protected]>
--- sound/usb/midi.c | 12 ++++ sound/usb/quirks-table.h | 51 +++++++++++++++++ sound/usb/quirks.c | 137 ++++++++++++++++++++++++++++++++++++++++++++++ sound/usb/quirks.h | 5 ++ sound/usb/usbaudio.h | 1 + 5 files changed, 206 insertions(+), 0 deletions(-)
sound/usb/midi.c +12 -0
@@ -2122,6 +2122,18 @@ int snd_usbmidi_create(struct snd_card *card, umidi->usb_protocol_ops = &snd_usbmidi_novation_ops; err =snd_usbmidi_detect_per_port_endpoints (umidi, endpoints);break ; +case QUIRK_MIDI_MBOX2 : +/* Digidesign Mbox 2 uses MIDIMAN MIDI protocol */ + umidi->usb_protocol_ops = &snd_usbmidi_midiman_ops; +/* +* We have to make sure that the USB core looks +* again at interface 6 by calling usb_set_interface() on it. +*/ +usb_set_interface (umidi->dev,6 ,0 ); +memcpy (&endpoints[0 ], quirk->data, +sizeof (struct snd_usb_midi_endpoint_info )); + err =0 ; +break ;case QUIRK_MIDI_RAW_BYTES : umidi->usb_protocol_ops = &snd_usbmidi_raw_ops;/*
sound/usb/quirks-table.h +51 -0
57 lines not on this page · raw message
sound/usb/quirks.c +137 -0
170 lines not on this page · raw message
sound/usb/quirks.h +5 -0
@@ -20,4 +20,9 @@ void snd_usb_set_format_quirk(struct snd_usb_substream *subs,int snd_usb_is_big_endian_format (struct snd_usb_audio *chip,struct audioformat *fp); +static int mbox2_skip_setting_quirk (struct snd_usb_audio *chip, +int iface,int altno); + +static int snd_usb_mbox2_boot_quirk (struct usb_device *dev); +#endif /* __USBAUDIO_QUIRKS_H */
sound/usb/usbaudio.h +1 -0
@@ -70,6 +70,7 @@ enum quirk_type {QUIRK_MIDI_YAMAHA ,QUIRK_MIDI_MIDIMAN ,QUIRK_MIDI_NOVATION , +QUIRK_MIDI_MBOX2 ,QUIRK_MIDI_RAW_BYTES ,QUIRK_MIDI_EMAGIC , QUIRK_MIDI_CME,
Signature · 1 line
1.6.3.3