From: Vinod Koul <vinod.koul@intel.com>
To: Mark Brown <broonie@kernel.org>
Cc: alsa-devel@alsa-project.org, subhransu.s.prusty@intel.com,
lgirdwood@gmail.com
Subject: Re: [PATCH v9 1/6] ASoC: Intel: mrfld: add the gain controls
Date: Wed, 15 Oct 2014 18:09:38 +0530 [thread overview]
Message-ID: <20141015123938.GN1638@intel.com> (raw)
In-Reply-To: <20141015130817.GF27755@sirena.org.uk>
[-- Attachment #1.1: Type: text/plain, Size: 1573 bytes --]
On Wed, Oct 15, 2014 at 03:08:17PM +0200, Mark Brown wrote:
> On Wed, Oct 15, 2014 at 03:53:03PM +0530, Vinod Koul wrote:
> > On Wed, Oct 15, 2014 at 12:49:47PM +0200, Mark Brown wrote:
> > > On Wed, Oct 15, 2014 at 12:34:56PM +0530, Vinod Koul wrote:
>
> > > > +/* the SST_GAIN macro above will create three alsa controls for each
> > > > + * instance invoked, gain, mute and ramp duration, which use the same gain
> > > > + * cell sst_gain to keep track of data
> > > > + *
> > > > + * To calculate number of gain cell instances we need to device by 3 in
> > > > + * below caulcation for gain cell memory.
> > > > + * This gets rid of static number and issues while adding new controls
> > > > + */
> > > > +static struct sst_gain_value sst_gains[ARRAY_SIZE(sst_gain_controls)/3];
>
> > > The use of ARRAY_SIZE() is nice here but I'm a bit confused about the
> > > divide by 3 - there's an entry in sst_gains referenced for each element
> > > in sst_gain_controls.
>
> > Thats is the reason added the comment above.
>
> The comment isn't very clear (splitting it into multiple paragraphs
> doesn't help since it looks like the calculation stands separately to
> the controls), and everything would be a lot simpler if there were a
> define for the number of controls created per SST_GAIN() rather than
> just hard coding the magic number.
Ah my mistake wasnt intended to be multiple para. I will remove the blank
like and yes add SST_GAIN_SIZE as 3 and using that would be better.
I resend this patch with this change :)
--
~Vinod
[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
[-- Attachment #2: Type: text/plain, Size: 0 bytes --]
next prev parent reply other threads:[~2014-10-15 13:15 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-15 7:04 [PATCH v9 0/6] Add mrfld DSP topology and widgets Vinod Koul
2014-10-15 7:04 ` [PATCH v9 1/6] ASoC: Intel: mrfld: add the gain controls Vinod Koul
2014-10-15 10:49 ` Mark Brown
2014-10-15 10:23 ` Vinod Koul
2014-10-15 13:08 ` Mark Brown
2014-10-15 12:39 ` Vinod Koul [this message]
2014-10-15 7:04 ` [PATCH v9 2/6] ASoC: Intel: mrfld: add DSP core controls Vinod Koul
2014-10-15 13:15 ` Mark Brown
2014-10-15 12:47 ` Vinod Koul
2014-10-15 14:05 ` Mark Brown
2014-10-15 13:45 ` Vinod Koul
2014-10-15 15:08 ` Mark Brown
2014-10-15 14:38 ` Vinod Koul
2014-10-15 7:04 ` [PATCH v9 3/6] ASoC: Intel: mrfld: add the DSP DAPM widgets Vinod Koul
2014-10-15 7:04 ` [PATCH v9 4/6] ASoC: core: Call mute for cpu dais as well Vinod Koul
2014-10-15 9:46 ` Mark Brown
2014-10-15 7:05 ` [PATCH v9 5/6] ASoC: Intel: mfld-pcm: add FE and BE ops Vinod Koul
2014-10-15 7:05 ` [PATCH v9 6/6] ASoC: Intel: mrfld: add the DSP mixers Vinod Koul
2014-10-15 12:46 ` [PATCH v9.1 1/6] ASoC: Intel: mrfld: add the gain controls Vinod Koul
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=20141015123938.GN1638@intel.com \
--to=vinod.koul@intel.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=subhransu.s.prusty@intel.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