All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sascha Hauer <s.hauer@pengutronix.de>
To: Shawn Guo <shawn.guo@freescale.com>
Cc: "Lothar Waßmann" <LW@KARO-electronics.de>,
	"Ian Campbell" <ijc+devicetree@hellion.org.uk>,
	"Kumar Gala" <galak@codeaurora.org>,
	"Mark Rutland" <mark.rutland@arm.com>,
	"Pawel Moll" <pawel.moll@arm.com>,
	"Rob Herring" <robh+dt@kernel.org>,
	"Russell King" <linux@arm.linux.org.uk>,
	"Sascha Hauer" <kernel@pengutronix.de>,
	devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ARM: dts: add support for Ka-Ro TX51
Date: Wed, 25 Jun 2014 09:08:49 +0200	[thread overview]
Message-ID: <20140625070849.GO15686@pengutronix.de> (raw)
In-Reply-To: <20140625064841.GA2224@dragon>

On Wed, Jun 25, 2014 at 02:48:43PM +0800, Shawn Guo wrote:
> On Mon, Jun 23, 2014 at 12:18:39PM +0200, Lothar Waßmann wrote:
> ...
> > > > +	phy-handle = <&phy0>;
> > > > +	mac-address = [000000000000]; /* will be set by U-Boot */
> > > 
> > > Shouldn't it be local-mac-address?
> > > 
> > probably yes, but both 'mac-address' and 'local-mac-address' are being
> > set up by U-Boot anyway.
> 
> Okay, never mind.  I just realized kernel supports both properties.
> 
> ...
> 
> > > > +&esdhc1 {
> > > > +	cd-gpios = <&gpio3 8 GPIO_ACTIVE_LOW>;
> > > > +	fsl,wp-controller;
> > > 
> > > Does it work for you, since the driver does not support it as of today?
> > > 
> > What driver doesn't support what?
> > AFAICT the sdhci-esdhc-imx.c driver supports both of these properties.
> 
> That was the case before, but it's not the case since commit
> 89d7e5c13122 (mmc: sdhci-esdhc-imx: add runtime pm support).
> 
> http://thread.gmane.org/gmane.linux.kernel.mmc/27287
> 
> ...
> 
> > > > +	spidev0: spi@0 {
> > > > +		compatible = "spidev";
> > > > +		reg = <0>;
> > > > +		spi-max-frequency = <54000000>;
> > > > +	};
> > > > +
> > > > +	spidev1: spi@1 {
> > > > +		compatible = "spidev";
> > > > +		reg = <1>;
> > > > +		spi-max-frequency = <54000000>;
> > > > +	};
> > > 
> > > I'm not sure we should have these two devices.
> > > 
> > Why not? With this the SPI bus can readily be used with the spidev
> > driver from Documentation/spi/spidev_test.c (which is what most of our
> > customers are asking for)!
> 
> Is this something that has been approved by DT maintainers?  I do not
> see "spidev" documented as a compatible in any bindings doc.

I don't think it has been approved, but it's used already in several
places:

arch/arm/boot/dts/spear1340-evb.dts:496:                                        compatible = "spidev";
arch/arm/boot/dts/spear1310-evb.dts:402:                                        compatible = "spidev";
arch/arm/boot/dts/imx28-tx28.dts:623:           compatible = "spidev";
arch/arm/boot/dts/imx28-tx28.dts:629:           compatible = "spidev";
arch/arm/boot/dts/atlas6-evb.dts:32:                                    compatible = "spidev";
arch/arm/boot/dts/marco-evb.dts:41:                                     compatible = "spidev";
arch/arm/boot/dts/tegra30-colibri-eval-v3.dts:78:                       compatible = "spidev";
arch/arm/boot/dts/imx53-tx53.dtsi:173:          compatible = "spidev";
arch/arm/boot/dts/imx53-tx53.dtsi:179:          compatible = "spidev";
arch/powerpc/boot/dts/mgcoge.dts:235:                                   compatible = "gen,spidev";
arch/powerpc/boot/dts/o2d.dtsi:43:                              compatible = "spidev";
arch/powerpc/boot/dts/digsy_mtc.dts:34:                         compatible = "spidev";

Usually this binding gets denied with "spidev is Linux specific. Use a
specific compatible instead". This had the result that the spidev driver
now matches to "rohm,dh2228fv" and I have already seen people claiming
that their spi device is a "rohm,dh2228fv" just to let the spidev driver
match.

Maybe the reasoning for a spidev binding could be:

There is a SPI device, but we don't know what it is, so we just call it
"spidev". Linux just tries to make the best from the situation and makes
a userspace device from it.


Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

WARNING: multiple messages have this Message-ID (diff)
From: Sascha Hauer <s.hauer-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
To: Shawn Guo <shawn.guo-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
Cc: "Lothar Waßmann"
	<LW-bxm8fMRDkQLDiMYJYoSAnRvVK+yQ3ZXh@public.gmane.org>,
	"Ian Campbell"
	<ijc+devicetree-KcIKpvwj1kUDXYZnReoRVg@public.gmane.org>,
	"Kumar Gala" <galak-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>,
	"Mark Rutland" <mark.rutland-5wv7dgnIgG8@public.gmane.org>,
	"Pawel Moll" <pawel.moll-5wv7dgnIgG8@public.gmane.org>,
	"Rob Herring" <robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
	"Russell King" <linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org>,
	"Sascha Hauer" <kernel-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] ARM: dts: add support for Ka-Ro TX51
