From: Marc Kleine-Budde <mkl@pengutronix.de>
To: Hui Wang <jason77.wang@gmail.com>
Cc: Wolfgang Grandegger <wg@grandegger.com>,
davem@davemloft.net, shawn.guo@linaro.org,
linux-can@vger.kernel.org,
Devicetree Discussions <devicetree-discuss@lists.ozlabs.org>
Subject: Re: [PATCH 2/4] can: flexcan: add hardware controller version support
Date: Wed, 27 Jun 2012 12:24:40 +0200 [thread overview]
Message-ID: <4FEADF68.7070702@pengutronix.de> (raw)
In-Reply-To: <4FEADCB8.80306@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1884 bytes --]
On 06/27/2012 12:13 PM, Hui Wang wrote:
[...]
>>> What compatible string do they actually use for the i.MX6Q board? Shawn
>>> or Hui? We need to fix that. From the discussion mentioned above I think
>>>
> Currently i modified the can1 DT entry in the imx6q.dtsi like this:
> flexcan@02090000 { /* CAN1 */
> reg = <0x02090000 0x4000>;
> interrupts = <0 110 0x04>;
> hw-version = <10>;
^^^^^^^^^^^^^^^^^^
remove
> };
>
> and the DT entry in the imx6q-sabrelite.dts like this:
> flexcan@02090000 { /* CAN1 */
> compatible = "fsl,imx6q-flexcan", "fsl,p1010-flexcan";
^^^^^^^^^^^^^^^^^^^
If imx6q is the first sock with this core "fsl,imx6q-flexcan" is the
official name. "fsl,p1010-flexcan" will be removed. The compatible
should go into the imx6q.dtsi
> phy-en-gpio = <&gpio1 4 0>;
> phy-stby-gpio = <&gpio1 2 0>;
> pinctrl-names = "default";
> pinctrl-0 = <&pinctrl_flexcan1_1>;
> };
> if we don't use hw-version entry and use flexcan-v10, do you mean we use
> strcmp or strxxx to decide controller version?
No, have a look at the flexcan_of_match. The struct of_device_id has a
data pointer that can point to some arbitrary data. Define a struct
flexcan_devtype_data which has, for now, a hardware revision member.
Have a look at the imx-spi[1] driver.
Marc
[1] http://lxr.free-electrons.com/source/drivers/spi/spi-imx.c
--
Pengutronix e.K. | Marc Kleine-Budde |
Industrial Linux Solutions | Phone: +49-231-2826-924 |
Vertretung West/Dortmund | Fax: +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de |
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 262 bytes --]
next prev parent reply other threads:[~2012-06-27 10:24 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1340785161-3598-1-git-send-email-jason77.wang@gmail.com>
[not found] ` <1340785161-3598-2-git-send-email-jason77.wang@gmail.com>
[not found] ` <1340785161-3598-3-git-send-email-jason77.wang@gmail.com>
[not found] ` <4FEAC3EF.3060606@pengutronix.de>
2012-06-27 8:56 ` [PATCH 2/4] can: flexcan: add hardware controller version support Wolfgang Grandegger
2012-06-27 9:43 ` Wolfgang Grandegger
2012-06-27 9:51 ` Marc Kleine-Budde
2012-06-27 10:13 ` Hui Wang
2012-06-27 10:24 ` Marc Kleine-Budde [this message]
2012-06-27 10:57 ` Wolfgang Grandegger
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=4FEADF68.7070702@pengutronix.de \
--to=mkl@pengutronix.de \
--cc=davem@davemloft.net \
--cc=devicetree-discuss@lists.ozlabs.org \
--cc=jason77.wang@gmail.com \
--cc=linux-can@vger.kernel.org \
--cc=shawn.guo@linaro.org \
--cc=wg@grandegger.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).