All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: Javier Martinez Canillas <javier@osg.samsung.com>
Cc: linux-kernel@vger.kernel.org, Wolfram Sang <wsa@the-dreams.de>,
	Simon Horman <horms@verge.net.au>,
	devicetree@vger.kernel.org, Sekhar Nori <nsekhar@ti.com>,
	David Lechner <david@lechnology.com>,
	Alexandre Belloni <alexandre.belloni@free-electrons.com>,
	Mark Rutland <mark.rutland@arm.com>
Subject: Re: [PATCH v3 01/21] dt-bindings: i2c: eeprom: Document manufacturer used as generic fallback
Date: Wed, 19 Apr 2017 18:27:59 -0500	[thread overview]
Message-ID: <20170419232759.mw6g6fwy4xvjaopv@rob-hp-laptop> (raw)
In-Reply-To: <20170414010445.21727-2-javier@osg.samsung.com>

On Thu, Apr 13, 2017 at 10:04:25PM -0300, Javier Martinez Canillas wrote:
> The at24 driver allows to register I2C EEPROM chips using different vendor
> and devices, but the I2C subsystem does not take the vendor into account
> when matching using the I2C table since it only has device entries.
> 
> But when matching using an OF table, both the vendor and device has to be
> taken into account so the driver defines only a set of compatible strings
> using the "atmel" vendor as a generic fallback for compatible I2C devices.
> 
> Document in the Device Tree binding document that this manufacturer should
> be used as the generic fallback.
> 
> Suggested-by: Wolfram Sang <wsa@the-dreams.de>
> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
> 
> ---
> 
> Changes in v3: None
> Changes in v2: None
> 
>  Documentation/devicetree/bindings/eeprom/eeprom.txt | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/eeprom/eeprom.txt b/Documentation/devicetree/bindings/eeprom/eeprom.txt
> index 5696eb508e95..d0395f14e2b3 100644
> --- a/Documentation/devicetree/bindings/eeprom/eeprom.txt
> +++ b/Documentation/devicetree/bindings/eeprom/eeprom.txt
> @@ -17,7 +17,8 @@ Required properties:
>  	"renesas,r1ex24002"
>  
>  	 If there is no specific driver for <manufacturer>, a generic
> -	 driver based on <type> is selected. Possible types are:
> +	 driver based on <type> and manufacturer "atmel" is selected.
> +	 Possible types are:

This isn't quite right. What the driver does isn't really relevant to 
the binding.

These types with no vendor are used as the compatible string, so we have 
to allow them. But it should be clear that no vendor is deprecated. 
Ironically, it is a lot of Atmel boards that do this. 

We should also explicitly list what are valid manufacturers. We also 
have "at" as a vendor prefix which perhaps we should explicitly say is 
deprecated.

Rob

WARNING: multiple messages have this Message-ID (diff)
From: Rob Herring <robh-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Javier Martinez Canillas
	<javier-JPH+aEBZ4P+UEJcrhfAQsw@public.gmane.org>
Cc: linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Wolfram Sang <wsa-z923LK4zBo2bacvFa/9K2g@public.gmane.org>,
	Simon Horman <horms-/R6kz+dDXgpPR4JQBCEnsQ@public.gmane.org>,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>,
	David Lechner <david-nq/r/kbU++upp/zk7JDF2g@public.gmane.org>,
	Alexandre Belloni
	<alexandre.belloni-wi1+55ScJUtKEb57/3fJTNBPR1lH4CV8@public.gmane.org>,
	Mark Rutland <mark.rutland-5wv7dgnIgG8@public.gmane.org>
Subject: Re: [PATCH v3 01/21] dt-bindings: i2c: eeprom: Document manufacturer used as generic fallback
Date: Wed, 19 Apr 2017 18:27:59 -0500	[thread overview]
Message-ID: <20170419232759.mw6g6fwy4xvjaopv@rob-hp-laptop> (raw)
In-Reply-To: <20170414010445.21727-2-javier-JPH+aEBZ4P+UEJcrhfAQsw@public.gmane.org>

