Skip to contentSkip to conversation

: snd_pcm_avail_update occasionally returns one billion frames

ALSA - lib 0001924 [email protected] 1 participant 1 message Mar 14, 2006

lore
Share & tools
lore
#0 lore raw

The following issue has been SUBMITTED.
======================================================================
<https://bugtrack.alsa-project.org/alsa-bug/view.php?id=1924>
======================================================================
Reported By: jussi_kujala
Assigned To:
======================================================================

Project:                    ALSA - lib
Issue ID:                   1924
Category:                   0_general
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
======================================================================
Date Submitted:             03-15-2006 00:02 CET
Last Modified:              03-15-2006 00:02 CET

======================================================================
Summary: snd_pcm_avail_update occasionally returns one
billion frames
Description:
Under right circumstances ALSA function snd_pcm_avail_update returns a wrong
value. More precisely, if buffer underruns are disabled like:
<code>
snd_pcm_sw_params_get_boundary( sw_params, &boundary ); snd_pcm_sw_params_set_stop_threshold( playback_handle, sw_params, boundary );
</code>
and there are constant underruns then it occasionally happens that the snd_pcm_avail_update returns the desired value plus the pointer boundary wrapout
value.

I noticed this when using a game called Stepmania, but it happens with a simple
program that plays .wav with a small buffer. To show that this is really happening, I have attached files from /proc/asound/card0/pcm0p/sub0.

If this is a some kind of a feature, it would be desirable to document it :-)
Well I am not 100% certain if this is a fault in ALSA, but it is my best guess so I make this bug report here.

======================================================================

Issue History
Date Modified Username Field Change
======================================================================
03-15-06 00:02 jussi_kujala New Issue
03-15-06 00:02 jussi_kujala File Added: sub0.tar
======================================================================

-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642