linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzk@kernel.org>
To: Chanwoo Choi <cwchoi00@gmail.com>
Cc: Andi Shyti <andi@etezian.org>,
	Javier Martinez Canillas <javier@osg.samsung.com>,
	Andi Shyti <andi.shyti@samsung.com>,
	Mark Rutland <mark.rutland@arm.com>,
	devicetree <devicetree@vger.kernel.org>,
	linux-samsung-soc <linux-samsung-soc@vger.kernel.org>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	Catalin Marinas <catalin.marinas@arm.com>,
	Jaechul Lee <jcsing.lee@samsung.com>,
	Will Deacon <will.deacon@arm.com>,
	linux-kernel <linux-kernel@vger.kernel.org>,
	Krzysztof Kozlowski <krzk@kernel.org>,
	Chanwoo Choi <cw00.choi@samsung.com>,
	Rob Herring <robh+dt@kernel.org>, Kukjin Kim <kgene@kernel.org>,
	linux-input@vger.kernel.org, galaxyra@gmail.com,
	beomho.seo@samsung.com,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH 3/4] arm64: dts: exynos: make tm2 and tm2e independent from each other
Date: Tue, 3 Jan 2017 18:31:36 +0200	[thread overview]
Message-ID: <20170103163136.rzoswklqevoeugn4@kozik-lap> (raw)
In-Reply-To: <CAGTfZH0tnjkqF_7DChLSvzs3C369mkb_HZmyrf3cc0T-UcBZ4A@mail.gmail.com>

On Wed, Jan 04, 2017 at 12:29:23AM +0900, Chanwoo Choi wrote:
> Hi Andi,
> 
> 2017-01-03 23:40 GMT+09:00 Andi Shyti <andi@etezian.org>:
> > Hi,
> >
> >> FWIW, I also agree with Chanwoo that the difference is too small to
> >> need a common .dtsi file.
> >
> > in principle I don't like "switching on and off" properties by
> > overwriting them with "status = disable", unless it's really
> > necessary (and this case is not). Even for small differences. It
> > makes the DTS harder to read and duplicates nodes with different
> > values throughout the DTS include chain.

I agree.

> >
> > In my opinion this approach should be discouraged.
> >
> > Besides, there are other overwritten differences in tm2e.dts that
> > I think should be separated as well. The "common" file approach is
> > widely used in arm/boot/dts/exynos* files.

I agree. Mostly we use:
1. Common DTSI and final addons/customizations in DTS.
2. Several common DTSI for specific parts (like sound).

> > The "status = disable" looks to me more like a temporary hack
> > rather than a permanent solution.
> >
> > In any case, still up to you :)
> >
> > Andi
> 
> I think that "status=disabled" of hsi2c_9 is not hack. The overwrite
> is possible for Device-tree. But, there is just difference how to
> support them with some method.
> 
> Except for touchkey, all peripheral device are same on both tm2 and
> tm2e. There are only small difference for a few property value.
> 
> To understand the difference between tm2 and tm2e, I made the patch
> (it is not complete version). If we implement the following patch, we
> support both tm2 and tm2e. So, I think that it is not complex to
> understand the h/w difference between tm2 and tm2e.

The difference below (I removed it from the quote) is indeed very small,
thanks Chanwoo for pointing this. However having common DTSI should not
end with much bigger final diff between files. I mean that it should be
the same amount of lines in total...

Actually, after applying this patch, the final exynos5433-tm2e.dts is
exactly the same as before. To me, this is a indication that a common
file is a good approach.


>From a separate Javier's mail:
> On 01/03/2017 11:40 AM, Andi Shyti wrote:
> > Hi,
> > 
> >> FWIW, I also agree with Chanwoo that the difference is too small to
> >> need a common .dtsi file.
> > 
> > in principle I don't like "switching on and off" properties by
> > overwriting them with "status = disable", unless it's really
> 
> This is a very good point. It would had been different if it was the
> opposite and tm2e had to enable the device node, but disabling it is
> indeed more confusing.
> On 01/03/2017 11:40 AM, Andi Shyti wrote:
> > Hi,
> > 
> >> FWIW, I also agree with Chanwoo that the difference is too small to
> >> need a common .dtsi file.
> > 
> > in principle I don't like "switching on and off" properties by
> > overwriting them with "status = disable", unless it's really
> 
> This is a very good point. It would had been different if it was the
> opposite and tm2e had to enable the device node, but disabling it is
> indeed more confusing.

