From: "Liao, Bard" <bard.liao@intel.com>
To: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>,
Bard liao <yung-chuan.liao@linux.intel.com>
Cc: "tiwai@suse.de" <tiwai@suse.de>,
"liam.r.girdwood@linux.intel.com"
<liam.r.girdwood@linux.intel.com>,
"alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
"broonie@kernel.org" <broonie@kernel.org>,
"pierre-louis.bossart@linux.intel.com"
<pierre-louis.bossart@linux.intel.com>
Subject: Re: [alsa-devel] [PATCH RFC 1/3] ASoC: Add initial support for multiple CPU DAIs
Date: Thu, 26 Dec 2019 09:15:38 +0000 [thread overview]
Message-ID: <567A313375B6F043A9BE3A1D9B8C6E7F0B4D2C61@SHSMSX101.ccr.corp.intel.com> (raw)
In-Reply-To: <87tv5nsdqo.wl-kuninori.morimoto.gx@renesas.com>
> -----Original Message-----
> From: Kuninori Morimoto [mailto:kuninori.morimoto.gx@renesas.com]
> Sent: Thursday, December 26, 2019 4:17 PM
> To: Bard liao <yung-chuan.liao@linux.intel.com>
> Cc: broonie@kernel.org; alsa-devel@alsa-project.org; tiwai@suse.de;
> liam.r.girdwood@linux.intel.com; pierre-louis.bossart@linux.intel.com; Liao,
> Bard <bard.liao@intel.com>
> Subject: Re: [PATCH RFC 1/3] ASoC: Add initial support for multiple CPU DAIs
>
>
> Hi Bard
>
> Actually I have plan to post semi-multi CPU DAI support as part of ASoC cleanup.
> The reason why "semi-multi" is that I can't test all features.
> It cares Multi-CPU as much as possible.
>
> Thus, your and my patches are 100% conflict :) But, it is OK for me.
> I'm happy to adjust to yours.
>
> Some comment from me
>
> > From: Shreyas NC <shreyas.nc@intel.com>
> >
> > ASoC core supports multiple codec DAIs but supports only a CPU DAI.
> > To support multiple cpu DAIs, add cpu_dai and num_cpu_dai in
> > snd_soc_dai_link and snd_soc_pcm_runtime structures similar to support
> > for codec_dai. This is intended as a preparatory patch to eventually
> > support the unification of the Codec and CPU DAI.
> >
> > Inline with multiple codec DAI approach, add support to allocate,
> > init, bind and probe multiple cpu_dai on init if driver specifies
> > that. Also add support to loop over multiple cpu_dai during suspend
> > and resume.
> >
> > This is intended as a preparatory patch to eventually unify the CPU
> > and Codec DAI into DAI components.
> >
> > Signed-off-by: Shreyas NC <shreyas.nc@intel.com>
> > Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>
> > ---
> (snip)
> > @@ -1149,6 +1154,9 @@ struct snd_soc_pcm_runtime {
> > struct snd_soc_dai **codec_dais;
> > unsigned int num_codecs;
> >
> > + struct snd_soc_dai **cpu_dais;
> > + unsigned int num_cpu_dai;
>
> Codec is using "num_codecs";
> So, I think "num_cpus" is better for CPU.
Agree. I will update it.
>
>
> > @@ -1020,14 +1036,6 @@ static int soc_dai_link_sanity_check(struct
> snd_soc_card *card,
> > return -EPROBE_DEFER;
> > }
> >
> > - /* FIXME */
> > - if (link->num_cpus > 1) {
> > - dev_err(card->dev,
> > - "ASoC: multi cpu is not yet supported %s\n",
> > - link->name);
> > - return -EINVAL;
> > - }
> > -
> > /*
> > * CPU device may be specified by either name or OF node, but
> > * can be left unspecified, and will be matched based on DAI
>
> I think you want to sanity check for each CPU DAI by using
> for_each_rtd_cpu_dai() here, not only removing FIXME ?
Sure, thanks for reminding.
>
>
>
>
> In my quick check, I think your patch-set doesn't care these functions ?
> # Mine version is also doesn't care. Thus it indicates warning message there.
> # Because I'm not sure how to handle these...
>
> - soc_init_pcm_runtime()
> - snd_dmaengine_pcm_prepare_slave_config()
> - dmaengine_pcm_set_runtime_hwparams()
> - dmaengine_pcm_compat_request_channel()
> - dpcm_state_read_file()
> - dpcm_path_get()
> - dpcm_runtime_merge_chan()
> - soc_new_pcm()
> - soc_dpcm_fe_runtime_update()
>
> For soc_new_pcm(), I think you need to care playback/capture flag for Multi-
> CPU/Codec.
>
> For soc_dpcm_fe_runtime_update(),
> you need to care about Multi-CPU.
> But, it doesn't care Multi-Codec, either...
>
> I attached mine version.
Thank you very much for the comments and patch.
I will read your version and merge our versions.
Thanks again for the quick reply.
>
> Thank you for your help !!
> Best regards
> ---
> Kuninori Morimoto
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
https://mailman.alsa-project.org/mailman/listinfo/alsa-devel
next prev parent reply other threads:[~2019-12-26 9:16 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-25 19:14 [alsa-devel] [PATCH RFC 0/3] ASoC: Add Multi CPU DAI support Bard liao
2019-12-25 19:14 ` [alsa-devel] [PATCH RFC 1/3] ASoC: Add initial support for multiple CPU DAIs Bard liao
2019-12-26 8:16 ` Kuninori Morimoto
2019-12-26 9:15 ` Liao, Bard [this message]
2019-12-25 19:15 ` [alsa-devel] [PATCH RFC 2/3] ASoC: Add multiple CPU DAI support for PCM ops Bard liao
2019-12-25 19:15 ` [alsa-devel] [PATCH RFC 3/3] ASoC: Add multiple CPU DAI support in DAPM Bard liao
2020-01-14 15:47 ` [alsa-devel] [PATCH RFC 0/3] ASoC: Add Multi CPU DAI support Mark Brown
2020-01-15 0:20 ` Liao, Bard
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=567A313375B6F043A9BE3A1D9B8C6E7F0B4D2C61@SHSMSX101.ccr.corp.intel.com \
--to=bard.liao@intel.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=kuninori.morimoto.gx@renesas.com \
--cc=liam.r.girdwood@linux.intel.com \
--cc=pierre-louis.bossart@linux.intel.com \
--cc=tiwai@suse.de \
--cc=yung-chuan.liao@linux.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;
as well as URLs for NNTP newsgroup(s).