Re: [PATCH] 2.5.29: some compilation fixes for irq frenzy [OSS +

Alan Cox (alan@lxorguk.ukuu.org.uk)
01 Aug 2002 01:08:12 +0100


On Wed, 2002-07-31 at 22:50, Andy Pfiffer wrote:
> After reading the code in question, it appears to me that the existing
> save_flags/cli constructs are being used to atomically query/modify
> elements of an audio_devs[N] entry. I can see how it might be possible
> for the patch to break SMP.

The cli() is doing a lock across all processors. The local_irqsave won't
protect other processors against the modifications. The ISA side of the
OSS audio world is midbogglingly ugly for this and for lock_kernel
horrors but the PCI side isnt too bad.

The DMA pointers in ISA OSS are also touched by interrupt handling code
- which again cli() locked across all processors and lock_irq* doesn't.

Rusty submitted a much better patch for this - deleting all the old OSS
ISA drivers, so that people can just fix and use the ALSA code instead.
I'm not saying don't analyse the locks and interrupt paths and fix the
OSS audio for ISA stuff, just that it might not be the best use of time
even if you do get it sorted out.

-
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/