32 static inline unsigned get_full_speed_hz(
unsigned int usb_rate)
34 return (usb_rate * 125 + (1 << 12)) >> 13;
38 static inline unsigned get_high_speed_hz(
unsigned int usb_rate)
40 return (usb_rate * 125 + (1 << 9)) >> 10;
50 snd_iprintf(buffer,
"%03d/%03d\n", chip->
dev->bus->busnum, chip->
dev->devnum);
57 snd_iprintf(buffer,
"%04x:%04x\n",
65 if (!snd_card_proc_new(chip->
card,
"usbbus", &entry))
66 snd_info_set_text_ops(entry, chip, proc_audio_usbbus_read);
67 if (!snd_card_proc_new(chip->
card,
"usbid", &entry))
68 snd_info_set_text_ops(entry, chip, proc_audio_usbid_read);
77 static char *sync_types[4] = {
78 "NONE",
"ASYNC",
"ADAPTIVE",
"SYNC"
85 snd_iprintf(buffer,
" Interface %d\n", fp->
iface);
86 snd_iprintf(buffer,
" Altset %d\n", fp->
altsetting);
87 snd_iprintf(buffer,
" Format:");
89 if (fp->
formats & (1uLL << fmt))
90 snd_iprintf(buffer,
" %s",
92 snd_iprintf(buffer,
"\n");
93 snd_iprintf(buffer,
" Channels: %d\n", fp->
channels);
94 snd_iprintf(buffer,
" Endpoint: %d %s (%s)\n",
99 snd_iprintf(buffer,
" Rates: %d - %d (continuous)\n",
103 snd_iprintf(buffer,
" Rates: ");
104 for (i = 0; i < fp->
nr_rates; i++) {
106 snd_iprintf(buffer,
", ");
109 snd_iprintf(buffer,
"\n");
112 snd_iprintf(buffer,
" Data packet interval: %d us\n",
125 snd_iprintf(buffer,
" Packet Size = %d\n", ep->
curpacksize);
126 snd_iprintf(buffer,
" Momentary freq = %u Hz (%#x.%04x)\n",
128 ? get_full_speed_hz(ep->
freqm)
129 : get_high_speed_hz(ep->
freqm),
133 snd_iprintf(buffer,
" Feedback Format = %d.%d\n",
141 snd_iprintf(buffer,
" Status: Running\n");
142 snd_iprintf(buffer,
" Interface = %d\n", subs->
interface);
143 snd_iprintf(buffer,
" Altset = %d\n", subs->
altset_idx);
147 snd_iprintf(buffer,
" Status: Stop\n");
155 snd_iprintf(buffer,
"%s : %s\n", stream->
chip->card->longname, stream->
pcm->name);
158 snd_iprintf(buffer,
"\nPlayback:\n");
163 snd_iprintf(buffer,
"\nCapture:\n");
176 if (!snd_card_proc_new(card, name, &entry))
177 snd_info_set_text_ops(entry, stream, proc_pcm_format_read);