On Thu, Apr 13, 2017 at 10:04:25PM -0300, Javier Martinez Canillas wrote:
> The at24 driver allows to register I2C EEPROM chips using different vendor
> and devices, but the I2C subsystem does not take the vendor into account
> when matching using the I2C table since it only has device entries.
> 
> But when matching using an OF table, both the vendor and device has to be
> taken into account so the driver defines only a set of compatible strings
> using the "atmel" vendor as a generic fallback for compatible I2C devices.
> 
> Document in the Device Tree binding document that this manufacturer should
> be used as the generic fallback.
> 
> Suggested-by: Wolfram Sang <wsa-z923LK4zBo2bacvFa/9K2g@public.gmane.org>
> Signed-off-by: Javier Martinez Canillas <javier-JPH+aEBZ4P+UEJcrhfAQsw@public.gmane.org>
> 
> ---
> 
> Changes in v3: None
> Changes in v2: None
> 
>  Documentation/devicetree/bindings/eeprom/eeprom.txt | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/eeprom/eeprom.txt b/Documentation/devicetree/bindings/eeprom/eeprom.txt
> index 5696eb508e95..d0395f14e2b3 100644
> --- a/Documentation/devicetree/bindings/eeprom/eeprom.txt
> +++ b/Documentation/devicetree/bindings/eeprom/eeprom.txt
> @@ -17,7 +17,8 @@ Required properties:
>  	"renesas,r1ex24002"
>  
>  	 If there is no specific driver for <manufacturer>, a generic
> -	 driver based on <type> is selected. Possible types are:
> +	 driver based on <type> and manufacturer "atmel" is selected.
> +	 Possible types are:

This isn't quite right. What the driver does isn't really relevant to 
the binding.

These types with no vendor are used as the compatible string, so we have 
to allow them. But it should be clear that no vendor is deprecated. 
Ironically, it is a lot of Atmel boards that do this. 

We should also explicitly list what are valid manufacturers. We also 
have "at" as a vendor prefix which perhaps we should explicitly say is 
deprecated.

Rob
--
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

  reply	other threads:[~2017-04-19 23:28 UTC|newest]

Thread overview: 68+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-14  1:04 [PATCH v3 00/21] eeprom: at24: Add OF device ID table Javier Martinez Canillas
2017-04-14  1:04 ` Javier Martinez Canillas
2017-04-14  1:04 ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 01/21] dt-bindings: i2c: eeprom: Document manufacturer used as generic fallback Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-19 23:27   ` Rob Herring [this message]
2017-04-19 23:27     ` Rob Herring
2017-04-19 23:35     ` Rob Herring
2017-04-19 23:35       ` Rob Herring
2017-05-15 10:48       ` Javier Martinez Canillas
2017-05-15 10:48         ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 02/21] eeprom: at24: Add OF device ID table Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 03/21] ARM: dts: omap: Add generic compatible string for I2C EEPROM Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14 14:17   ` Tony Lindgren
2017-04-14 14:17     ` Tony Lindgren
2017-04-14 14:17     ` Tony Lindgren
2017-04-19 23:56   ` Rob Herring
2017-04-19 23:56     ` Rob Herring
2017-04-19 23:56     ` Rob Herring
2017-05-15 10:55     ` Javier Martinez Canillas
2017-05-15 10:55       ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 04/21] ARM: dts: turris-omnia: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 05/21] ARM: dts: at91: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-05-15  9:32   ` Alexandre Belloni
2017-05-15  9:32     ` Alexandre Belloni
2017-05-15  9:32     ` Alexandre Belloni
2017-04-14  1:04 ` [PATCH v3 06/21] ARM: dts: efm32: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 07/21] ARM: dts: imx: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 08/21] ARM: dts: keystone: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 09/21] ARM: dts: lpc18xx: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 10/21] ARM: dts: r7s72100: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 11/21] ARM: dts: koelsch: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 12/21] ARM: dts: socfpga: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 13/21] ARM: dts: uniphier: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 14/21] ARM: dts: zynq: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 15/21] arm64: dts: ls1043a: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 16/21] arm64: zynqmp: " Javier Martinez Canillas
2017-04-14  1:04   ` Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 17/21] powerpc/5200: " Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 18/21] powerpc/fsl: " Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 19/21] powerpc/512x: " Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 20/21] powerpc/83xx: " Javier Martinez Canillas
2017-04-14  1:04 ` [PATCH v3 21/21] powerpc/44x: " Javier Martinez Canillas
2017-04-20  0:12 ` [PATCH v3 00/21] eeprom: at24: Add OF device ID table Rob Herring
2017-04-20  0:12   ` Rob Herring
2017-04-20  0:12   ` Rob Herring

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=20170419232759.mw6g6fwy4xvjaopv@rob-hp-laptop \
    --to=robh@kernel.org \
    --cc=alexandre.belloni@free-electrons.com \
    --cc=david@lechnology.com \
    --cc=devicetree@vger.kernel.org \
    --cc=horms@verge.net.au \
    --cc=javier@osg.samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=nsekhar@ti.com \
    --cc=wsa@the-dreams.de \
    /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.