Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp2102712ybn; Thu, 26 Sep 2019 07:06:03 -0700 (PDT) X-Google-Smtp-Source: APXvYqwEQ71z9z3azOdrA7S7Aj2EuZB0swy/6pyd32A4ncof+wut6rOqsGeyanr4nxcbLwHRWjfw X-Received: by 2002:a7b:cb55:: with SMTP id v21mr3224771wmj.53.1569506763395; Thu, 26 Sep 2019 07:06:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569506763; cv=none; d=google.com; s=arc-20160816; b=blnwDyyF10stDgyrMW2CezIjhgacdOBQKipiiaV92fx6rKg8bRgrgef+nt6TWidUIF mJVfSyQvE5KXISlSdmrXr0K+48CZuMz3V2NqcB+8a/5QIea7/9i+gCyj3AUjzkHjTQsG 5XcDvWRPkL3g5h5FPHaFdSTsVPoIoWt2nBojxrgvaUXhO8vF2p5uiQlBfAaZP/vmpSRs aEkQN1YW4nAyJ174qwSV9yPgda++f/Z1Ld14wSovX/+NYLEA8jgnxzhEzEVrC+S9P1Cf z8AnsokgpEOD/aZrRHhwsdU1VbBrjNbqRXKxxf2NsEvu5xIekQf1ar5Y9bFJ134isGPQ tsTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=whPrRyPjsEqHWkxa6+82YRMbs+ju315F0WTkmuF7zX0=; b=QnuhvzUxFbXhv013aNcnY3B3nDNQSJF43lawMv3Mt86vzzxSmYS8QWox8u317MoTED eJjuHbnpnDM2GXAJQgf3ItaP3UHEuz74RPLhu814RGATbfQ+ddh9LoEwEvfJREKb/Vg9 E+l73/mrAXg7Sv0d9yXRx+daSIYMWsNvjQC+nVeuXpzbhYRgRbytsixfRiSw8rPs+fhB GZZ29a1yD9vcg6y0KWDjBR4FQXIkWzrtlGs0bUpMSJniE1K59gU7E1lLQTICollIP9u3 V0ZuCf195WYjJ1db17mmDxGlv3UHNVcI95fkyWjbWcy+HF14y44Vj5NBi023D3VJ2be6 KoKg== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b16si1415898edb.341.2019.09.26.07.05.38; Thu, 26 Sep 2019 07:06:03 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727049AbfIZODW (ORCPT + 99 others); Thu, 26 Sep 2019 10:03:22 -0400 Received: from mail-wm1-f65.google.com ([209.85.128.65]:51332 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726216AbfIZODW (ORCPT ); Thu, 26 Sep 2019 10:03:22 -0400 Received: by mail-wm1-f65.google.com with SMTP id 7so2933323wme.1; Thu, 26 Sep 2019 07:03:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=whPrRyPjsEqHWkxa6+82YRMbs+ju315F0WTkmuF7zX0=; b=jabbRHfDsxfiZus/YT79T2RsfbL4uvDDHBQYq42FPVNxAtCsHrmVQhweCTPEiI/0kV U5TrrMRxVttNJAmTehh+UMhUflj7JHg3w97j6RKBTCDOdl8NBhlc8dFPHbIgxZLM8FZs Vcr9/EBsO6Zy8dQvxBPGJWrCDpYsZimlsGttNdOHPaC0rNSvJcfnAgFFOC9wfqwwuYDh m2Ww/Pg3SM9hSFAalJPytaQDGPCT+/wgKV5WW1s4BSzpwd358qA/fSa/lFCIl0wEiJtn h4xw99Q+D46vmwzuJ+uv97+Ttco7wXU3lX33UDuC14A0hwosWpnEnW9u4PLYU8EcmBBr 1xrQ== X-Gm-Message-State: APjAAAVEeJnDX8HrtvRFXMgIpMJAQ6JhG3F+iS0Nw1pnCeiginkA60BE EO9FOcgvpGctbbbddhuOvRY= X-Received: by 2002:a1c:9e0b:: with SMTP id h11mr3039065wme.144.1569506598528; Thu, 26 Sep 2019 07:03:18 -0700 (PDT) Received: from pi3 ([194.230.155.145]) by smtp.googlemail.com with ESMTPSA id y186sm4789915wmd.26.2019.09.26.07.03.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 26 Sep 2019 07:03:17 -0700 (PDT) Date: Thu, 26 Sep 2019 16:03:15 +0200 From: Krzysztof Kozlowski To: Marek Szyprowski Cc: devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, linux-samsung-soc@vger.kernel.org, Rob Herring , Mark Rutland , Inki Dae , Maciej Falkowski Subject: Re: [PATCH v2] dt-bindings: gpu: Convert Samsung Image Scaler to dt-schema Message-ID: <20190926140315.GA16002@pi3> References: <20190926125614.10408-1-m.szyprowski@samsung.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20190926125614.10408-1-m.szyprowski@samsung.com> User-Agent: Mutt/1.12.1 (2019-06-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 26, 2019 at 02:56:14PM +0200, Marek Szyprowski wrote: > From: Maciej Falkowski > > Convert Samsung Image Scaler to newer dt-schema format. > > Signed-off-by: Maciej Falkowski > Signed-off-by: Marek Szyprowski > --- > v2: > - Removed quotation marks from string in 'compatible' property > - Added if-then statement for 'clocks' and 'clock-names' property > - Added include directive to example > - Added GIC_SPI macro to example > > Best regards, > Maciej Falkowski > --- > .../bindings/gpu/samsung-scaler.txt | 27 ------- > .../bindings/gpu/samsung-scaler.yaml | 71 +++++++++++++++++++ > 2 files changed, 71 insertions(+), 27 deletions(-) > delete mode 100644 Documentation/devicetree/bindings/gpu/samsung-scaler.txt > create mode 100644 Documentation/devicetree/bindings/gpu/samsung-scaler.yaml > > diff --git a/Documentation/devicetree/bindings/gpu/samsung-scaler.txt b/Documentation/devicetree/bindings/gpu/samsung-scaler.txt > deleted file mode 100644 > index 9c3d98105dfd..000000000000 > --- a/Documentation/devicetree/bindings/gpu/samsung-scaler.txt > +++ /dev/null > @@ -1,27 +0,0 @@ > -* Samsung Exynos Image Scaler > - > -Required properties: > - - compatible : value should be one of the following: > - (a) "samsung,exynos5420-scaler" for Scaler IP in Exynos5420 > - (b) "samsung,exynos5433-scaler" for Scaler IP in Exynos5433 > - > - - reg : Physical base address of the IP registers and length of memory > - mapped region. > - > - - interrupts : Interrupt specifier for scaler interrupt, according to format > - specific to interrupt parent. > - > - - clocks : Clock specifier for scaler clock, according to generic clock > - bindings. (See Documentation/devicetree/bindings/clock/exynos*.txt) > - > - - clock-names : Names of clocks. For exynos scaler, it should be "mscl" > - on 5420 and "pclk", "aclk" and "aclk_xiu" on 5433. > - > -Example: > - scaler@12800000 { > - compatible = "samsung,exynos5420-scaler"; > - reg = <0x12800000 0x1294>; > - interrupts = <0 220 IRQ_TYPE_LEVEL_HIGH>; > - clocks = <&clock CLK_MSCL0>; > - clock-names = "mscl"; > - }; > diff --git a/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml b/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml > new file mode 100644 > index 000000000000..af19930d052e > --- /dev/null > +++ b/Documentation/devicetree/bindings/gpu/samsung-scaler.yaml > @@ -0,0 +1,71 @@ > +# SPDX-License-Identifier: GPL-2.0 > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/gpu/samsung-scaler.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Samsung Exynos SoC Image Scaler > + > +maintainers: > + - Inki Dae > + > +properties: > + compatible: > + enum: > + - samsung,exynos5420-scaler > + - samsung,exynos5433-scaler > + > + reg: > + maxItems: 1 > + > + interrupts: > + maxItems: 1 > + I am repeating myself... leave the clocks and clock-names. "I think it is worth to leave the clocks and clock-names here (could be empty or with min/max values for number of items). This makes it easy to find the properties by humans. Midgard bindings could be used as example." > +if: > + properties: > + compatible: > + contains: > + const: samsung,exynos5420-scaler > +then: > + properties: > + clocks: > + items: > + - description: mscl clock > + > + clock-names: > + items: > + - const: mscl > +else: > + properties: > + clocks: > + items: > + - description: mscl clock > + - description: aclk clock > + - description: aclk_xiu clock > + > + clock-names: > + items: > + - const: pclk > + - const: aclk > + - const: aclk_xiu > + > +required: > + - compatible > + - reg > + - interrupts > + - clocks > + - clock-names > + > +examples: > + - | > + #include > + #include > + > + scaler@12800000 { > + compatible = "samsung,exynos5420-scaler"; > + reg = <0x12800000 0x1294>; > + interrupts = ; > + clocks = <&clock CLK_MSCL0>; > + clock-names = "mscl"; > + }; > + Unneeded trailing line. Best regards, Krzysztof