[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: USB audio



On Mon, Jan 28, 2002 at 12:06:06PM -0500, Albert D. Cahalan wrote:

> > Do you have a patch? I'd be interested in seeing your bug report.
> 
> Check google:  cahalan usb audio -google
> Look for the follow-up with extra info.

I took a look at your posting. I'm not sure what value disassembly
code has over locating where the error is occurring in the source.
Looking at the source, it appears that a deadlock is occurring over
the spin_lock on the USB data structure for audio, but I haven't spent
enough time with it to figure out what's going on, nor am I likely to
soon. I'm not really up on the guts of the USB code, and every time I
have to monkey with it (say, when I'm working on the Pegasus driver)
I'm thankful that I don't have to be.

> USB audio is another driver that only works as a module.  The
> standard Cube speakers (the ones that roll off your desk) seem to
> operate at 50 Hz, which is pretty strange.

I could have just been lucky so far, but my configuration has USB
audio compiled into the kernel, and I've played about 10 hours of
music through it so far with no problems.

It's not at all clear *which* sample rate is being used for playback.
The messages spit out by the initialization code suggest a range:

usbaudio: device 2 audiocontrol interface 0 has 0 input and 1 output AudioStreaming interfaces
usbaudio: device 2 interface 1 altsetting 0 does not have an endpoint
usbaudio: valid output sample rate 5000
usbaudio: valid output sample rate 50000
usbaudio: device 2 interface 1 altsetting 1: format 0x00000010 sratelo 5000 sratehi 50000 attributes 0x00
usbaudio: valid output sample rate 5000
usbaudio: valid output sample rate 50000
usbaudio: device 2 interface 1 altsetting 2: format 0x80000010 sratelo 5000 sratehi 50000 attributes 0x00
usbaudio: device 2 interface 1 altsetting 3 unsupported channels 2 framesize 3
usbaudio: registered dsp 14,3
usbaudio: constructing mixer for Terminal 3 type 0x0301
usbaudio: registered mixer 14,0
usb_audio_parsecontrol: usb_audio_state at c1e7a680

I don't know what connection these numbers have to reality; I've
played a variety of MP3s through the speakers (and headphones) and all
of them sounded just fine in terms of clarity, and I somehow doubt
that the kernel is doing on-the-fly up-sampling to 50KHz.

> I'm tempted to do the very un-Linus hack of finding out if our
> many sound daemons could be stuffed into the kernel. I'm sick
> of all the conflicts, and not happy knowing that there is an
> extra source of lag in the middle. Oh well.

I'm not sure exactly which lag you're talking about, and I'm not sure
that the kernel hackers are deserving of any ire. USB audio is the
most economical solution to a problem, and the fact that it works at
all under Linux is neat, but it's never going to be as efficient as
most other solutions to the audio problem. I'm pretty sure the only
reason Apple chose to do things the way they did was cost.


-- 
       . . . the self-reflecting image of a narcotized mind . . .
ozymandias G desiderata     ogd@aoaioxxysz.net     desperate, deathless
(415)823-6356       http://www.pushby.com/forrest/       ::AOAIOXXYSZ::

Attachment: pgp_Qdk4qw5yd.pgp
Description: PGP signature


Reply to: