From: Thomas Voegtle <tv@lio96.de>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: linux-kernel@vger.kernel.org, jgarzik@pobox.com
Subject: Re: [rfc] i810_audio: offset LVI from CIV to avoid stalled start
Date: Wed, 19 Jan 2005 09:59:43 +0100 (CET) [thread overview]
Message-ID: <Pine.LNX.4.58.0501190954590.28787@er-systems.de> (raw)
In-Reply-To: <20050118224248.GA17785@gondor.apana.org.au>
On Wed, 19 Jan 2005, Herbert Xu wrote:
> On Tue, Jan 18, 2005 at 01:07:47PM -0500, John W. Linville wrote:
> >
> > No, that does not fix it. :-( In fact, it doesn't seem to alter the
> > problem at all...
>
> OK. In that case I agree with your patch. The overruns that I
> attributed to it were probably caused by other bugs that's been
> fixed since.
>
> Cheers,
>
Here is the same patch against 2.6.11-rc1-bk6. Works for me.
--- linux-2.6.11-rc1-bk6/sound/oss/i810_audio.c.old 2005-01-19 09:47:20.438345600 +0100
+++ linux-2.6.11-rc1-bk6/sound/oss/i810_audio.c 2005-01-19 09:48:43.618700264 +0100
@@ -1196,10 +1196,20 @@
if (count < fragsize)
return;
+ /* if we are currently stopped, then our CIV is actually set to our
+ * *last* sg segment and we are ready to wrap to the next. However,
+ * if we set our LVI to the last sg segment, then it won't wrap to
+ * the next sg segment, it won't even get a start. So, instead, when
+ * we are stopped, we set both the LVI value and also we increment
+ * the CIV value to the next sg segment to be played so that when
+ * we call start, things will operate properly
+ */
if (!dmabuf->enable && dmabuf->ready) {
if (!(dmabuf->trigger & trigger))
return;
+ CIV_TO_LVI(state->card, port, 1);
+
start(state);
while (!(I810_IOREADB(state->card, port + OFF_CR) & ((1<<4) | (1<<2))))
;
--
Thomas Vögtle email: thomas@voegtle-clan.de
----- http://www.voegtle-clan.de/thomas ------
prev parent reply other threads:[~2005-01-19 9:03 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-01-17 18:37 [rfc] i810_audio: offset LVI from CIV to avoid stalled start John W. Linville
2005-01-17 18:46 ` [patch 2.4.29-rc1] " John W. Linville
2005-01-17 22:54 ` Thomas Voegtle
2005-01-17 20:39 ` [rfc] " Herbert Xu
2005-01-17 21:44 ` John W. Linville
2005-01-17 23:23 ` Herbert Xu
2005-01-18 18:07 ` John W. Linville
2005-01-18 22:42 ` Herbert Xu
2005-01-19 8:59 ` Thomas Voegtle [this message]
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=Pine.LNX.4.58.0501190954590.28787@er-systems.de \
--to=tv@lio96.de \
--cc=herbert@gondor.apana.org.au \
--cc=jgarzik@pobox.com \
--cc=linux-kernel@vger.kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).