alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
From: sutar.mounesh@gmail.com
To: patch@alsa-project.org
Cc: alsa-devel@alsa-project.org,
	Anant Agrawal <Anant_Agrawal@mentor.com>,
	mounesh_sutar@mentor.com
Subject: [PATCH] alsa-lib: alsa dshare endless playback of buffer
Date: Fri, 25 Nov 2016 16:43:34 +0530	[thread overview]
Message-ID: <1480072414-17398-1-git-send-email-sutar.mounesh@gmail.com> (raw)

From: Anant Agrawal <Anant_Agrawal@mentor.com>

On snd_pcm_drain() the slave PCM driven via plugin DSHARE is not filled with
silence. Result is endless playback of buffer content until pcm is closed.
In ALSA pcm dshare plugin, called do_silence method to fix the issue.

Signed-off-by: Anant Agrawal <Anant_Agrawal@mentor.com>

---
--- alsa-lib-1.0.29.orig/src/pcm/pcm_dshare.c	2015-04-28 08:20:44.662995477 -0700
+++ alsa-lib-1.0.29/src/pcm/pcm_dshare.c	2015-04-28 08:20:59.603077419 -0700
@@ -195,6 +195,7 @@
 		dshare->avail_max = avail;
 	if (avail >= pcm->stop_threshold) {
 		snd_timer_stop(dshare->timer);
+		do_silence(pcm);
 		gettimestamp(&dshare->trigger_tstamp, pcm->tstamp_type);
 		if (dshare->state == SND_PCM_STATE_RUNNING) {
 			dshare->state = SND_PCM_STATE_XRUN;

             reply	other threads:[~2016-11-25 11:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-25 11:13 sutar.mounesh [this message]
2016-11-28 19:17 ` [PATCH] alsa-lib: alsa dshare endless playback of buffer Takashi Iwai

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=1480072414-17398-1-git-send-email-sutar.mounesh@gmail.com \
    --to=sutar.mounesh@gmail.com \
    --cc=Anant_Agrawal@mentor.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=mounesh_sutar@mentor.com \
    --cc=patch@alsa-project.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).