Fix divide by 0 in echoaudio driver
PATCH 1/1 Fix divide by 0 in echoaudio driver
This patch has already been merged in 2.6.34:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.34.y.git;a=commitdiff;h=b721e68bdc5b39c51bf6a1469f8d3663fbe03243
Since it fixes a /0 in the irq handler, please consider including it also in the next maintenance release of 2.6.33.
This patch is against 2.6.33.5.
Signed-off-by Giuliano Pochini <[email protected]>
sound/pci/echoaudio/echoaudio.c +3 -1
@@ -1821,7 +1821,9 @@ static irqreturn_t snd_echo_interrupt(in/* The hardware doesn't tell us which substream caused the irq, thus we have to check all running substreams. */ for (ss =0 ; ss <DSP_MAXPIPES ; ss++) { -if ((substream = chip->substream[ss])) { + substream = chip->substream[ss]; +if (substream && ((struct audiopipe *)substream->runtime-> + private_data)->state ==PIPE_STATE_STARTED ) { period =pcm_pointer (substream) / substream->runtime->period_size;if (period != chip->last_period[ss]) {
Signature · 1 line
Giuliano.