From: Mark Brown <broonie@kernel.org>
To: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
Cc: Liam Girdwood <lgirdwood@gmail.com>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org,
Support Opensource <support.opensource@diasemi.com>,
Sathyanarayana Nujella <sathyanarayana.nujella@intel.com>
Subject: Re: [PATCH 1/3] ASoC: da7219: Convert driver to use generic device/fwnode functions
Date: Fri, 6 May 2016 13:26:43 +0100 [thread overview]
Message-ID: <20160506122643.GS6292@sirena.org.uk> (raw)
In-Reply-To: <4783487c3caa1d66f0a1d5b25c9b341aee1118e4.1462285398.git.Adam.Thomson.Opensource@diasemi.com>
[-- Attachment #1: Type: text/plain, Size: 921 bytes --]
On Thu, May 05, 2016 at 11:53:04AM +0100, Adam Thomson wrote:
> This change converts the driver from using the of_* functions to using
> the device_* and fwnode_* functions for accssing DT related data.
> This is in preparation for updates to support ACPI based initialisation.
Is this *really* sensible? DT idioms don't always match up with ACPI
idioms well and this isn't a trivial DT binding.
> +static struct fwnode_handle *da7219_aad_of_named_fwhandle(struct device *dev,
> + const char *name)
> +{
> + struct fwnode_handle *child;
> + struct device_node *of_node;
> +
> + /* Find first matching child node */
> + device_for_each_child_node(dev, child) {
> + if (is_of_node(child)) {
> + of_node = to_of_node(child);
> + if (of_node_cmp(of_node->name, name) == 0)
> + return child;
> + }
> + }
> +
> + return NULL;
> +}
There's nothing device specific about this, it should go in generic
code.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 473 bytes --]
next prev parent reply other threads:[~2016-05-06 12:26 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-05 10:53 [PATCH 0/3] ASoC: da7219: Add ACPI initialisation support to driver Adam Thomson
2016-05-05 10:53 ` [PATCH 1/3] ASoC: da7219: Convert driver to use generic device/fwnode functions Adam Thomson
2016-05-06 12:26 ` Mark Brown [this message]
2016-05-06 14:33 ` Opensource [Adam Thomson]
2016-05-06 16:05 ` Mark Brown
2016-05-09 12:05 ` Opensource [Adam Thomson]
2016-05-09 14:56 ` Mark Brown
2016-05-05 10:53 ` [PATCH 2/3] ASoC: da7219: Add ACPI parsing support Adam Thomson
2016-05-06 12:39 ` Mark Brown
2016-05-06 14:45 ` Opensource [Adam Thomson]
2016-05-06 16:42 ` Mark Brown
2016-05-05 10:53 ` [PATCH 3/3] ASoC: da7219: Add initial ACPI id for device Adam Thomson
2016-05-05 13:49 ` Pierre-Louis Bossart
2016-06-10 10:18 ` [PATCH 0/3] ASoC: da7219: Add ACPI initialisation support to driver Opensource [Adam Thomson]
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=20160506122643.GS6292@sirena.org.uk \
--to=broonie@kernel.org \
--cc=Adam.Thomson.Opensource@diasemi.com \
--cc=alsa-devel@alsa-project.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=perex@perex.cz \
--cc=sathyanarayana.nujella@intel.com \
--cc=support.opensource@diasemi.com \
--cc=tiwai@suse.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).