All of lore.kernel.org
 help / color / mirror / Atom feed
From: Li Yang <leoyang.li@nxp.com>
To: Rob Herring <robh@kernel.org>
Cc: Shawn Guo <shawnguo@kernel.org>,
	"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
	<devicetree@vger.kernel.org>,
	Oleksij Rempel <linux@rempel-privat.de>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2 02/16] dt-bindings: i2c: imx: update schema to align with original txt binding
Date: Fri, 8 Oct 2021 22:08:34 -0500	[thread overview]
Message-ID: <CADRPPNSxLaG1WcxKY-KtBwJON51Rg5-euJNJnJObarjEKN2eSA@mail.gmail.com> (raw)
In-Reply-To: <YWDEESYAuQSIfOSQ@robh.at.kernel.org>

On Fri, Oct 8, 2021 at 5:20 PM Rob Herring <robh@kernel.org> wrote:
>
> On Fri, Oct 01, 2021 at 12:37:54PM -0500, Li Yang wrote:
> > On Fri, Oct 1, 2021 at 8:24 AM Rob Herring <robh+dt@kernel.org> wrote:
> > >
> > > On Thu, Sep 30, 2021 at 7:04 PM Li Yang <leoyang.li@nxp.com> wrote:
> > > >
> > > > When the binding was converted from txt to yaml, it actually added more
> > > > constrains than the original txt binding which was already used in many
> > > > in-tree DTSes.  Some of the newly added constrains are either not valid
> > > > or not neccessary.
> > >
> > > IMO, both of these should be fixed in the dts files.
> > >
> > > > Not all SoCs use ipg as the clock name for i2c.  There is no point in
> > > > having SoC integration information defined in i2c binding.  Remove the
> > > > clock name requirement in the schema.
> > >
> > > Any name you want is not fine. Your choices are remove clock-names,
> > > add all the names used, or change everyone to use 'ipg'.
> >
> > I understand that the name should be important as clocks are
> > referenced by name.  But since the i2c controller only has one clock ,
> > the name is never referenced in the driver.
>
> Then just remove 'clock-names' from the dts file.

Had thought the clock-names are mandatory, but it turns out not.
Removing it should be great.

>
> > If we really want to define the name, IMO, it should be from the
> > perspective of the i2c controller like "clkin" or "i2c" instead of the
> > "ipg" from the perspective of SoC integration which could be changing
> > with a different integration.  I can list both "i2c" and "ipg" for now
> > as a workaround though.
>
> $modulename for $foo-names always looks made up and pointless to me.
>
> >
> > >
> > > > The original txt binding didn't require the order of tx and rx for
> > > > dmas/dma-names.  Many in tree DTSes are already using the other order.
> > > > Both orders should just work fine.  Update the schema to allow both.
> > >
> > > Doesn't sound like a case where defining the order is challenging.
> >
> > No, it is not challenging.  But as dma channel is only referenced by
> > name instead of index.  I don't see too much benefit in enforcing the
> > order other than easier to create the schema.
>
> Easier is nice, and that's the 'DT way' is the other reason.

Ok.

Regards,
Leo

WARNING: multiple messages have this Message-ID (diff)
From: Li Yang <leoyang.li@nxp.com>
To: Rob Herring <robh@kernel.org>
Cc: Shawn Guo <shawnguo@kernel.org>,
	 "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS"
	<devicetree@vger.kernel.org>,
	Oleksij Rempel <linux@rempel-privat.de>,
	 linux-arm-kernel <linux-arm-kernel@lists.infradead.org>,
	 "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2 02/16] dt-bindings: i2c: imx: update schema to align with original txt binding
Date: Fri, 8 Oct 2021 22:08:34 -0500	[thread overview]
Message-ID: <CADRPPNSxLaG1WcxKY-KtBwJON51Rg5-euJNJnJObarjEKN2eSA@mail.gmail.com> (raw)
In-Reply-To: <YWDEESYAuQSIfOSQ@robh.at.kernel.org>

On Fri, Oct 8, 2021 at 5:20 PM Rob Herring <robh@kernel.org> wrote:
>
> On Fri, Oct 01, 2021 at 12:37:54PM -0500, Li Yang wrote:
> > On Fri, Oct 1, 2021 at 8:24 AM Rob Herring <robh+dt@kernel.org> wrote:
> > >
> > > On Thu, Sep 30, 2021 at 7:04 PM Li Yang <leoyang.li@nxp.com> wrote:
> > > >
> > > > When the binding was converted from txt to yaml, it actually added more
> > > > constrains than the original txt binding which was already used in many
> > > > in-tree DTSes.  Some of the newly added constrains are either not valid
> > > > or not neccessary.
> > >
> > > IMO, both of these should be fixed in the dts files.
> > >
> > > > Not all SoCs use ipg as the clock name for i2c.  There is no point in
> > > > having SoC integration information defined in i2c binding.  Remove the
> > > > clock name requirement in the schema.
> > >
> > > Any name you want is not fine. Your choices are remove clock-names,
> > > add all the names used, or change everyone to use 'ipg'.
> >
> > I understand that the name should be important as clocks are
> > referenced by name.  But since the i2c controller only has one clock ,
> > the name is never referenced in the driver.
>
> Then just remove 'clock-names' from the dts file.

