All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Jassi Brar <jassisinghbrar@gmail.com>
Cc: alsa-devel@alsa-project.org, kgene.kim@samsung.com,
	Jassi Brar <jassi.brar@samsung.com>,
	ben-linux@fluff.org, june.bae@samsung.com, lrg@slimlogic.co.uk,
	sw.youn@samsung.com
Subject: Re: [PATCH 11/25] ASoC: Samsung: Add common I2S driver
Date: Tue, 19 Oct 2010 21:01:42 -0700	[thread overview]
Message-ID: <20101020040141.GA22078@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <AANLkTi=5i=51=-m3ZhbTOWyQKz8H3oam6V=QfjL1DxhM@mail.gmail.com>

On Wed, Oct 20, 2010 at 12:27:43PM +0900, Jassi Brar wrote:
> On Wed, Oct 20, 2010 at 12:13 PM, Mark Brown

> > If we have something in the driver data struct specifying the masks to
> > use then set these at probe time rather than having the if statements -
> > probably the same mask can be used for playback & record if the
> > bitfields are lined up similarly.  This would then be:

> >        con |= data->active_mask;
> >        con &= ~data->pause_mask;

> > or similar, possibly with some shifts.

> Let me see if the space saved is worth the complication.

I was thinking it should make something similar by making it clear that
we're just doing the same thing to a different location rather than lots
of conditional code to follow.

> > Please add a comment explaining that you're inverting the orientation
> > you set previously - it's really surprising when reading the code.

> Ok, I'll add a comment.
> Btw, isn't it the standard way? Don't other I2S CPU drivers do the same thing ?

Not commonly - normally people don't implement anything except plain I2S
mode, or have explict mode and inversion bits (so the mode sets the
expected polarity and then the inversion bit swaps that).

> > How would the index be used with multi-component?

> For example, please look at [Patch 23/25]

> +               /* Secondary is at offset MAX_I2S from Primary */
> +               str = (char *)smdk_dai[SEC_PLAYBACK].cpu_dai_name;
> +               str[strlen(str) - 1] = '0' + MAX_I2S;

Hrm, slightly fiddly.  Perhaps we want a function people can call which
will generate the secondary DAI name for you?  Might be more directly
what people want.

  reply	other threads:[~2010-10-20  4:01 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1P85Z9-0007a6-27>
2010-10-19  7:04 ` [PATCH 01/25] ASoC: WM8580: Remove useless assignment Jassi Brar
2010-10-19 10:02   ` Liam Girdwood
2010-10-19 10:21   ` Mark Brown
2010-10-19  7:05 ` [PATCH 02/25] ASoC: Samsung: Remove redundant AQUILA driver Jassi Brar
2010-10-19  7:05 ` [PATCH 03/25] ASoC: Samsung: Rename DMA device Jassi Brar
2010-10-19  7:05 ` [PATCH 04/25] ARM: Samsung: Define common audio-dma device Jassi Brar
2010-10-19  7:54   ` Vasily khoruzhick
2010-10-19  7:05 ` [PATCH 05/25] ASoC: Samsung: Rename ASoC DMA driver Jassi Brar
2010-10-19  7:05 ` [PATCH 06/25] ASoC: Samsung: Rename AC97 platform device Jassi Brar
2010-10-19  7:06 ` [PATCH 07/25] ASoC: Samsung: Rename AC97 driver Jassi Brar
2010-10-19  7:06 ` [PATCH 08/25] ASoC: Samsung: Rename PCM driver Jassi Brar
2010-10-19  7:06 ` [PATCH 09/25] ASoC: Samsung: Generalize DMA driver namespace Jassi Brar
2010-10-19  7:06 ` [PATCH 10/25] ASoC: Samsung: Rename s3c64xx I2S device Jassi Brar
2010-10-19  7:07 ` [PATCH 11/25] ASoC: Samsung: Add common I2S driver Jassi Brar
2010-10-19  9:35   ` Mark Brown
2010-10-20  2:22     ` Jassi Brar
2010-10-20  3:13       ` Mark Brown
2010-10-20  3:27         ` Jassi Brar
2010-10-20  4:01           ` Mark Brown [this message]
2010-10-22  7:39             ` Jassi Brar
2010-10-22 15:28               ` Mark Brown
2010-10-19  7:07 ` [PATCH 12/25] ARM: S3C64XX: I2S: Upgrade platform device Jassi Brar
2010-10-19  7:07 ` [PATCH 13/25] ARM: S5P6440: " Jassi Brar
2010-10-19  7:07 ` [PATCH 14/25] ARM: S5P6442: " Jassi Brar
2010-10-19  7:07 ` [PATCH 15/25] ARM: S5PC100: " Jassi Brar
2010-10-19  7:07 ` [PATCH 16/25] ARM: S5PV210: " Jassi Brar
2010-10-19  7:07 ` [PATCH 17/25] ARM: S5PV310: Add audio platform devices Jassi Brar
2010-10-19  7:07 ` [PATCH 18/25] ASoC: SMARTQ: Move to use new I2S driver Jassi Brar
2010-10-19  7:08 ` [PATCH 19/25] ASoC: GONI: " Jassi Brar
2010-10-19  7:08 ` [PATCH 20/25] ASoC: SMDK64XX: " Jassi Brar
2010-10-19  7:08 ` [PATCH 21/25] ASoC: S3C64XX: Remove obsoleted I2S drivers Jassi Brar
2010-10-19  7:08 ` [PATCH 22/25] ASoC: SMDK64XX: Rename for other platforms Jassi Brar
2010-10-19  7:08 ` [PATCH 23/25] ASoC: SMDK_WM8580: Enable for SMDKC100 Jassi Brar
2010-10-19  7:09 ` [PATCH 24/25] ASoC: Samsung: Generalize Kconfig symbols Jassi Brar
2010-10-19  7:09 ` [PATCH 25/25] ASoC: Samsung: Rename from s3c24xx to samsung Jassi Brar
2010-10-19  8:16   ` Mark Brown
2010-10-19  8:34     ` Jassi Brar
2010-10-19  8:16 ` Jassi Brar

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=20101020040141.GA22078@opensource.wolfsonmicro.com \
    --to=broonie@opensource.wolfsonmicro.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=ben-linux@fluff.org \
    --cc=jassi.brar@samsung.com \
    --cc=jassisinghbrar@gmail.com \
    --cc=june.bae@samsung.com \
    --cc=kgene.kim@samsung.com \
    --cc=lrg@slimlogic.co.uk \
    --cc=sw.youn@samsung.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.