From: Ingo Molnar <mingo@elte.hu>
To: "Ni@m" <niam.niam@gmail.com>
Cc: Michal Piotrowski <michal.k.k.piotrowski@gmail.com>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: sound is interrupting with new kernels
Date: Mon, 23 Jul 2007 14:02:33 +0200 [thread overview]
Message-ID: <20070723120233.GA28222@elte.hu> (raw)
In-Reply-To: <a9e22dff0707222125i49adade7seea63f12672aa701@mail.gmail.com>
* Ni@m <niam.niam@gmail.com> wrote:
> >Please run this script while using mplayer or audacious
> >http://people.redhat.com/mingo/cfs-scheduler/tools/cfs-debug-info.sh
> >and send results
> >
> I did it anyway ... see the attachment. The script has been running
> while mplayer has been running and sound has been interrupting.
firstly, could you check whether the ogg123/mpg321 console apps work
without any audio skipping? If they work fine, does Amarok work fine?
(Amarok is an X apps that has a high-quality latency design - most other
X based players are affected by X communication latencies.)
Can you see any ALSA xruns related to any of the apps that skips sound?
For that, first enable CONFIG_SND_DEBUG and CONFIG_SND_PCM_XRUN_DEBUG
and reboot into such an xrun-debug enabled kernel. Once you have booted
into it, you should see the xrun_debug flag of your audio driver, under
/proc/asound/card*/pcm*/xrun_debug. Do something like this:
echo 1 > /proc/asound/card0/pcm0p/xrun_debug
can you see any ALSA xruns reported to the syslog at the same time the
audio apps are skipping?
Plus if any of the above apps causes audio skipping then to further
debug this, could you try the latency tracer:
http://redhat.com/~mingo/latency-tracing-patches/latency-tracing-v2.6.23-rc1-combo.patch
apply the combo patch to v2.6.23-rc1, enable CONFIG_WAKEUP_TIMING and
CONFIG_FUNCTION_TRACING, boot into the new kernel and do this to start
the latency tracer:
echo 0 > /proc/sys/kernel/preempt_max_latency
you should start seeing such messages in the syslog:
( sshd-2254 |#1): new 2 us maximum-latency wakeup.
( sleep-2310 |#0): new 4 us maximum-latency wakeup.
( auditd-1856 |#1): new 6 us maximum-latency wakeup.
( auditd-1857 |#0): new 9 us maximum-latency wakeup.
( kjournald-1455 |#1): new 10 us maximum-latency wakeup.
( ls-2318 |#1): new 11 us maximum-latency wakeup.
( kjournald-623 |#1): new 15 us maximum-latency wakeup.
( bash-2324 |#1): new 15 us maximum-latency wakeup.
( kjournald-623 |#1): new 50 us maximum-latency wakeup.
( events/0-9 |#0): new 262 us maximum-latency wakeup.
it will increase monotonically - always showing the worst-case latency
it detected. What kind of numbers do you get, while the sound is
skipping? If it's in the milliseconds, then wakeup latencies could be
the cause of your sound skipping. Send the contents of the
/proc/latency_trace file in that case.
( if the reported latencies are low, but sound is skipping too and ALSA
reports xrun, then we can use the tracer to debug audio latencies
directly as well, but that will need an extra patch. )
Ingo
next prev parent reply other threads:[~2007-07-23 12:02 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-21 22:10 Ni@m
2007-07-23 0:16 ` Michal Piotrowski
2007-07-23 3:01 ` Ni@m
2007-07-23 4:25 ` Ni@m
2007-07-23 12:02 ` Ingo Molnar [this message]
2007-07-23 12:28 ` Ingo Molnar
2007-07-28 22:31 ` Ni@m
[not found] ` <a9e22dff0707290415lf7588cfx19155d531c9c5a3f@mail.gmail.com>
2007-07-29 11:16 ` Fwd: " Ni@m
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070723120233.GA28222@elte.hu \
--to=mingo@elte.hu \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.k.k.piotrowski@gmail.com \
--cc=niam.niam@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®