From: Daniel Mack <daniel@caiaq.de>
To: Alex Lee <alexlee188@gmail.com>
Cc: Takashi Iwai <tiwai@suse.de>,
"alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
"clemens@ladisch.de" <clemens@ladisch.de>
Subject: Re: [PATCH 2/5] ALSA: usb-audio: unify UAC macros and struct names
Date: Thu, 17 Jun 2010 14:07:52 +0200 [thread overview]
Message-ID: <20100617120752.GH17833@buzzloop.caiaq.de> (raw)
In-Reply-To: <6E4AF70D-1E90-48FF-9EBB-0882C6ABAF34@gmail.com>
On Wed, Jun 16, 2010 at 01:31:17PM -0700, Alex Lee wrote:
> It will be painful, but what about defining a whole new set of
> UAC2_xxx constants even if it is the same value as UAC1 ?
That doesn't really help much, as the code using these macros is hybrid,
for both versions. Just grep for them in the sources to see what I mean
:)
Daniel
> On 16-Jun-2010, at 1:21 PM, Takashi Iwai <tiwai@suse.de> wrote:
>
> >At Wed, 16 Jun 2010 19:40:44 +0200,
> >Daniel Mack wrote:
> >>
> >>On Wed, Jun 16, 2010 at 07:34:49PM +0200, Takashi Iwai wrote:
> >>>At Wed, 16 Jun 2010 17:57:28 +0200,
> >>>Daniel Mack wrote:
> >>>>
> >>>>diff --git a/include/linux/usb/audio.h b/include/linux/usb/audio.h
> >>>>index c51200c..a54b825 100644
> >>>>--- a/include/linux/usb/audio.h
> >>>>+++ b/include/linux/usb/audio.h
> >>>>@@ -39,8 +39,8 @@
> >>>>#define UAC_MIXER_UNIT 0x04
> >>>>#define UAC_SELECTOR_UNIT 0x05
> >>>>#define UAC_FEATURE_UNIT 0x06
> >>>>-#define UAC_PROCESSING_UNIT_V1 0x07
> >>>>-#define UAC_EXTENSION_UNIT_V1 0x08
> >>>>+#define UAC1_PROCESSING_UNIT 0x07
> >>>>+#define UAC1_EXTENSION_UNIT 0x08
> >>>
> >>>So now we have mixed prefix here, UAC_ and UAC1_.
> >>>Isn't it a bit confusing, too?
> >>>
> >>>Honestly, I have no much preference about this name-ruling.
> >>>But it's of course better if it's stabilized :)
> >>
> >>Well yeah, I hate that too, especially as it is a matter of taste
> >>eventually.
> >
> >Indeed, it's just a matter of taste.
> >
> >>However, the idea is: things that are common for both UAC1
> >>and UAC2 are prefixed with UAC_, and only those things that are
> >>special
> >>get a number suffix. Which is the case in the block you quoted above.
> >
> >Yeah, that I understood. It's just that I feel something not clear
> >around this... It might be simply because of the salad I ate today,
> >though. But I'd like to hear opinions of others before merging.
> >If nothing comes up, I'm willing to apply as is.
> >
> >>(This perticular detail is really the greatest unnecessary
> >>confusion in
> >>the UAC2 spec, btw. They just drop one enumeration value and shuffled
> >>two others around for no obvious reason. Now we have to live
> >>with that.)
> >
> >There are always enough examples how to behave rude :)
> >
> >
> >thanks,
> >
> >Takashi
next prev parent reply other threads:[~2010-06-17 12:07 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-16 15:57 usb-audio: some cleanup patches for 2.6.36 Daniel Mack
2010-06-16 15:57 ` [PATCH 1/5] ALSA: usb-audio: clean up includes in clock.c Daniel Mack
2010-06-16 15:57 ` [PATCH 2/5] ALSA: usb-audio: unify UAC macros and struct names Daniel Mack
2010-06-16 17:34 ` Takashi Iwai
2010-06-16 17:40 ` Daniel Mack
2010-06-16 20:21 ` Takashi Iwai
[not found] ` <6E4AF70D-1E90-48FF-9EBB-0882C6ABAF34@gmail.com>
2010-06-17 12:07 ` Daniel Mack [this message]
[not found] ` <AANLkTimtpdMFSDTEiDNLI0HzMPdRwJmsvyG0AuWGKv1r@mail.gmail.com>
2010-06-17 15:26 ` Daniel Mack
2010-06-16 15:57 ` [PATCH 3/5] ALSA: usb-midi: whitespace fixes Daniel Mack
2010-06-16 15:57 ` [PATCH 4/5] ALSA: usb-audio: move and add some comments Daniel Mack
2010-06-16 15:57 ` [PATCH 5/5] ALSA: usb-audio: simplify control interface access Daniel Mack
2010-06-23 14:22 ` usb-audio: some cleanup patches for 2.6.36 Takashi Iwai
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=20100617120752.GH17833@buzzloop.caiaq.de \
--to=daniel@caiaq.de \
--cc=alexlee188@gmail.com \
--cc=alsa-devel@alsa-project.org \
--cc=clemens@ladisch.de \
--cc=tiwai@suse.de \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).