All of lore.kernel.org
 help / color / mirror / Atom feed
From: Javier Martinez Canillas <javier@dowhile0.org>
To: Rob Herring <robh@kernel.org>
Cc: "Linux Kernel" <linux-kernel@vger.kernel.org>,
	"Wolfram Sang" <wsa@the-dreams.de>,
	"linux-arm-kernel@lists.infradead.org"
	<linux-arm-kernel@lists.infradead.org>,
	"Benoît Cousson" <bcousson@baylibre.com>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"Tony Lindgren" <tony@atomide.com>,
	"Mark Rutland" <mark.rutland@arm.com>,
	"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
	"Russell King" <linux@armlinux.org.uk>,
	"Mark Jackson" <mpfj@newflow.co.uk>
Subject: Re: [PATCH v3 03/21] ARM: dts: omap: Add generic compatible string for I2C EEPROM
Date: Mon, 15 May 2017 12:55:22 +0200	[thread overview]
Message-ID: <CABxcv=k7LbcQCiVYCPTTsG_-hxBseHzPy-55zDNJ+yW0BL0=3g@mail.gmail.com> (raw)
In-Reply-To: <20170419235646.j6cc3vm7eru6buv6@rob-hp-laptop>

Hello Rob,

On Thu, Apr 20, 2017 at 1:56 AM, Rob Herring <robh@kernel.org> wrote:
> On Thu, Apr 13, 2017 at 10:04:27PM -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.
>>
>> So add this generic fallback to the device node compatible string to make
>> the device to match the driver using the OF device ID table.
>>
>> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
>> ---
>>
>> Changes in v3: None
>> Changes in v2: None
>>
>>  arch/arm/boot/dts/am335x-baltos.dtsi            |  2 +-
>>  arch/arm/boot/dts/am335x-base0033.dts           |  2 +-
>>  arch/arm/boot/dts/am335x-bone-common.dtsi       | 10 +++++-----
>>  arch/arm/boot/dts/am335x-nano.dts               |  2 +-
>>  arch/arm/boot/dts/am335x-pepper.dts             |  2 +-
>>  arch/arm/boot/dts/am335x-shc.dts                |  2 +-
>>  arch/arm/boot/dts/am335x-sl50.dts               |  2 +-
>>  arch/arm/boot/dts/am437x-idk-evm.dts            |  2 +-
>>  arch/arm/boot/dts/am437x-sk-evm.dts             |  2 +-
>>  arch/arm/boot/dts/am43x-epos-evm.dts            |  2 +-
>>  arch/arm/boot/dts/am57xx-beagle-x15-common.dtsi |  2 +-
>>  arch/arm/boot/dts/omap3-cm-t3x.dtsi             |  2 +-
>>  arch/arm/boot/dts/omap3-gta04.dtsi              |  2 +-
>>  arch/arm/boot/dts/omap3-sb-t35.dtsi             |  2 +-
>>  arch/arm/boot/dts/omap4-var-som-om44.dtsi       |  2 +-
>>  arch/arm/boot/dts/omap5-cm-t54.dts              |  2 +-
>>  arch/arm/boot/dts/omap5-sbc-t54.dts             |  2 +-
>>  17 files changed, 21 insertions(+), 21 deletions(-)
>>
>> diff --git a/arch/arm/boot/dts/am335x-baltos.dtsi b/arch/arm/boot/dts/am335x-baltos.dtsi
>> index d42b98f15e8b..6ca780d0623f 100644
>> --- a/arch/arm/boot/dts/am335x-baltos.dtsi
>> +++ b/arch/arm/boot/dts/am335x-baltos.dtsi
>> @@ -255,7 +255,7 @@
>>       };
>>
>>       at24@50 {
>> -             compatible = "at24,24c02";
>> +             compatible = "at24,24c02", "atmel,24c02";
>
> I think you can just drop the at24 compatibles. A new kernel doesn't
> need it. An old kernel ignores the manufacturer. I checked that u-boot
> only matches on "atmel,*", so okay there. Don't know about the *BSDs. I
> couldn't find anything.
>

That's a very good point, it doesn't make sense indeed to keep them,
since the vendor prefix can as you said be ignored (until the OF
modalias report is fixed).

I'll re-spin the series dropping them. Thanks a lot.

Best regards,
Javier

WARNING: multiple messages have this Message-ID (diff)
From: javier@dowhile0.org (Javier Martinez Canillas)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v3 03/21] ARM: dts: omap: Add generic compatible string for I2C EEPROM
Date: Mon, 15 May 2017 12:55:22 +0200	[thread overview]
Message-ID: <CABxcv=k7LbcQCiVYCPTTsG_-hxBseHzPy-55zDNJ+yW0BL0=3g@mail.gmail.com> (raw)
In-Reply-To: <20170419235646.j6cc3vm7eru6buv6@rob-hp-laptop>

