linux-arm-msm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Cheng-yi Chiang <cychiang@chromium.org>
To: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Cc: Tzung-Bi Shih <tzungbi@google.com>,
	Taniya Das <tdas@codeaurora.org>,
	ALSA development <alsa-devel@alsa-project.org>,
	Banajit Goswami <bgoswami@codeaurora.org>,
	Takashi Iwai <tiwai@suse.com>,
	Rohit kumar <rohitkr@codeaurora.org>,
	Patrick Lai <plai@codeaurora.org>, Andy Gross <agross@kernel.org>,
	Dylan Reid <dgreid@chromium.org>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
	<devicetree@vger.kernel.org>,
	Tzung-Bi Shih <tzungbi@chromium.org>,
	Stephan Gerhold <stephan@gerhold.net>,
	linux-arm-msm <linux-arm-msm@vger.kernel.org>,
	Stephen Boyd <swboyd@chromium.org>,
	Rob Herring <robh+dt@kernel.org>,
	Bjorn Andersson <bjorn.andersson@linaro.org>,
	"moderated list:ARM/Mediatek SoC support" 
	<linux-arm-kernel@lists.infradead.org>,
	Douglas Anderson <dianders@chromium.org>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>,
	Judy Hsiao <judyhsiao@chromium.org>
Subject: Re: [PATCH] ASoC: max98357a: set channels_max to 4
Date: Wed, 16 Jun 2021 18:14:05 +0800	[thread overview]
Message-ID: <CAFv8Nw+FNfmgwadeFMWjRiGbKFuO4JJ=9ggRHxG+Pq_OuHdmeA@mail.gmail.com> (raw)
In-Reply-To: <3501e398-dfba-43b1-4638-325a158e860d@linux.intel.com>

On Wed, Jun 16, 2021 at 12:00 AM Pierre-Louis Bossart
<pierre-louis.bossart@linux.intel.com> wrote:
>
>
>
> On 6/15/21 10:47 AM, Cheng-yi Chiang wrote:
> > Hi Tzung-Bi,
> >
> > On a platform, the four max98357a amps will be controlled by only one
> > codec device, as GPIO for SD_MODE is shared by all amps and is the
> > only thing to be controlled.
> > In this sense, I think we can treat max98357a DAI as if it supports
> > four channels.
> > I understand that this solution is not scalable, because one can
> > control as many amps as they want.
> > Theoretically, the number of supported channels by this codec device
> > is unlimited.
> > I found that rt1015.c has similar usage.
> > Do you have a better suggestion to support this kind of use case ?
> > Thanks!
>
> please don't top-post...
Hi Pierre-Louis,

I am sorry about that!
>
>
> I don't think it's correct to declare 4-channel support at the
> individual codec DAI level when in practice each device will be provided
> with a TDM mask that selects two slots.

On this platform there is no TDM support, so there were two I2S data lines.

>
> This is confusing device capabilities and TDM link configuration.

I see that in most of the use cases of multiple amps, we should use
codecs and num_codecs of the link.
But in this case we only want one codec to control the only GPIO
shared by 4 max98357a amps
I think we should be able to use 1 max98357 codec and 3 dummy codec to
fulfill this use case.
Not sure if the number of dummy codec would really matter.
With num_codec > 1 we should be able to bypass the channel checking
and just use the channel from CPU DAI.
Thanks for the suggestion.


>
> > On Tue, Jun 1, 2021 at 2:20 PM Tzung-Bi Shih <tzungbi@google.com> wrote:
> >>
> >> On Wed, May 26, 2021 at 11:47 PM Judy Hsiao <judyhsiao@chromium.org> wrote:
> >>> Sets channels_max to 4 to support QUAD channel.
> >>
> >> Could you point out probably the up-to-date MAX98357A datasheet for
> >> 4-channel support?
> >>
> >> On a related note, from the public datasheet I could find[1], "Table
> >> 5" only shows 2 channel's configuration.
> >>
> >> [1]: https://pdf1.alldatasheet.com/datasheet-pdf/view/623796/MAXIM/MAX98357A.html

  reply	other threads:[~2021-06-16 10:14 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-26 15:47 [PATCH] ASoC: max98357a: set channels_max to 4 Judy Hsiao
2021-06-01  6:20 ` Tzung-Bi Shih
2021-06-15 15:47   ` Cheng-yi Chiang
2021-06-15 16:00     ` Pierre-Louis Bossart
2021-06-16 10:14       ` Cheng-yi Chiang [this message]
2021-06-16 16:23         ` Pierre-Louis Bossart
2021-06-16 20:40           ` 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='CAFv8Nw+FNfmgwadeFMWjRiGbKFuO4JJ=9ggRHxG+Pq_OuHdmeA@mail.gmail.com' \
    --to=cychiang@chromium.org \
    --cc=agross@kernel.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=bgoswami@codeaurora.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dgreid@chromium.org \
    --cc=dianders@chromium.org \
    --cc=judyhsiao@chromium.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=pierre-louis.bossart@linux.intel.com \
    --cc=plai@codeaurora.org \
    --cc=robh+dt@kernel.org \
    --cc=rohitkr@codeaurora.org \
    --cc=stephan@gerhold.net \
    --cc=swboyd@chromium.org \
    --cc=tdas@codeaurora.org \
    --cc=tiwai@suse.com \
    --cc=tzungbi@chromium.org \
    --cc=tzungbi@google.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;
as well as URLs for NNTP newsgroup(s).