From: thierry.reding@avionic-design.de (Thierry Reding)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/3] i2c: tegra: Support DVC controller in device tree
Date: Sun, 18 Dec 2011 16:42:08 +0100 [thread overview]
Message-ID: <20111218154208.GA5600@avionic-0098.mockup.avionic-design.de> (raw)
In-Reply-To: <1324186101-23695-1-git-send-email-swarren@nvidia.com>
* Stephen Warren wrote:
[...]
> @@ -636,7 +649,18 @@ static int tegra_i2c_probe(struct platform_device *pdev)
> i2c_dev->bus_clk_rate = be32_to_cpup(prop);
> }
>
> - if (pdev->id == 3)
> +#if defined(CONFIG_OF)
> + if (pdev->dev.of_node) {
> + const struct of_device_id *match;
> +
> + match = of_match_device(tegra_i2c_of_match, &pdev->dev);
> + if (!match)
> + return -EINVAL;
> +
> + i2c_dev->is_dvc = match->data;
> + }
> +#endif
> + else if (pdev->id == 3)
Shouldn't the "else" move into the CONFIG_OF branch?
Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20111218/200453ba/attachment.sig>
next prev parent reply other threads:[~2011-12-18 15:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-18 5:28 [PATCH 1/3] i2c: tegra: Support DVC controller in device tree Stephen Warren
2011-12-18 5:28 ` [PATCH 2/3] arm/dt: tegra: Use new compatible value for DVC I2C controller Stephen Warren
2011-12-18 5:28 ` [PATCH 3/3] arm/dt: Add ADT7461 to Seaboard Stephen Warren
2011-12-18 5:41 ` [PATCH 1/3] i2c: tegra: Support DVC controller in device tree Olof Johansson
2011-12-18 15:42 ` Thierry Reding [this message]
2011-12-18 15:46 ` Thierry Reding
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=20111218154208.GA5600@avionic-0098.mockup.avionic-design.de \
--to=thierry.reding@avionic-design.de \
--cc=linux-arm-kernel@lists.infradead.org \
/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).