From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: "Lopez Cruz, Misael" <x0052729@ti.com>
Cc: "alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>
Subject: Re: [PATCHv2 1/7] OMAP4: PMIC: Add support for twl6030 codec
Date: Mon, 28 Sep 2009 14:56:06 +0100 [thread overview]
Message-ID: <20090928135606.GI31899@rakim.wolfsonmicro.main> (raw)
In-Reply-To: <67059DBF19D7214F9C66BB0EA91BA90E90A391DF@dlee04.ent.ti.com>
On Fri, Sep 25, 2009 at 09:02:32PM -0500, Lopez Cruz, Misael wrote:
> +#if defined(CONFIG_SND_SOC_TWL6030)
> +#define twl_has_codec() true
> +#else
> +#define twl_has_codec() false
> +#endif
This ifdef won't match if the CODEC driver is modular.
> +
> + if (twl_has_codec() && pdata->codec) {
> + child = add_child(CODEC_SUB_CHIP_ID, "twl6030_codec",
> + pdata->codec, sizeof(*pdata->codec), false,
> + 0, 0);
> + if (IS_ERR(child))
> + return PTR_ERR(child);
> + }
I'd be inclined to print a warning here if no platform data is supplied,
or have the CODEC handle missing platform data to make it easier for
people to diagnose any problems with instantiating the device.
prev parent reply other threads:[~2009-09-28 13:56 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-26 2:02 [PATCHv2 1/7] OMAP4: PMIC: Add support for twl6030 codec Lopez Cruz, Misael
2009-09-28 13:56 ` Mark Brown [this message]
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=20090928135606.GI31899@rakim.wolfsonmicro.main \
--to=broonie@opensource.wolfsonmicro.com \
--cc=alsa-devel@alsa-project.org \
--cc=linux-omap@vger.kernel.org \
--cc=x0052729@ti.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