Date: Wed, 25 Jun 2014 09:08:49 +0200	[thread overview]
Message-ID: <20140625070849.GO15686@pengutronix.de> (raw)
In-Reply-To: <20140625064841.GA2224@dragon>

On Wed, Jun 25, 2014 at 02:48:43PM +0800, Shawn Guo wrote:
> On Mon, Jun 23, 2014 at 12:18:39PM +0200, Lothar Waßmann wrote:
> ...
> > > > +	phy-handle = <&phy0>;
> > > > +	mac-address = [000000000000]; /* will be set by U-Boot */
> > > 
> > > Shouldn't it be local-mac-address?
> > > 
> > probably yes, but both 'mac-address' and 'local-mac-address' are being
> > set up by U-Boot anyway.
> 
> Okay, never mind.  I just realized kernel supports both properties.
> 
> ...
> 
> > > > +&esdhc1 {
> > > > +	cd-gpios = <&gpio3 8 GPIO_ACTIVE_LOW>;
> > > > +	fsl,wp-controller;
> > > 
> > > Does it work for you, since the driver does not support it as of today?
> > > 
> > What driver doesn't support what?
> > AFAICT the sdhci-esdhc-imx.c driver supports both of these properties.
> 
> That was the case before, but it's not the case since commit
> 89d7e5c13122 (mmc: sdhci-esdhc-imx: add runtime pm support).
> 
> http://thread.gmane.org/gmane.linux.kernel.mmc/27287
> 
> ...
> 
> > > > +	spidev0: spi@0 {
> > > > +		compatible = "spidev";
> > > > +		reg = <0>;
> > > > +		spi-max-frequency = <54000000>;
> > > > +	};
> > > > +
> > > > +	spidev1: spi@1 {
> > > > +		compatible = "spidev";
> > > > +		reg = <1>;
> > > > +		spi-max-frequency = <54000000>;
> > > > +	};
> > > 
> > > I'm not sure we should have these two devices.
> > > 
> > Why not? With this the SPI bus can readily be used with the spidev
> > driver from Documentation/spi/spidev_test.c (which is what most of our
> > customers are asking for)!
> 
> Is this something that has been approved by DT maintainers?  I do not
> see "spidev" documented as a compatible in any bindings doc.

I don't think it has been approved, but it's used already in several
places:

arch/arm/boot/dts/spear1340-evb.dts:496:                                        compatible = "spidev";
arch/arm/boot/dts/spear1310-evb.dts:402:                                        compatible = "spidev";
arch/arm/boot/dts/imx28-tx28.dts:623:           compatible = "spidev";
arch/arm/boot/dts/imx28-tx28.dts:629:           compatible = "spidev";
arch/arm/boot/dts/atlas6-evb.dts:32:                                    compatible = "spidev";
arch/arm/boot/dts/marco-evb.dts:41:                                     compatible = "spidev";
arch/arm/boot/dts/tegra30-colibri-eval-v3.dts:78:                       compatible = "spidev";
arch/arm/boot/dts/imx53-tx53.dtsi:173:          compatible = "spidev";
arch/arm/boot/dts/imx53-tx53.dtsi:179:          compatible = "spidev";
arch/powerpc/boot/dts/mgcoge.dts:235:                                   compatible = "gen,spidev";
arch/powerpc/boot/dts/o2d.dtsi:43:                              compatible = "spidev";
arch/powerpc/boot/dts/digsy_mtc.dts:34:                         compatible = "spidev";

Usually this binding gets denied with "spidev is Linux specific. Use a
specific compatible instead". This had the result that the spidev driver
now matches to "rohm,dh2228fv" and I have already seen people claiming
that their spi device is a "rohm,dh2228fv" just to let the spidev driver
match.

Maybe the reasoning for a spidev binding could be:

There is a SPI device, but we don't know what it is, so we just call it
"spidev". Linux just tries to make the best from the situation and makes
a userspace device from it.


Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

WARNING: multiple messages have this Message-ID (diff)
From: s.hauer@pengutronix.de (Sascha Hauer)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: dts: add support for Ka-Ro TX51
Date: Wed, 25 Jun 2014 09:08:49 +0200	[thread overview]
Message-ID: <20140625070849.GO15686@pengutronix.de> (raw)
In-Reply-To: <20140625064841.GA2224@dragon>

On Wed, Jun 25, 2014 at 02:48:43PM +0800, Shawn Guo wrote:
> On Mon, Jun 23, 2014 at 12:18:39PM +0200, Lothar Wa?mann wrote:
> ...
> > > > +	phy-handle = <&phy0>;
> > > > +	mac-address = [000000000000]; /* will be set by U-Boot */
> > > 
> > > Shouldn't it be local-mac-address?
> > > 
> > probably yes, but both 'mac-address' and 'local-mac-address' are being
> > set up by U-Boot anyway.
> 
> Okay, never mind.  I just realized kernel supports both properties.
> 
> ...
> 
> > > > +&esdhc1 {
> > > > +	cd-gpios = <&gpio3 8 GPIO_ACTIVE_LOW>;
> > > > +	fsl,wp-controller;
> > > 
> > > Does it work for you, since the driver does not support it as of today?
> > > 
> > What driver doesn't support what?
> > AFAICT the sdhci-esdhc-imx.c driver supports both of these properties.
> 
> That was the case before, but it's not the case since commit
> 89d7e5c13122 (mmc: sdhci-esdhc-imx: add runtime pm support).
> 
> http://thread.gmane.org/gmane.linux.kernel.mmc/27287
> 
> ...
> 
> > > > +	spidev0: spi at 0 {
> > > > +		compatible = "spidev";
> > > > +		reg = <0>;
> > > > +		spi-max-frequency = <54000000>;
> > > > +	};
> > > > +
> > > > +	spidev1: spi at 1 {
> > > > +		compatible = "spidev";
> > > > +		reg = <1>;
> > > > +		spi-max-frequency = <54000000>;
> > > > +	};
> > > 
> > > I'm not sure we should have these two devices.
> > > 
> > Why not? With this the SPI bus can readily be used with the spidev
> > driver from Documentation/spi/spidev_test.c (which is what most of our
> > customers are asking for)!
> 
> Is this something that has been approved by DT maintainers?  I do not
> see "spidev" documented as a compatible in any bindings doc.

I don't think it has been approved, but it's used already in several
places:

arch/arm/boot/dts/spear1340-evb.dts:496:                                        compatible = "spidev";
arch/arm/boot/dts/spear1310-evb.dts:402:                                        compatible = "spidev";
arch/arm/boot/dts/imx28-tx28.dts:623:           compatible = "spidev";
arch/arm/boot/dts/imx28-tx28.dts:629:           compatible = "spidev";
arch/arm/boot/dts/atlas6-evb.dts:32:                                    compatible = "spidev";
arch/arm/boot/dts/marco-evb.dts:41:                                     compatible = "spidev";
arch/arm/boot/dts/tegra30-colibri-eval-v3.dts:78:                       compatible = "spidev";
arch/arm/boot/dts/imx53-tx53.dtsi:173:          compatible = "spidev";
arch/arm/boot/dts/imx53-tx53.dtsi:179:          compatible = "spidev";
arch/powerpc/boot/dts/mgcoge.dts:235:                                   compatible = "gen,spidev";
arch/powerpc/boot/dts/o2d.dtsi:43:                              compatible = "spidev";
arch/powerpc/boot/dts/digsy_mtc.dts:34:                         compatible = "spidev";

Usually this binding gets denied with "spidev is Linux specific. Use a
specific compatible instead". This had the result that the spidev driver
now matches to "rohm,dh2228fv" and I have already seen people claiming
that their spi device is a "rohm,dh2228fv" just to let the spidev driver
match.

Maybe the reasoning for a spidev binding could be:

There is a SPI device, but we don't know what it is, so we just call it
"spidev". Linux just tries to make the best from the situation and makes
a userspace device from it.


Sascha

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

  reply	other threads:[~2014-06-25  7:09 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-12 13:09 [PATCH] ARM: dts: add support for Ka-Ro TX51 Lothar Waßmann
2014-06-12 13:09 ` Lothar Waßmann
2014-06-12 13:09 ` Lothar Waßmann
2014-06-18 15:01 ` Shawn Guo
2014-06-18 15:01   ` Shawn Guo
2014-06-18 15:01   ` Shawn Guo
2014-06-23 10:18   ` Lothar Waßmann
2014-06-23 10:18     ` Lothar Waßmann
2014-06-23 10:18     ` Lothar Waßmann
2014-06-25  6:48     ` Shawn Guo
2014-06-25  6:48       ` Shawn Guo
2014-06-25  6:48       ` Shawn Guo
2014-06-25  7:08       ` Sascha Hauer [this message]
2014-06-25  7:08         ` Sascha Hauer
2014-06-25  7:08         ` Sascha Hauer

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=20140625070849.GO15686@pengutronix.de \
    --to=s.hauer@pengutronix.de \
    --cc=LW@KARO-electronics.de \
    --cc=devicetree@vger.kernel.org \
    --cc=galak@codeaurora.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=shawn.guo@freescale.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.