From: Takashi Iwai <tiwai@suse.de>
To: Clemens Ladisch <clemens@ladisch.de>
Cc: alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org,
Paul Bonser <misterpib@gmail.com>
Subject: Re: [PATCH v2] ALSA: usb-audio: Add support for Akai MPC Element USB MIDI controller
Date: Fri, 09 Jan 2015 11:26:11 +0100 [thread overview]
Message-ID: <s5h7fwwcksc.wl-tiwai@suse.de> (raw)
In-Reply-To: <54AF95EA.90505@ladisch.de>
At Fri, 09 Jan 2015 09:48:42 +0100,
Clemens Ladisch wrote:
>
> Paul Bonser wrote:
> > On 01/08/2015 03:56 PM, Clemens Ladisch wrote:
> >> Paul Bonser wrote:
> >>> The Akai MPC Element incorrectly reports its bInterfaceClass as 255, but
> >>> otherwise implements the USB MIDI spec correctly.
> >>>
> >>> This adds a quirks-table.h entry which allows the device to be
> >>> recognized as a standard USB MIDI device.
> >>>
> >>> +++ b/sound/usb/quirks-table.h
> >>> +{
> >>> + /* Akai MPC Element */
> >>> + USB_DEVICE(0x09e8, 0x0021),
> >>> + .driver_info = (unsigned long) & (const struct snd_usb_audio_quirk) {
> >>> + .ifnum = QUIRK_ANY_INTERFACE,
> >>> + .type = QUIRK_COMPOSITE,
> >>> + .data = & (const struct snd_usb_audio_quirk[]) {
> >>> + {
> >>> + .ifnum = 0,
> >>> + .type = QUIRK_IGNORE_INTERFACE
> >>> + },
> >>> + {
> >>> + .ifnum = 1,
> >>> + .type = QUIRK_MIDI_STANDARD_INTERFACE
> >>> + },
> >>> + {
> >>> + .ifnum = -1
> >>> + }
> >>> + }
> >>> + }
> >>> +},
> >>
> >> Why a composite quirk? Does a single quirk entry not work?
> >
> > A single quirk entry results in an error message in dmesg:
> > "snd-usb-audio: probe of 3-2:1.0 failed with error -5"
>
> That message is normal for unhandled interfaces.
It's still not good to show a message, so using QUIRK_IGNORE_INTERFACE
is good enough as a workaround. So I applied it as is to for-next
branch now. Though...
> Does it actually prevent the device from working?
... it's still interesting why it needs a special handling. If we
find out more and have a better fix, let's put on top of the current
patch.
thanks,
Takashi
WARNING: multiple messages have this Message-ID (diff)
From: Takashi Iwai <tiwai@suse.de>
To: Clemens Ladisch <clemens@ladisch.de>
Cc: Paul Bonser <misterpib@gmail.com>,
Jaroslav Kysela <perex@perex.cz>,
alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org
Subject: Re: [alsa-devel] [PATCH v2] ALSA: usb-audio: Add support for Akai MPC Element USB MIDI controller
Date: Fri, 09 Jan 2015 11:26:11 +0100 [thread overview]
Message-ID: <s5h7fwwcksc.wl-tiwai@suse.de> (raw)
In-Reply-To: <54AF95EA.90505@ladisch.de>
At Fri, 09 Jan 2015 09:48:42 +0100,
Clemens Ladisch wrote:
>
> Paul Bonser wrote:
> > On 01/08/2015 03:56 PM, Clemens Ladisch wrote:
> >> Paul Bonser wrote:
> >>> The Akai MPC Element incorrectly reports its bInterfaceClass as 255, but
> >>> otherwise implements the USB MIDI spec correctly.
> >>>
> >>> This adds a quirks-table.h entry which allows the device to be
> >>> recognized as a standard USB MIDI device.
> >>>
> >>> +++ b/sound/usb/quirks-table.h
> >>> +{
> >>> + /* Akai MPC Element */
> >>> + USB_DEVICE(0x09e8, 0x0021),
> >>> + .driver_info = (unsigned long) & (const struct snd_usb_audio_quirk) {
> >>> + .ifnum = QUIRK_ANY_INTERFACE,
> >>> + .type = QUIRK_COMPOSITE,
> >>> + .data = & (const struct snd_usb_audio_quirk[]) {
> >>> + {
> >>> + .ifnum = 0,
> >>> + .type = QUIRK_IGNORE_INTERFACE
> >>> + },
> >>> + {
> >>> + .ifnum = 1,
> >>> + .type = QUIRK_MIDI_STANDARD_INTERFACE
> >>> + },
> >>> + {
> >>> + .ifnum = -1
> >>> + }
> >>> + }
> >>> + }
> >>> +},
> >>
> >> Why a composite quirk? Does a single quirk entry not work?
> >
> > A single quirk entry results in an error message in dmesg:
> > "snd-usb-audio: probe of 3-2:1.0 failed with error -5"
>
> That message is normal for unhandled interfaces.
It's still not good to show a message, so using QUIRK_IGNORE_INTERFACE
is good enough as a workaround. So I applied it as is to for-next
branch now. Though...
> Does it actually prevent the device from working?
... it's still interesting why it needs a special handling. If we
find out more and have a better fix, let's put on top of the current
patch.
thanks,
Takashi
next prev parent reply other threads:[~2015-01-09 10:26 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-08 5:34 [PATCH v2] ALSA: usb-audio: Add support for Akai MPC Element USB MIDI controller Paul Bonser
2015-01-08 21:56 ` Clemens Ladisch
2015-01-08 21:56 ` [alsa-devel] " Clemens Ladisch
2015-01-09 0:46 ` Paul Bonser
2015-01-09 8:48 ` Clemens Ladisch
2015-01-09 8:48 ` [alsa-devel] " Clemens Ladisch
2015-01-09 10:26 ` Takashi Iwai [this message]
2015-01-09 10:26 ` Takashi Iwai
2015-01-09 15:11 ` Paul Bonser
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=s5h7fwwcksc.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=clemens@ladisch.de \
--cc=linux-kernel@vger.kernel.org \
--cc=misterpib@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.