The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Charles Keepax <ckeepax@opensource.cirrus.com>
To: Jerome Brunet <jbrunet@baylibre.com>
Cc: Mark Brown <broonie@kernel.org>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Kevin Hilman <khilman@baylibre.com>,
	<alsa-devel@alsa-project.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [alsa-devel] [PATCH RFC] ASoC: dai playback_active and capture_active may be greater than 1
Date: Mon, 30 Apr 2018 16:10:04 +0100	[thread overview]
Message-ID: <20180430151004.edal7xei4okf7hao@localhost.localdomain> (raw)
In-Reply-To: <20180419140612.11049-1-jbrunet@baylibre.com>

On Thu, Apr 19, 2018 at 04:06:12PM +0200, Jerome Brunet wrote:
> At the moment playback_active and capture_active are using only 1 bit so
> the maximum active count is 1.
> 
> However, snd_soc_runtime_activate() may be called several time on the
> same dai. This happens when a dai is part of several dai_links. It is
> often the case for "snd-soc-dummy-dai".
> 
> This is a problem if snd_soc_runtime_activate() is called an even number
> of times on a dai. In this case the active count overflow back to 0. As
> consequence, ASoC functions, such as soc_dpcm_runtime_update(), won't run
> correctly.
> 
> Storing these usage counts on plain 'unsigned int' solves the problem.
> 
> Fixes: f0fba2ad1b6b ("ASoC: multi-component - ASoC Multi-Component Support")
> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
> ---

Reviewed-by: Charles Keepax <ckeepax@opensource.cirrus.com>

Thanks,
Charles

  reply	other threads:[~2018-04-30 15:10 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-19 14:06 [PATCH RFC] ASoC: dai playback_active and capture_active may be greater than 1 Jerome Brunet
2018-04-30 15:10 ` Charles Keepax [this message]
2018-05-01 21:07 ` Applied "ASoC: dai playback and capture active may be greater than 1" to the asoc tree Mark Brown

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=20180430151004.edal7xei4okf7hao@localhost.localdomain \
    --to=ckeepax@opensource.cirrus.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=jbrunet@baylibre.com \
    --cc=khilman@baylibre.com \
    --cc=lgirdwood@gmail.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