All of lore.kernel.org
 help / color / mirror / Atom feed
From: Grant Likely <grant.likely@secretlab.ca>
To: Kumar Gala <galak@codeaurora.org>, Sascha Hauer <s.hauer@pengutronix.de>
Cc: Mark Rutland <mark.rutland@arm.com>,
	devicetree@vger.kernel.org, linux-fbdev@vger.kernel.org,
	Pawel Moll <pawel.moll@arm.com>,
	Stephen Warren <swarren@wwwdotorg.org>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	Rob Herring <rob.herring@calxeda.com>,
	Denis Carikli <denis@eukrea.com>,
	Tomi Valkeinen <tomi.valkeinen@ti.com>,
	Sascha Hauer <kernel@pengutronix.de>,
	Shawn Guo <shawn.guo@linaro.org>,
	Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCHv3][ 3/5] video: mx3fb: Add device tree suport.
Date: Sun, 27 Oct 2013 13:56:03 +0000	[thread overview]
Message-ID: <20131027135603.1589FC4039D@trevor.secretlab.ca> (raw)
In-Reply-To: <93D2899F-E285-4794-8F32-AD55360A4A80@codeaurora.org>

[-- Attachment #1: Type: text/plain, Size: 4762 bytes --]

On Sat, 26 Oct 2013 01:43:23 -0500, Kumar Gala <galak@codeaurora.org> wrote:
> 
> On Oct 25, 2013, at 7:18 PM, Sascha Hauer wrote:
> 
> > On Fri, Oct 25, 2013 at 08:50:40PM +0100, Grant Likely wrote:
> >> On Wed, 23 Oct 2013 14:43:47 +0200, Denis Carikli <denis@eukrea.com> wrote:
> >>> Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>
> >>> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
> >>> Cc: linux-fbdev@vger.kernel.org
> >>> Cc: Rob Herring <rob.herring@calxeda.com>
> >>> Cc: Pawel Moll <pawel.moll@arm.com>
> >>> Cc: Mark Rutland <mark.rutland@arm.com>
> >>> Cc: Stephen Warren <swarren@wwwdotorg.org>
> >>> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk>
> >>> Cc: devicetree@vger.kernel.org
> >>> Cc: Sascha Hauer <kernel@pengutronix.de>
> >>> Cc: linux-arm-kernel@lists.infradead.org
> >>> Cc: Eric Bénard <eric@eukrea.com>
> >>> Signed-off-by: Denis Carikli <denis@eukrea.com>
> >>> ---
> >>> ChangeLog v2->v3:
> >>> - The device tree bindings were reworked in order to make it look more like the
> >>>  IPUv3 bindings.
> >>> - The interface_pix_fmt property now looks like the IPUv3 one.
> >>> ---
> >>> .../devicetree/bindings/video/fsl,mx3-fb.txt       |   35 ++++++
> >>> drivers/video/Kconfig                              |    2 +
> >>> drivers/video/mx3fb.c                              |  125 +++++++++++++++++---
> >>> 3 files changed, 147 insertions(+), 15 deletions(-)
> >>> create mode 100644 Documentation/devicetree/bindings/video/fsl,mx3-fb.txt
> >>> 
> >>> diff --git a/Documentation/devicetree/bindings/video/fsl,mx3-fb.txt b/Documentation/devicetree/bindings/video/fsl,mx3-fb.txt
> >>> new file mode 100644
> >>> index 0000000..0b31374
> >>> --- /dev/null
> >>> +++ b/Documentation/devicetree/bindings/video/fsl,mx3-fb.txt
> >>> @@ -0,0 +1,35 @@
> >>> +Freescale MX3 fb
> >>> +================
> >>> +
> >>> +Required properties:
> >>> +- compatible: Should be "fsl,mx3fb". compatible chips include the imx31 and the
> >>> +  imx35.
> >>> +- reg: should be register base and length as documented in the datasheet.
> >>> +- clocks: Handle to the ipu_gate clock.
> >>> +
> >>> +Example:
> >>> +
> >>> +lcdc: mx3fb@53fc00b4 {
> >>> +	compatible = "fsl,mx3-fb";
> >>> +	reg = <0x53fc00b4 0x0b>;
> >>> +	clocks = <&clks 55>;
> >>> +};
> >> 
> >> This (and some of the other bindings) are trivial, and they are all
> >> associated with a single SoC. I think it would be better to collect all
> >> the mx3 bindings into a single file rather than distributing them all
> >> over the bindings tree.
> >> 
> >> I started thinking about this after some of the DT conversations in
> >> Edinburgh this week. Unless there is a high likelyhood of components
> >> being used separately, I think it is far more useful to collect all the
> >> bindings for an SoC into a single file. It will certainly reduce a lot
> >> of the boilerplate that we've been collecting in bindings documentation
> >> files.
> >> 
> >> A long time ago I took that approach for the mpc5200 documentation[1].
> >> Take a look at that organization and let me know what you think.
> > 
> > I don't think this is a good idea. When a new SoC comes out we don't
> > know which components will be reused on the next SoC. This will cause a
> > lot of bikeshedding when it actually is reused and then has to be moved.
> > 
> > Also I would find it quite inconsistent if I had to lookup some devices
> > in a SoC file and most bindings in subsystem specific files. So when
> > searching for a binding I would first have to know if the hardware is
> > unique to the SoC or not.
> 
> I agree that as new SoC come out its better to have these things split
> out.  Also for IP that is sold by vendors like Synopsys/Designware
> that get used on a lot of SoCs its makes it easier to ensure
> consistency by having the binding split out for the IP and not the
> SoC.

After looking at how many files we're now creating under
Documentation/devicetree/bindings, I'm starting to think we need to go
entirely the other way and put whole the whole family of an SoC into a
single binding file, particularly for the SoC integration level stuff
that isn't likely to be shared with SoCs from other vendors.

A decision on this can be deferred as we're working on schema tools.
Some of that may fall out when we figure out what the structure of the
schema files should be.

> Also, by having bindings for similar devices for different SoCs kept together it becomes easier for us to see patterns across SoCs as we might come up with a more generic binding in the future.  Far more difficult if things are SoC oriented.

The downside is bindings for a single SoC get distributed among a lot of
files which makes it more difficult to follow how the SoC is put
together and configured.

g.



[-- Attachment #2: Type: text/plain, Size: 176 bytes --]

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

WARNING: multiple messages have this Message-ID (diff)
From: grant.likely@secretlab.ca (Grant Likely)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv3][ 3/5] video: mx3fb: Add device tree suport.
Date: Sun, 27 Oct 2013 13:56:03 +0000	[thread overview]
Message-ID: <20131027135603.1589FC4039D@trevor.secretlab.ca> (raw)
In-Reply-To: <93D2899F-E285-4794-8F32-AD55360A4A80@codeaurora.org>

On Sat, 26 Oct 2013 01:43:23 -0500, Kumar Gala <galak@codeaurora.org> wrote:
> 
> On Oct 25, 2013, at 7:18 PM, Sascha Hauer wrote:
> 
> > On Fri, Oct 25, 2013 at 08:50:40PM +0100, Grant Likely wrote:
> >> On Wed, 23 Oct 2013 14:43:47 +0200, Denis Carikli <denis@eukrea.com> wrote:
> >>> Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>
> >>> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
> >>> Cc: linux-fbdev at vger.kernel.org
> >>> Cc: Rob Herring <rob.herring@calxeda.com>
> >>> Cc: Pawel Moll <pawel.moll@arm.com>
> >>> Cc: Mark Rutland <mark.rutland@arm.com>
> >>> Cc: Stephen Warren <swarren@wwwdotorg.org>
> >>> Cc: Ian Campbell <ijc+devicetree@hellion.org.uk>
> >>> Cc: devicetree at vger.kernel.org
> >>> Cc: Sascha Hauer <kernel@pengutronix.de>
> >>> Cc: linux-arm-kernel at lists.infradead.org
> >>> Cc: Eric B??nard <eric@eukrea.com>
> >>> Signed-off-by: Denis Carikli <denis@eukrea.com>
> >>> ---
> >>> ChangeLog v2->v3:
> >>> - The device tree bindings were reworked in order to make it look more like the
> >>>  IPUv3 bindings.
> >>> - The interface_pix_fmt property now looks like the IPUv3 one.
> >>> ---
> >>> .../devicetree/bindings/video/fsl,mx3-fb.txt       |   35 ++++++
> >>> drivers/video/Kconfig                              |    2 +
> >>> drivers/video/mx3fb.c                              |  125 +++++++++++++++++---
> >>> 3 files changed, 147 insertions(+), 15 deletions(-)
> >>> create mode 100644 Documentation/devicetree/bindings/video/fsl,mx3-fb.txt
> >>> 
> >>> diff --git a/Documentation/devicetree/bindings/video/fsl,mx3-fb.txt b/Documentation/devicetree/bindings/video/fsl,mx3-fb.txt
> >>> new file mode 100644
> >>> index 0000000..0b31374
> >>> --- /dev/null
> >>> +++ b/Documentation/devicetree/bindings/video/fsl,mx3-fb.txt
> >>> @@ -0,0 +1,35 @@
> >>> +Freescale MX3 fb
> >>> +================
> >>> +
> >>> +Required properties:
> >>> +- compatible: Should be "fsl,mx3fb". compatible chips include the imx31 and the
> >>> +  imx35.
> >>> +- reg: should be register base and length as documented in the datasheet.
> >>> +- clocks: Handle to the ipu_gate clock.
> >>> +
> >>> +Example:
> >>> +
> >>> +lcdc: mx3fb at 53fc00b4 {
> >>> +	compatible = "fsl,mx3-fb";
> >>> +	reg = <0x53fc00b4 0x0b>;
> >>> +	clocks = <&clks 55>;
> >>> +};
> >> 
> >> This (and some of the other bindings) are trivial, and they are all
> >> associated with a single SoC. I think it would be better to collect all
> >> the mx3 bindings into a single file rather than distributing them all
> >> over the bindings tree.
> >> 
> >> I started thinking about this after some of the DT conversations in
> >> Edinburgh this week. Unless there is a high likelyhood of components
> >> being used separately, I think it is far more useful to collect all the
> >> bindings for an SoC into a single file. It will certainly reduce a lot
> >> of the boilerplate that we've been collecting in bindings documentation
> >> files.
> >> 
> >> A long time ago I took that approach for the mpc5200 documentation[1].
> >> Take a look at that organization and let me know what you think.
> > 
> > I don't think this is a good idea. When a new SoC comes out we don't
> > know which components will be reused on the next SoC. This will cause a
> > lot of bikeshedding when it actually is reused and then has to be moved.
> > 
> > Also I would find it quite inconsistent if I had to lookup some devices
> > in a SoC file and most bindings in subsystem specific files. So when
> > searching for a binding I would first have to know if the hardware is
> > unique to the SoC or not.
> 
> I agree that as new SoC come out its better to have these things split
> out.  Also for IP that is sold by vendors like Synopsys/Designware
> that get used on a lot of SoCs its makes it easier to ensure
> consistency by having the binding split out for the IP and not the
> SoC.

After looking at how many files we're now creating under
Documentation/devicetree/bindings, I'm starting to think we need to go
entirely the other way and put whole the whole family of an SoC into a
single binding file, particularly for the SoC integration level stuff
that isn't likely to be shared with SoCs from other vendors.

A decision on this can be deferred as we're working on schema tools.
Some of that may fall out when we figure out what the structure of the
schema files should be.

> Also, by having bindings for similar devices for different SoCs kept together it becomes easier for us to see patterns across SoCs as we might come up with a more generic binding in the future.  Far more difficult if things are SoC oriented.

The downside is bindings for a single SoC get distributed among a lot of
files which makes it more difficult to follow how the SoC is put
together and configured.

g.

  reply	other threads:[~2013-10-27 13:56 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-10-23 12:43 [PATCHv3][ 1/5] fbdev: Add the lacking FB_SYNC_* for matching the DISPLAY_FLAGS_* Denis Carikli
2013-10-23 12:43 ` Denis Carikli
2013-10-23 12:43 ` Denis Carikli
     [not found] ` <1382532229-32755-1-git-send-email-denis-fO0SIAKYzcbQT0dZR+AlfA@public.gmane.org>
2013-10-23 12:43   ` [PATCHv3][ 2/5] dma: ipu: Add devicetree support Denis Carikli
2013-10-23 12:43     ` Denis Carikli
2013-10-23 12:43   ` [PATCHv3][ 3/5] video: mx3fb: Add device tree suport Denis Carikli
2013-10-23 12:43     ` Denis Carikli
2013-10-23 12:43     ` Denis Carikli
2013-10-25 19:50     ` Grant Likely
2013-10-25 19:50       ` Grant Likely
     [not found]       ` <20131025195040.0CCC3C404DA-WNowdnHR2B42iJbIjFUEsiwD8/FfD2ys@public.gmane.org>
2013-10-26  0:18         ` Sascha Hauer
2013-10-26  0:18           ` Sascha Hauer
2013-10-26  0:18           ` Sascha Hauer
     [not found]           ` <20131026001854.GE17135-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2013-10-26  6:43             ` Kumar Gala
2013-10-26  6:43               ` Kumar Gala
2013-10-26  6:43               ` Kumar Gala
2013-10-27 13:56               ` Grant Likely [this message]
2013-10-27 13:56                 ` Grant Likely
     [not found]     ` <1382532229-32755-3-git-send-email-denis-fO0SIAKYzcbQT0dZR+AlfA@public.gmane.org>
2013-10-26  6:40       ` Kumar Gala
2013-10-26  6:40         ` Kumar Gala
2013-10-26  6:40         ` Kumar Gala
2013-10-23 12:43   ` [PATCHv3][ 5/5] ARM: dts: mbimxsd35 Add video and displays support Denis Carikli
2013-10-23 12:43     ` Denis Carikli
2013-10-23 12:43     ` Denis Carikli
2013-10-23 12:43 ` [PATCHv3][ 4/5] video: mx3fb: Introduce regulator support Denis Carikli
2013-10-23 12:43   ` Denis Carikli
2013-10-29 10:35 ` [PATCHv3][ 1/5] fbdev: Add the lacking FB_SYNC_* for matching the DISPLAY_FLAGS_* Tomi Valkeinen
2013-10-29 10:35   ` Tomi Valkeinen
2013-10-29 10:35   ` Tomi Valkeinen

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=20131027135603.1589FC4039D@trevor.secretlab.ca \
    --to=grant.likely@secretlab.ca \
    --cc=denis@eukrea.com \
    --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-fbdev@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=plagnioj@jcrosoft.com \
    --cc=rob.herring@calxeda.com \
    --cc=s.hauer@pengutronix.de \
    --cc=shawn.guo@linaro.org \
    --cc=swarren@wwwdotorg.org \
    --cc=tomi.valkeinen@ti.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.