aboutsummaryrefslogtreecommitdiffstats
path: root/sound/usb/proc.c
diff options
context:
space:
mode:
authorClemens Ladisch <clemens@ladisch.de>2010-03-04 13:46:15 -0500
committerTakashi Iwai <tiwai@suse.de>2010-03-05 02:18:32 -0500
commit015eb0b08150c6fef843efe22609589ead3d4fb8 (patch)
tree3ffcb8b5be54355761d94001a8c5415c965daccd /sound/usb/proc.c
parente11b4e0e4f5ab40ec342dc07b7201c09a45f9574 (diff)
ALSA: usb-audio: use a format bitmask per alternate setting
In preparation for USB audio 2.0 support, change the audioformat structure so that it uses a bitmask to specify possible formats. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb/proc.c')
-rw-r--r--sound/usb/proc.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/sound/usb/proc.c b/sound/usb/proc.c
index 78fc3ba2522c..f5e3f356b95f 100644
--- a/sound/usb/proc.c
+++ b/sound/usb/proc.c
@@ -79,11 +79,16 @@ static void proc_dump_substream_formats(struct snd_usb_substream *subs, struct s
79 79
80 list_for_each(p, &subs->fmt_list) { 80 list_for_each(p, &subs->fmt_list) {
81 struct audioformat *fp; 81 struct audioformat *fp;
82 snd_pcm_format_t fmt;
82 fp = list_entry(p, struct audioformat, list); 83 fp = list_entry(p, struct audioformat, list);
83 snd_iprintf(buffer, " Interface %d\n", fp->iface); 84 snd_iprintf(buffer, " Interface %d\n", fp->iface);
84 snd_iprintf(buffer, " Altset %d\n", fp->altsetting); 85 snd_iprintf(buffer, " Altset %d\n", fp->altsetting);
85 snd_iprintf(buffer, " Format: %s\n", 86 snd_iprintf(buffer, " Format:");
86 snd_pcm_format_name(fp->format)); 87 for (fmt = 0; fmt <= SNDRV_PCM_FORMAT_LAST; ++fmt)
88 if (fp->formats & (1uLL << fmt))
89 snd_iprintf(buffer, " %s",
90 snd_pcm_format_name(fmt));
91 snd_iprintf(buffer, "\n");
87 snd_iprintf(buffer, " Channels: %d\n", fp->channels); 92 snd_iprintf(buffer, " Channels: %d\n", fp->channels);
88 snd_iprintf(buffer, " Endpoint: %d %s (%s)\n", 93 snd_iprintf(buffer, " Endpoint: %d %s (%s)\n",
89 fp->endpoint & USB_ENDPOINT_NUMBER_MASK, 94 fp->endpoint & USB_ENDPOINT_NUMBER_MASK,