Re: via82cxxx_audio locking problems

Adrian Cox (adrian@humboldt.co.uk)
Fri, 21 Sep 2001 08:50:01 +0100


Jeff Garzik wrote:

> On Thu, 20 Sep 2001, Thomas Sailer wrote:
>> Dropping and reacquiring syscall_sem around interruptible_sleep_on
>> in via_dsp_do_read, via_dsp_do_write and via_dsp_drain_playback
>> should solve the problem. Does anyone see a problem with this?

> Is there a possibility of do_read being re-entered during that window?
> I agree its a problem but the solution sounds racy?

What's probably needed is one semaphore to lock read/write and ioctls
that look at the playback engine, and another semaphore to lock accesses
to the AC97 codec. That may be simpler to implement than dropping and
releasing the syscall_sem.

-- 
Adrian Cox   http://www.humboldt.co.uk/

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/