Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp482034imm; Wed, 26 Sep 2018 01:52:11 -0700 (PDT) X-Google-Smtp-Source: ACcGV63W/+vuy0pkZjVc5yBTZamNikihUjpwQingmutirgW99/YlhSw4k2mSM6NcPnLSzGKIoDVb X-Received: by 2002:a63:cf4c:: with SMTP id b12-v6mr2692566pgj.418.1537951931100; Wed, 26 Sep 2018 01:52:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537951931; cv=none; d=google.com; s=arc-20160816; b=boUDqiTBaEvoJQYN18BGhwW/lJ+iK8m+GcpoPJmA9azi/UWzPFrWCliX/DRxYEKMiZ s/fl/WXerlfQRmTqOAOfQ6a58IlX7B8H90QCXkQAIOQuE1sF27xpSDzqYvZsgm4bf7k6 uvAg65RyzfL4jkPL6MbiGybwhAz2TxNG1U8rs+jUj6vVUeHB+EbNhVpeJVpFaiZO9bSj 3KpIm9wHYHY3TipSCYjxTctFm9MPhsxsSeH82TnrPlsiTNRHPswMfPzj+9S7V5zOBtJe kcg2WbOe5wQ0f2nDu8osM++6r1sgOzoxMBg9p5oSzZ9/QRQXCgPvfYUUtCd7yftEyNDP 6VAg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:autocrypt:openpgp:from:references:cc:to:subject :dkim-signature; bh=fTCeSqjBT3qZwJM4pZfg88xjzOAMDrkM9nA3EC0uYB8=; b=eHhz5nHCWKGYyJJoZGXjz13kG0oOP6EhLBLsXxXKw6QmTbX6JrK2OXae4LL8B/cyGc 2IsvS73ildGPVy+FUZr3anHig1tH4f908fkGefAYI/+2hJilT6UmAZhBiB9mfSrcjhWq n/uYJo/+7kRaijOdDzwgtXsllPGB0rwXu3rLoD5l4AJC5Zx1MmPubwbr2VavNGs5te/G dUZaBO14w7yGN8/GOd8ncEkMxigSgSzmr4nHqqDm7Cln1Znqm2BOVYNPeBwVEqtV5vnk fTktBlmC/ZGDUe0jYB+S3Edv1ZgOUt0+LRuZ0k+EsZJF1mH9IoCD0HYlHbbBWp9oKf6Z R1KA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=O3E98ykd; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t192-v6si4641270pgc.485.2018.09.26.01.51.54; Wed, 26 Sep 2018 01:52:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=O3E98ykd; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727570AbeIZPCM (ORCPT + 99 others); Wed, 26 Sep 2018 11:02:12 -0400 Received: from mail-ed1-f68.google.com ([209.85.208.68]:41301 "EHLO mail-ed1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726404AbeIZPCL (ORCPT ); Wed, 26 Sep 2018 11:02:11 -0400 Received: by mail-ed1-f68.google.com with SMTP id f38-v6so1158826edd.8; Wed, 26 Sep 2018 01:50:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:openpgp:autocrypt:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=fTCeSqjBT3qZwJM4pZfg88xjzOAMDrkM9nA3EC0uYB8=; b=O3E98ykdvik0MpFzgHkr+56RKYotl8CRRzY9xRwGwyDzOsGJteEW9y9unCNJ8WJKDn QiErtSg7pyZwtW9DPvpQVKDjF8W0O+4e8TwDoSaFRgdq3X/yv7ZlyKEeeJPXy9gz3eJD s/MZiU4W7ic1RgK+nIURlCGi/Voycicr4x2A0zNdKr0n3y4UTzW6VSS1vCSFBTVM8ORR c8eBcB8aMS/fH0+oUPauP5++qi1bsfkkcZpHlEyYv9cM2jNfPhRKwArjPh2Y7qU0zLix zyGv2+GDkvQL6H6z06YN8+g05lL5CVVze+i+mmxLTyHBx4v6feFq+T/R0m7mXhwPC7MQ Oxew== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:openpgp:autocrypt :message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=fTCeSqjBT3qZwJM4pZfg88xjzOAMDrkM9nA3EC0uYB8=; b=KNi65vVxPBAVtiopwKyQWJjKLzNW50QGEvcwrpYhualMtj/obpqoScUvm5+aeXmTjj /83CVfWcA8rw+9r0OwOWYUqIQ4+97hIEUQaGF+VsSCQFIkx1UJ3Qz4ge0NsR/U2dJg93 yXrwA1x1b2s0XT0+KbQk2MGge5b9SXjLtJv0Ey2Dqjh5wJrpmjruOupAenhB7k6kcYMI yNaROZqKRhZ905llIotVMvihR80p3hcQeU3W4SlstT0yIL8iY376w/q7TnBCcCwAH8ql GhcX5ZSjdZK/vN2Zfb9P8O1f37xrcLjejtWkmu/GybjSvqqcbpMK36svC6wNz0/6wZAm Pq8w== X-Gm-Message-State: ABuFfojqUUMqIvy2YTBm8jOAHbDHMwrra+cTv5W6uk5jQUMDpbf+R4q+ ODAN0oAJnofU/WqcMm4tTnI= X-Received: by 2002:aa7:c485:: with SMTP id m5-v6mr8109767edq.205.1537951816180; Wed, 26 Sep 2018 01:50:16 -0700 (PDT) Received: from ziggy.stardust ([37.223.146.97]) by smtp.gmail.com with ESMTPSA id e25-v6sm7628644edd.35.2018.09.26.01.50.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 26 Sep 2018 01:50:15 -0700 (PDT) Subject: Re: [Resend PATCH 5/5] arm: dts: mt7623: add display subsystem related device nodes To: CK Hu , Ryder Lee Cc: Rob Herring , Sean Wang , Roy Luo , Weijie Gao , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, chunhui dai , Bibby Hsieh References: <84011aa94dd7be9239b7a2f944dd30fc70568fbb.1536155449.git.ryder.lee@mediatek.com> <7105c341de3525761ad4067ca57c641c7097f773.1536155449.git.ryder.lee@mediatek.com> <1537925879.20118.3.camel@mtksdaap41> <1537929498.32631.16.camel@mtkswgap22> <1537939280.20005.19.camel@mtksdaap41> From: Matthias Brugger Openpgp: preference=signencrypt Autocrypt: addr=matthias.bgg@gmail.com; prefer-encrypt=mutual; keydata= xsFNBFP1zgUBEAC21D6hk7//0kOmsUrE3eZ55kjc9DmFPKIz6l4NggqwQjBNRHIMh04BbCMY fL3eT7ZsYV5nur7zctmJ+vbszoOASXUpfq8M+S5hU2w7sBaVk5rpH9yW8CUWz2+ZpQXPJcFa OhLZuSKB1F5JcvLbETRjNzNU7B3TdS2+zkgQQdEyt7Ij2HXGLJ2w+yG2GuR9/iyCJRf10Okq gTh//XESJZ8S6KlOWbLXRE+yfkKDXQx2Jr1XuVvM3zPqH5FMg8reRVFsQ+vI0b+OlyekT/Xe 0Hwvqkev95GG6x7yseJwI+2ydDH6M5O7fPKFW5mzAdDE2g/K9B4e2tYK6/rA7Fq4cqiAw1+u EgO44+eFgv082xtBez5WNkGn18vtw0LW3ESmKh19u6kEGoi0WZwslCNaGFrS4M7OH+aOJeqK fx5dIv2CEbxc6xnHY7dwkcHikTA4QdbdFeUSuj4YhIZ+0Q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zCx2cQi33jwvnJAK1o4VlNx36RfrxzBqc1uZGzJBCQu4 8UjmUSsTwWC3HpE/D9sM+xACs803lFUIZC5H62G059cCPAXKgsFpNMKmBAWweBkVJAisoQeX 50OP+/11ArV0cv+fOTfJj0/KwFXJaaYh3LUQNILLBNxkSrhCLl8dUg53IbHx4NfIAgqxLWGf XM8DY1aFdU79pac005PuhxCWkKTJz3gCmznnoat4GCnL5gy/m0Qk45l4PFqwWXVLo9AQg2Kp 3mlIFZ6fsEKIAN5hxlbNvNb9V2Zo5bFZjPWPFTxOteM0omUAS+QopwU0yPLLGJVf2iCmItHc UXI+r2JwH1CJjrHWeQEI2ucSKsNa8FllDmG/fQ== Message-ID: <67eb0b9c-f2a3-a9c4-202f-d3c64b6a2b3e@gmail.com> Date: Wed, 26 Sep 2018 10:50:13 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.0 MIME-Version: 1.0 In-Reply-To: <1537939280.20005.19.camel@mtksdaap41> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 26/09/2018 07:21, CK Hu wrote: > Hi, Ryder: > > On Wed, 2018-09-26 at 10:38 +0800, Ryder Lee wrote: >> On Wed, 2018-09-26 at 09:37 +0800, CK Hu wrote: >>> Hi, Ryder: >>> >>> On Wed, 2018-09-05 at 22:09 +0800, Ryder Lee wrote: >>>> Add display subsystem related device nodes for MT7623. >>>> >>>> Cc: CK Hu >>>> Signed-off-by: chunhui dai >>>> Signed-off-by: Bibby Hsieh >>>> Signed-off-by: Ryder Lee >>>> --- >>>> I forgot to sort nodes in my previous mail. Sorry for the inconvenience. >>>> >>>> This patch depends on the series: https://lkml.org/lkml/2018/9/5/223 >>>> >>>> @Matthias, >>>> I know you're working on broken MMSYS - just want to ask whether it's possible >>>> to let the patch to go to your tree (if others are okay with it), and send a >>>> fixup one for MT7623 MMSYS later? >>>> --- >>>> arch/arm/boot/dts/mt7623.dtsi | 177 ++++++++++++++++++++++++++ >>>> arch/arm/boot/dts/mt7623n-bananapi-bpi-r2.dts | 83 ++++++++++++ >>>> arch/arm/boot/dts/mt7623n-rfb-emmc.dts | 83 ++++++++++++ >>>> 3 files changed, 343 insertions(+) >>>> >>>> diff --git a/arch/arm/boot/dts/mt7623.dtsi b/arch/arm/boot/dts/mt7623.dtsi >>>> index d01bdee..fdf9078 100644 >>>> --- a/arch/arm/boot/dts/mt7623.dtsi >>>> +++ b/arch/arm/boot/dts/mt7623.dtsi >>>> @@ -23,6 +23,11 @@ >>>> #address-cells = <2>; >>>> #size-cells = <2>; >>>> >>>> + aliases { >>>> + rdma0 = &rdma0; >>>> + rdma1 = &rdma1; >>>> + }; >>>> + >>>> cpu_opp_table: opp-table { >>>> compatible = "operating-points-v2"; >>>> opp-shared; >>>> @@ -311,6 +316,25 @@ >>>> clock-names = "spi", "wrap"; >>>> }; >>>> >>>> + mipi_tx0: mipi-dphy@10010000 { >>>> + compatible = "mediatek,mt7623-mipi-tx", >>>> + "mediatek,mt2701-mipi-tx"; >>>> + reg = <0 0x10010000 0 0x90>; >>>> + clocks = <&clk26m>; >>>> + clock-output-names = "mipi_tx0_pll"; >>>> + #clock-cells = <0>; >>>> + #phy-cells = <0>; >>>> + }; >>>> + >>>> + cec: cec@10012000 { >>>> + compatible = "mediatek,mt7623-cec", >>>> + "mediatek,mt8173-cec"; >>>> + reg = <0 0x10012000 0 0xbc>; >>>> + interrupts = ; >>>> + clocks = <&infracfg CLK_INFRA_CEC>; >>>> + status = "disabled"; >>>> + }; >>>> + >>>> cir: cir@10013000 { >>>> compatible = "mediatek,mt7623-cir"; >>>> reg = <0 0x10013000 0 0x1000>; >>>> @@ -359,6 +383,18 @@ >>>> #clock-cells = <1>; >>>> }; >>>> >>>> + hdmi_phy: phy@10209100 { >>>> + compatible = "mediatek,mt7623-hdmi-phy", >>>> + "mediatek,mt2701-hdmi-phy"; >>>> + reg = <0 0x10209100 0 0x24>; >>>> + clocks = <&apmixedsys CLK_APMIXED_HDMI_REF>; >>>> + clock-names = "pll_ref"; >>>> + clock-output-names = "hdmitx_dig_cts"; >>>> + #clock-cells = <0>; >>>> + #phy-cells = <0>; >>>> + status = "disabled"; >>>> + }; >>>> + >>>> rng: rng@1020f000 { >>>> compatible = "mediatek,mt7623-rng"; >>>> reg = <0 0x1020f000 0 0x1000>; >>>> @@ -558,6 +594,16 @@ >>>> status = "disabled"; >>>> }; >>>> >>>> + hdmiddc0: i2c@11013000 { >>>> + compatible = "mediatek,mt7623-hdmi-ddc", >>>> + "mediatek,mt8173-hdmi-ddc"; >>>> + interrupts = ; >>>> + reg = <0 0x11013000 0 0x1C>; >>>> + clocks = <&pericfg CLK_PERI_I2C3>; >>>> + clock-names = "ddc-i2c"; >>>> + status = "disabled"; >>>> + }; >>>> + >>>> nor_flash: spi@11014000 { >>>> compatible = "mediatek,mt7623-nor", >>>> "mediatek,mt8173-nor"; >>>> @@ -732,6 +778,84 @@ >>>> #clock-cells = <1>; >>>> }; >>>> >>>> + display_components: dispsys@14000000 { >>>> + compatible = "mediatek,mt7623-mmsys", >>> >>> Checkpatch warning: >>> >>> WARNING: DT compatible string "mediatek,mt7623-mmsys" appears >>> un-documented -- check ./Documentation/devicetree/bindings/ >>> #101: FILE: arch/arm/boot/dts/mt7623.dtsi:782: >>> + compatible = "mediatek,mt7623-mmsys", >>> >>> >>>> + "mediatek,mt2701-mmsys"; >>>> + reg = <0 0x14000000 0 0x1000>; >>>> + power-domains = <&scpsys MT2701_POWER_DOMAIN_DISP>; >>>> + }; >>>> + >>>> + ovl@14007000 { >>>> + compatible = "mediatek,mt7623-disp-ovl", >>> >>> I think this is also un-documented, but I don't know why checkpatch does >>> not show any warning. >>> >>> Regards, >>> CK >>>> + "mediatek,mt2701-disp-ovl"; >>>> + reg = <0 0x14007000 0 0x1000>; >>>> + interrupts = ; >>>> + clocks = <&mmsys CLK_MM_DISP_OVL>; >>>> + iommus = <&iommu MT2701_M4U_PORT_DISP_OVL_0>; >>>> + mediatek,larb = <&larb0>; >>>> + }; >>>> + >> >> I fallback to use the MT2701's compatible string here and there, but I >> could add a new one for MT7623. >> >> BTW, I've had this question for a long time - should I add a new >> compatible for the very same IPs, or could we just use the old one in >> DTS? >> >> Ryder >> > > From [1], there is a description for the multiple compatible string > scheme: > > ==== > The reasoning behind this scheme is the observation that in the majority > of cases, a single machine_desc can support a large number of boards > if they all use the same SoC, or same family of SoCs. However, > invariably there will be some exceptions where a specific board will > require special setup code that is not useful in the generic case. > Special cases could be handled by explicitly checking for the > troublesome board(s) in generic setup code, but doing so very quickly > becomes ugly and/or unmaintainable if it is more than just a couple of > cases. > > Instead, the compatible list allows a generic machine_desc to provide > support for a wide common set of boards by specifying "less > compatible" values in the dt_compat list. In the example above, > generic board support can claim compatibility with "ti,omap3" or > "ti,omap3450". If a bug was discovered on the original beagleboard > that required special workaround code during early boot, then a new > machine_desc could be added which implements the workarounds and only > matches on "ti,omap3-beagleboard". > ==== > > I don't know would there be a problem happened only in MT7623 even > though this hardware is identical in both MT2701 and MT7623. Maybe the > system-wide configuration would influence this driver. So the easy way > is to add the compatible string for MT7623. If you could prove that > this driver would never be influenced by system-wide configuration, > using only MT2701 compatible string is acceptable for me. > > This is my opinion, but the most important is maintainer's opinion. > The compatible string looks good. But you should update the binding documentation :) Regards, Matthias