Had thought the clock-names are mandatory, but it turns out not.
Removing it should be great.

>
> > If we really want to define the name, IMO, it should be from the
> > perspective of the i2c controller like "clkin" or "i2c" instead of the
> > "ipg" from the perspective of SoC integration which could be changing
> > with a different integration.  I can list both "i2c" and "ipg" for now
> > as a workaround though.
>
> $modulename for $foo-names always looks made up and pointless to me.
>
> >
> > >
> > > > The original txt binding didn't require the order of tx and rx for
> > > > dmas/dma-names.  Many in tree DTSes are already using the other order.
> > > > Both orders should just work fine.  Update the schema to allow both.
> > >
> > > Doesn't sound like a case where defining the order is challenging.
> >
> > No, it is not challenging.  But as dma channel is only referenced by
> > name instead of index.  I don't see too much benefit in enforcing the
> > order other than easier to create the schema.
>
> Easier is nice, and that's the 'DT way' is the other reason.

Ok.

Regards,
Leo

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2021-10-09  3:08 UTC|newest]

Thread overview: 52+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-01  0:04 [PATCH v2 00/16] Cleanup of LS1021a device trees Li Yang
2021-10-01  0:04 ` Li Yang
2021-10-01  0:04 ` [PATCH v2 01/16] dt-bindings: arm: fsl: add ls1021a-tsn board Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 02/16] dt-bindings: i2c: imx: update schema to align with original txt binding Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01 13:16   ` Rob Herring
2021-10-01 13:16     ` Rob Herring
2021-10-01 13:23   ` Rob Herring
2021-10-01 13:23     ` Rob Herring
2021-10-01 17:37     ` Li Yang
2021-10-01 17:37       ` Li Yang
2021-10-08 22:20       ` Rob Herring
2021-10-08 22:20         ` Rob Herring
2021-10-09  3:08         ` Li Yang [this message]
2021-10-09  3:08           ` Li Yang
2021-10-01  0:04 ` [PATCH v2 03/16] ARM: dts: ls1021a: change to use SPDX identifiers Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 04/16] ARM: dts: ls1021a-qds: Add node for QSPI flash Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  5:24   ` [EXT] " Kuldeep Singh
2021-10-01  5:24     ` Kuldeep Singh
2021-10-01 20:08     ` Li Yang
2021-10-01 20:08       ` Li Yang
2021-10-04  5:53       ` Kuldeep Singh
2021-10-04  5:53         ` Kuldeep Singh
2021-10-01  0:04 ` [PATCH v2 05/16] ARM: dts: ls1021a: update pcie nodes for dt-schema check Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 06/16] ARM: dts: ls1021a: fix board compatible to follow binding schema Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 07/16] ARM: dts: ls1021a: breakup long values in thermal node Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 08/16] ARM: dts: ls1021a: disable ifc node by default Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 09/16] ARM: dts: ls1021a: remove regulators simple-bus Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 10/16] ARM: dts: ls1021a: fix memory node for schema check Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 11/16] ARM: dts: ls1021a: add #dma-cells to qdma node Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 12/16] ARM: dts: ls1021a: add #power-domain-cells for power-controller node Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 13/16] ARM: dts: ls1021a-qds: change fpga to simple-mfd device Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 14/16] ARM: dts: ls1021a-tsn: remove undocumented property "position" from mma8452 node Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 15/16] ARM: dts: ls1021a: move thermal-zones node out of soc/ Li Yang
2021-10-01  0:04   ` Li Yang
2021-10-01  0:04 ` [PATCH v2 16/16] ARM: dts: ls1021a-tsn: use generic "jedec,spi-nor" compatible for flash Li Yang
2021-10-01  0:04   ` [PATCH v2 16/16] ARM: dts: ls1021a-tsn: use generic "jedec, spi-nor" " Li Yang
2021-10-01  5:14   ` [EXT] [PATCH v2 16/16] ARM: dts: ls1021a-tsn: use generic "jedec,spi-nor" " Kuldeep Singh
2021-10-01  5:14     ` Kuldeep Singh

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=CADRPPNSxLaG1WcxKY-KtBwJON51Rg5-euJNJnJObarjEKN2eSA@mail.gmail.com \
    --to=leoyang.li@nxp.com \
    --cc=devicetree@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@rempel-privat.de \
    --cc=robh@kernel.org \
    --cc=shawnguo@kernel.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 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.