From: Ashish Chavan <ashish.chavan@kpitcummins.com>
To: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: <lrg@ti.com>, alsa-devel <alsa-devel@alsa-project.org>,
David Dajun Chen <david.chen@diasemi.com>,
<kuninori.morimoto.gx@renesas.com>,
linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [alsa-devel] [PATCH 7/9] ASoC: da7210: Add support for ALC and Noise suppression
Date: Thu, 13 Oct 2011 14:45:45 +0530 [thread overview]
Message-ID: <1318497345.12107.443.camel@matrix> (raw)
In-Reply-To: <20111012150404.GT3647@opensource.wolfsonmicro.com>
On Wed, 2011-10-12 at 16:04 +0100, Mark Brown wrote:
> On Wed, Oct 12, 2011 at 08:37:50PM +0530, Ashish Chavan wrote:
>
> > + if (ucontrol->value.integer.value[0]) {
> > + /* Check if noise suppression is enabled */
> > + if (reg_cache[DA7210_CONTROL] & DA7210_NOISE_SUP_EN) {
>
> No, don't go peering directly into the register cache. This is going to
> explode if the board configures a different cache style and means you
> can't change the cache type later. Just read the register and trust
> that the cache will do something sane.
Will update the code to directly read the register. I thought of saving
some io bandwidth and if I remember correctly, I saw few exiting drivers
doing this.
>
> > + dev_dbg(codec->dev, "Failed to enable ALC\n");
> > + return -EPERM;
> > + }
>
> Either drop the debug print or make it say what the problem is.
Will add more specific info about error.
>
> similar problems in the rest of the patch.
>
> > + SOC_SINGLE("ALC Capture Max Gain", DA7210_ALC_MAX, 0, 0x3F, 0),
> > + SOC_SINGLE("ALC Capture Min Gain", DA7210_ALC_MIN, 0, 0x3F, 0),
> > + SOC_SINGLE("ALC Capture Noise Gain", DA7210_ALC_NOIS, 0, 0x3F, 0),
>
> Volume.
>
next prev parent reply other threads:[~2011-10-13 9:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-12 15:07 [alsa-devel] [PATCH 7/9] ASoC: da7210: Add support for ALC and Noise suppression Ashish Chavan
2011-10-12 15:04 ` Mark Brown
2011-10-13 9:15 ` Ashish Chavan [this message]
2011-10-13 10:26 ` 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=1318497345.12107.443.camel@matrix \
--to=ashish.chavan@kpitcummins.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@opensource.wolfsonmicro.com \
--cc=david.chen@diasemi.com \
--cc=kuninori.morimoto.gx@renesas.com \
--cc=linux-kernel@vger.kernel.org \
--cc=lrg@ti.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