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

sound output with libao



I'm trying to work out why libao doesn't work with the dmasound_pmac OSS
driver anymore (since upgrading from 0.8.3-1.1 to 0.8.4-1, see bug
#216007).

In two applications (ogg123 and quake2 (new libao driver I'm writing for
it)) both of them fail to open the OSS device with this error:

libao - OSS cannot set channels to 2

This error message comes from line 244 of src/plugins/oss/ao_oss.c with
the following bit of code:

        if (ioctl(internal->fd,SNDCTL_DSP_STEREO,&tmp) < 0) {
                fprintf(stderr, "libao - OSS cannot set channels to %d\n", 
                        format->channels);
                goto ERR;
        }

Tracing back into dmasound_core.c in the kernel, it looks like the call
to shared_resources_are_mine is returning 0 and causing the -EINVAL from
the call to ioctl.

I commented out that block from libao and the next ioctl call failed
instead.

So, why would shared_... decide that the ioctl is failing?

-- 
jaq@debian.org                               http://people.debian.org/~jaq



Reply to: