LKML Archive on
help / color / mirror / Atom feed
From: Nicolin Chen <>
To: Zidan Wang <>
Cc: Zidan Wang <>,,,,,,,,,
Subject: Re: [alsa-devel][PATCH 2/3] ASoC: fsl_sai: Add support for tdm slots operation
Date: Fri, 23 Jan 2015 00:27:09 -0800	[thread overview]
Message-ID: <20150123082708.GA3408@Alpha> (raw)
In-Reply-To: <20150123025507.GA2382@b50113>

On Fri, Jan 23, 2015 at 10:55:09AM +0800, Zidan Wang wrote:
> I have another question.
> Can a channel have several slots? Or channel just means slot.

Strictly speaking, a channel surely may have several slots IMO.
The idea for TDM, even for I2S, left channel can bear multiple
slots -- each may be masked and then received by a different

The reason I've said that much against your code is not fully
objection against your idea of using Slot Per Channel but for
the implementation -- you divided them and then multiplied them
again while your true motivation was just to calculate the bclk.
And I could not understand it without seeing your later explain.
Code and things would be much easier if you make it straight

But actually I don't mind if you feel comfortable to make a
detour like that, but as I commented at the first place. Code
like that should be companied with comments to tell its meaning.
And I still don't fully understand why you override the channels
for monaural cases.

> > And another problem of your patch is the configurations for FRSZ and
> > xMR fields. For monaural case, the channels == 1, the current code
> > passes it directly to set them while your code overrides it to 2.
> > 
> > I'm not sure if you've tested the monaural case and confirmed it works.
> > But, apparently, the configurations look pretty different.

> I have tested the mono case, it works well.

I just ran a simple test with speaker-test -Dhw:0 -c1, it works
but the FRSZ value is changed to 0x1 for a monaural case (0x0
originally). Setting FRSZ to 0x0 makes more sense to me since
it looks like the configuration for active slot number. But
that depends on the internal logic design of SAI so it may be
better for you to double check with IC owner and run more tests.
If you confirm that, I for sure will be willing to ignore the
change here.


  reply	other threads:[~2015-01-23  8:27 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-20 12:21 [alsa-devel][PATCH 0/3] Add master mode, tmd and right-j mode support Zidan Wang
2015-01-20 12:21 ` [alsa-devel][PATCH 1/3] SoC: fsl_sai: add sai master " Zidan Wang
2015-01-21  6:07   ` Nicolin Chen
2015-01-21  9:25     ` Zidan Wang
2015-01-21 17:36       ` Nicolin Chen
2015-01-20 12:21 ` [alsa-devel][PATCH 2/3] ASoC: fsl_sai: Add support for tdm slots operation Zidan Wang
2015-01-21 18:08   ` Nicolin Chen
2015-01-22  4:55     ` Zidan Wang
2015-01-22  5:44       ` Nicolin Chen
2015-01-22  6:20         ` Zidan Wang
2015-01-22 23:50           ` Nicolin Chen
2015-01-23  2:55             ` Zidan Wang
2015-01-23  8:27               ` Nicolin Chen [this message]
2015-01-20 12:21 ` [alsa-devel][PATCH 3/3] ASoC: fsl_sai: Add support for Right-J mode Zidan Wang
2015-01-21 18:53   ` Nicolin Chen
2015-01-22  5:13     ` Zidan Wang
2015-01-22  5:46       ` Nicolin Chen
2015-01-21  1:15 ` [alsa-devel] [PATCH 0/3] Add master mode, tmd and right-j mode support Fabio Estevam
2015-01-21  6:29   ` Nicolin Chen

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150123082708.GA3408@Alpha \ \ \ \ \ \ \ \ \ \ \ \ \
    --subject='Re: [alsa-devel][PATCH 2/3] ASoC: fsl_sai: Add support for tdm slots operation' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

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).