Hello Rob,

On Thu, Apr 20, 2017 at 1:56 AM, Rob Herring <robh@kernel.org> wrote:
> On Thu, Apr 13, 2017 at 10:04:27PM -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.
>>
>> So add this generic fallback to the device node compatible string to make
>> the device to match the driver using the OF device ID table.
>>
>> Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
>> ---
>>
>> Changes in v3: None
>> Changes in v2: None
>>
>>  arch/arm/boot/dts/am335x-baltos.dtsi            |  2 +-
>>  arch/arm/boot/dts/am335x-base0033.dts           |  2 +-
>>  arch/arm/boot/dts/am335x-bone-common.dtsi       | 10 +++++-----
>>  arch/arm/boot/dts/am335x-nano.dts               |  2 +-
>>  arch/arm/boot/dts/am335x-pepper.dts             |  2 +-
>>  arch/arm/boot/dts/am335x-shc.dts                |  2 +-
>>  arch/arm/boot/dts/am335x-sl50.dts               |  2 +-
>>  arch/arm/boot/dts/am437x-idk-evm.dts            |  2 +-
>>  arch/arm/boot/dts/am437x-sk-evm.dts             |  2 +-
>>  arch/arm/boot/dts/am43x-epos-evm.dts            |  2 +-
>>  arch/arm/boot/dts/am57xx-beagle-x15-common.dtsi |  2 +-
>>  arch/arm/boot/dts/omap3-cm-t3x.dtsi             |  2 +-
>>  arch/arm/boot/dts/omap3-gta04.dtsi              |  2 +-
>>  arch/arm/boot/dts/omap3-sb-t35.dtsi             |  2 +-
>>  arch/arm/boot/dts/omap4-var-som-om44.dtsi       |  2 +-
>>  arch/arm/boot/dts/omap5-cm-t54.dts              |  2 +-
>>  arch/arm/boot/dts/omap5-sbc-t54.dts             |  2 +-
>>  17 files changed, 21 insertions(+), 21 deletions(-)
>>
>> diff --git a/arch/arm/boot/dts/am335x-baltos.dtsi b/arch/arm/boot/dts/am335x-baltos.dtsi
>> index d42b98f15e8b..6ca780d0623f 100644
>> --- a/arch/arm/boot/dts/am335x-baltos.dtsi
>> +++ b/arch/arm/boot/dts/am335x-baltos.dtsi
>> @@ -255,7 +255,7 @@
>>       };
>>
>>       at24 at 50 {
>> -             compatible = "at24,24c02";
>> +             compatible = "at24,24c02", "atmel,24c02";
>
> I think you can just drop the at24 compatibles. A new kernel doesn't
> need it. An old kernel ignores the manufacturer. I checked that u-boot
> only matches on "atmel,*", so okay there. Don't know about the *BSDs. I
> couldn't find anything.
>

That's a very good point, it doesn't make sense indeed to keep them,
since the vendor prefix can as you said be ignored (until the OF
modalias report is fixed).

I'll re-spin the series dropping them. Thanks a lot.

Best regards,
Javier

  reply	other threads:[~2017-05-15 10:55 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
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 [this message]
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='CABxcv=k7LbcQCiVYCPTTsG_-hxBseHzPy-55zDNJ+yW0BL0=3g@mail.gmail.com' \
    --to=javier@dowhile0.org \
    --cc=bcousson@baylibre.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=mark.rutland@arm.com \
    --cc=mpfj@newflow.co.uk \
    --cc=robh@kernel.org \
    --cc=tony@atomide.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.