devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bo Shen <voice.shen@atmel.com>
To: Richard Genoud <richard.genoud@gmail.com>
Cc: devicetree-discuss@lists.ozlabs.org,
	"Nicolas Ferre" <nicolas.ferre@atmel.com>,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	"Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Subject: Re: [RFC PATCH 08/13] sound: sam9x5_wm8731: machine driver for at91sam9x5 wm8731 boards
Date: Mon, 8 Jul 2013 10:01:25 +0800	[thread overview]
Message-ID: <51DA1D75.2010503@atmel.com> (raw)
In-Reply-To: <CACQ1gAji8KkjXee8o=9jt8O38611LBJ95yXimxbfn1qLaLOcnA@mail.gmail.com>

Hi Richard,

On 7/5/2013 23:15, Richard Genoud wrote:
>>> +       card->dev = &pdev->dev;
>>> >>+       card->owner = THIS_MODULE;
>>> >>+       card->dai_link = dai;
>>> >>+       card->num_links = 1;
>>> >>+       dai->name = "WM8731";
>>> >>+       dai->stream_name = "WM8731 PCM";
>>> >>+       dai->codec_dai_name = "wm8731-hifi";
>>> >>+       dai->init = at91sam9x5ek_wm8731_init;
>>> >>+       card->dapm_widgets = at91sam9x5ek_dapm_widgets;
>>> >>+       card->num_dapm_widgets = ARRAY_SIZE(at91sam9x5ek_dapm_widgets);
>> >
>> >
>> >Will keep these as snd_soc_card and snd_soc_dai_link structure separately?
> I don't really understand what you mean here.
> do you mean that something like that will more explicit ? :
> +       card->dai_link[0].name = "WM8731";
> +       card->dai_link[0].stream_name = "WM8731 PCM";
> +       card->dai_link[0].codec_dai_name = "wm8731-hifi";
> +       card->dai_link[0].init = at91sam9x5ek_wm8731_init;
>

I mean using structure to define snd_soc_card and snd_soc_dai_link, look 
like:
struct snd_soc_dai_link dai_link_name = {
	.name = xxx,
	.stream_name = xxx,
	...
};

struct snd_soc_card card_name = {
	.name = xxxx
	.ower = THIS_MODULE,
	.dai_link = &dai_link_name,
	...
};

In this way, I think it will be more clear than put them in code.

Best Regards,
Bo Shen

  parent reply	other threads:[~2013-07-08  2:01 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-01  8:39 [RFC PATCH 00/13] audio support for at91sam9x5ek board Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 01/13] misc: atmel_ssc: add device tree DMA support Richard Genoud
2013-07-02  3:01   ` Bo Shen
2013-07-02  8:13     ` Richard Genoud
2013-07-02  9:11       ` Bo Shen
2013-07-03 12:21         ` Richard Genoud
2013-07-03 15:51           ` Richard Genoud
2013-07-04  1:15             ` Bo Shen
     [not found]               ` <51D4CC94.3020908-AIFe0yeh4nAAvxtiuMwx3w@public.gmane.org>
2013-07-04 13:44                 ` Richard Genoud
2013-07-05  1:25                   ` Bo Shen
2013-07-05  7:16                     ` Richard Genoud
     [not found] ` <1372667978-4718-1-git-send-email-richard.genoud-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2013-07-01  8:39   ` [RFC PATCH 02/13] misc: atmel_ssc: keep the count of pdev->id Richard Genoud
2013-07-02  3:03     ` Bo Shen
2013-07-05 15:16       ` Richard Genoud
2013-07-01  8:39   ` [RFC PATCH 04/13] ARM: at91: DTS: sam9x5: add SSC DMA parameters Richard Genoud
2013-07-01  8:39   ` [RFC PATCH 06/13] ARM: AT91: DTS: sam9x5ek: add sound configuration Richard Genoud
2013-07-01  8:39   ` [RFC PATCH 07/13] ARM: AT91: DTS: sam9x5ek: enable SSC Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 03/13] ARM: at91: DTS: sam9x5: add clock for SSC DT entry Richard Genoud
2013-07-02  3:05   ` Bo Shen
2013-07-05 15:16     ` Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 05/13] ARM: AT91: DTS: sam9x5ek: add WM8731 codec Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 08/13] sound: sam9x5_wm8731: machine driver for at91sam9x5 wm8731 boards Richard Genoud
2013-07-02  3:21   ` Bo Shen
2013-07-05 15:15     ` Richard Genoud
     [not found]       ` <CACQ1gAji8KkjXee8o=9jt8O38611LBJ95yXimxbfn1qLaLOcnA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-07-05 18:06         ` Mark Brown
2013-07-05 18:12           ` Richard Genoud
2013-07-08  2:01       ` Bo Shen [this message]
2013-07-08  7:55         ` Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 09/13] sound: atmel-pcm: don't return ok if pcm-dma is not implemented Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 10/13] sound: atmel_ssc_dai: PM: actually stopping clock on suspend/resume Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 11/13] sound: atmel-pcm-dma: check pointer before dereference Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 12/13] sound: wm8731: rework power management Richard Genoud
2013-07-01  8:39 ` [RFC PATCH 13/13] sound: codec: wm8371: correct capture line/mic Richard Genoud

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=51DA1D75.2010503@atmel.com \
    --to=voice.shen@atmel.com \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nicolas.ferre@atmel.com \
    --cc=richard.genoud@gmail.com \
    --cc=u.kleine-koenig@pengutronix.de \
    /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).