I agree, 'status = disable' in final DTS is not a common pattern and
to me when reading, it makes me wonder what was the author's intention.

Also including a DTS in DTS is not a common pattern, neither. It appears
(git grep include arch/arm/boot/dts | grep 'dts"') in few places but it
is not obvious. At least to me.

Overall, I prefer the common approach.

Best regards,
Krzysztof

  reply	other threads:[~2017-01-03 16:34 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20170103075733epcas5p48985c789a816f1f2eae84c52e070cc14@epcas5p4.samsung.com>
2017-01-03  7:57 ` [PATCH 0/4] Add touch key driver support for TM2 Jaechul Lee
     [not found]   ` <CGME20170103075733epcas5p47dff8d21854938b2439c9843d91bc301@epcas5p4.samsung.com>
2017-01-03  7:57     ` [PATCH 1/4] input: Add support for the tm2 touchkey device driver Jaechul Lee
2017-01-03 12:26       ` Javier Martinez Canillas
2017-01-04 14:15       ` Rob Herring
     [not found]   ` <CGME20170103075733epcas5p4a065198d4abf35081024af95055c67d2@epcas5p4.samsung.com>
2017-01-03  7:57     ` [PATCH 2/4] input: tm2-touchkey: Add touchkey driver support for TM2 Jaechul Lee
2017-01-03 13:11       ` Javier Martinez Canillas
2017-01-03 18:56         ` Dmitry Torokhov
2017-01-03 16:59       ` Krzysztof Kozlowski
     [not found]   ` <CGME20170103075734epcas5p43a9743131f63affd0a438d2ed342f22e@epcas5p4.samsung.com>
2017-01-03  7:57     ` [PATCH 3/4] arm64: dts: exynos: make tm2 and tm2e independent from each other Jaechul Lee
2017-01-03  8:16       ` Andi Shyti
2017-01-03  8:27       ` Krzysztof Kozlowski
2017-01-03  9:58         ` Andi Shyti
2017-01-03 10:01           ` Krzysztof Kozlowski
2017-01-03 10:25             ` Andi Shyti
2017-01-03 11:47               ` Chanwoo Choi
2017-01-03 11:55                 ` Andi Shyti
2017-01-03 12:15                   ` Javier Martinez Canillas
2017-01-03 14:40                     ` Andi Shyti
2017-01-03 14:57                       ` Javier Martinez Canillas
2017-01-03 15:29                       ` Chanwoo Choi
2017-01-03 16:31                         ` Krzysztof Kozlowski [this message]
2017-01-03 16:41               ` Krzysztof Kozlowski
     [not found]   ` <CGME20170103075734epcas5p439b05860a3238ce638f683d9687786a3@epcas5p4.samsung.com>
2017-01-03  7:57     ` [PATCH 4/4] arm64: dts: exynos: Add tm2 touchkey node Jaechul Lee
2017-01-03 13:14       ` Javier Martinez Canillas
2017-01-03 16:49       ` Krzysztof Kozlowski

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=20170103163136.rzoswklqevoeugn4@kozik-lap \
    --to=krzk@kernel.org \
    --cc=andi.shyti@samsung.com \
    --cc=andi@etezian.org \
    --cc=beomho.seo@samsung.com \
    --cc=catalin.marinas@arm.com \
    --cc=cw00.choi@samsung.com \
    --cc=cwchoi00@gmail.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=galaxyra@gmail.com \
    --cc=javier@osg.samsung.com \
    --cc=jcsing.lee@samsung.com \
    --cc=kgene@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=will.deacon@arm.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).