Skip to contentSkip to conversation

sound/core/pcm_lib.c:158: BUG

DISCUSSION Olaf Hering 3 participants 4 messages Dec 18, 2004 – Dec 20, 2004 PowerPC

lore
Share & tools
lore
#0 lore raw

Is this just debug output, or should I be worried about it?

linux-2.6.10-rc3-olh/sound/core/pcm_lib.c:158: BUG: stream = 0, pos = 0x4000, buffer size = 0x4000, period size = 0x1000

This is an ibook2, playing mp3 with xmms, alsa version is 1.0.3, from sles9. I remember no failures in the last couple hours.

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://productguide.itmanagersjournal.com/

#1 lore raw
Quoted 6 lines · Olaf Hering

Is this just debug output, or should I be worried about it?

linux-2.6.10-rc3-olh/sound/core/pcm_lib.c:158: BUG: stream = 0, pos = 0x4000, buffer size = 0x4000, period size = 0x1000

This is an ibook2, playing mp3 with xmms, alsa version is 1.0.3, from sles9. I remember no failures in the last couple hours.

That message indicates that the hardware pointer returned by the pointer callback was beyond the end of the buffer which should not be possible.

This could indicate an off by one error in the driver, it looks like the erroneous position is one sample past the end of the buffer.

Lee

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://productguide.itmanagersjournal.com/

#2 lore raw

At Sat, 18 Dec 2004 19:34:12 -0500,

Quoted 6 lines · Lee Revell
Quoted 4 lines · Olaf Hering

Is this just debug output, or should I be worried about it?

linux-2.6.10-rc3-olh/sound/core/pcm_lib.c:158: BUG: stream = 0, pos = 0x4000, buffer size = 0x4000, period size = 0x1000

Quoted 8 lines
Quoted 2 lines

This is an ibook2, playing mp3 with xmms, alsa version is 1.0.3, from sles9. I remember no failures in the last couple hours.

That message indicates that the hardware pointer returned by the pointer callback was beyond the end of the buffer which should not be possible.

This could indicate an off by one error in the driver, it looks like the erroneous position is one sample past the end of the buffer.

Does the patch below work?

Takashi

Index: alsa-kernel/ppc/pmac.c
===================================================================
RCS file: /suse/tiwai/cvs/alsa/alsa-kernel/ppc/pmac.c,v retrieving revision 1.51

ppc/pmac.c +2 -1
diff -u -r1.51 pmac.c
@@ -318,7 +318,8 @@
 	stat = ld_le16(&cp->xfer_status);
 	if (stat & (ACTIVE|DEAD)) {
 		count = in_le16(&cp->res_count);
-		count = rec->period_size - count;
+		if (count)
+			count = rec->period_size - count;
 	}
 #endif
 	count += rec->cur_period * rec->period_size;
#3 lore raw
Quoted 11 lines · Takashi Iwai

At Sat, 18 Dec 2004 19:34:12 -0500,

Quoted 9 lines · Lee Revell
Quoted 6 lines · Olaf Hering

Is this just debug output, or should I be worried about it?

linux-2.6.10-rc3-olh/sound/core/pcm_lib.c:158: BUG: stream = 0, pos = 0x4000, buffer size = 0x4000, period size = 0x1000

This is an ibook2, playing mp3 with xmms, alsa version is 1.0.3, from sles9. I remember no failures in the last couple hours.

Quoted 7 lines
Quoted 5 lines

That message indicates that the hardware pointer returned by the pointer callback was beyond the end of the buffer which should not be possible.

This could indicate an off by one error in the driver, it looks like the erroneous position is one sample past the end of the buffer.

Does the patch below work?

I havent seen that warning since 2 hours, so I guess it helps.

-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users. Discover which products truly live up to the hype. Start reading now.
http://productguide.itmanagersjournal.com/