From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-14.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BC3ECC433DB for ; Wed, 13 Jan 2021 15:39:49 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7A7E8208BA for ; Wed, 13 Jan 2021 15:39:49 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7A7E8208BA Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References:Message-ID: Subject:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=ZDoWt6zbRa4B0AK8LxOF5jwmapxRWxM6swNFbQTU4C4=; b=xKNnW/kZivmwdE+Jt/OdMsBaU bTNmjRlsIpesX5g+k6aSCzSaMa+JRrBmwZ/K95rdQCk93pdonsiyk80HbFPTXN7sa75+7WKd+sNV0 eaEtYR3LCxLoHEL3C7BmOZoOFoIVKXWhMUcsYorEydS/27rnXuQ/+ofvHxuRq1UQVc+zrB6nyBvmB TK9Ffc+0Wy89dve9SZDZAeaLexY4rj/vWDXN8whurSJVw/IGfhR0lEglbyWgPCBVjzQ3A9bSdIv1d MuvdydS5HnGxOF0RfLPOKSv31yVdsErCfngevFduadZFwOeuBSQsrOBblyb5Iw4HyUCi1zSr8wrkc z0XujDfpQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kziDC-0005yd-RB; Wed, 13 Jan 2021 15:37:30 +0000 Received: from mail-oo1-f54.google.com ([209.85.161.54]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kziD5-0005wg-UW for linux-arm-kernel@lists.infradead.org; Wed, 13 Jan 2021 15:37:28 +0000 Received: by mail-oo1-f54.google.com with SMTP id j8so617099oon.3 for ; Wed, 13 Jan 2021 07:37:23 -0800 (PST) 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; bh=5kG+UaHsX0V2DzmZsJoGVERE52cozjiwmwEVWUmr6BI=; b=PfWzXORvVqbr7ifOcWPglnWHx6N5XAWd9gN3YTMX91tixivY4UD6znp25KlQkxN//a lU/IZbLnnCzTjwMwdgJGyN88ebF/sjRfwzJVpFru4og47/+YqtXGjTtotALFA5/KrHWr to1V/kUY9Au1LfNl5Ahiv+6WUPw8cl3POnSHkD1950A9RCW4GCXZm1UKdfb5EEu/KUyT macPHB448sdUZs9YOtEPJyllq/od9awaCmTJ6nmmtlEkkyVk3hnIe62V5T88peO6/UxL eSqj/FADkRvzbcIl+PCSyWaZZwb5hL/1rSwuK1wXUs/MmMhtGRTQ4Wql4bXWgS+8iZcc Onjg== X-Gm-Message-State: AOAM530ZEZw+phcS0oOTKeTwErUA3vtW6Vdbh06rNogbhJkjbq1Eu5jY vju4hX7jkkOUR4xCbeuo6A== X-Google-Smtp-Source: ABdhPJz9xwVKMJuGX/FtAZ5bpt3tFVGkkyKSZAa9e6zltw1cl6vr7ZrxhX4LFcwReYcQSRExztNTvQ== X-Received: by 2002:a4a:e8d1:: with SMTP id h17mr1609987ooe.71.1610552242970; Wed, 13 Jan 2021 07:37:22 -0800 (PST) Received: from robh.at.kernel.org (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.gmail.com with ESMTPSA id p132sm439131oia.41.2021.01.13.07.37.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Jan 2021 07:37:22 -0800 (PST) Received: (nullmailer pid 2494140 invoked by uid 1000); Wed, 13 Jan 2021 15:37:21 -0000 Date: Wed, 13 Jan 2021 09:37:21 -0600 From: Rob Herring To: Stefan Wahren Subject: Re: [PATCH V3] dt-bindings: gpu: Convert v3d to json-schema Message-ID: <20210113153721.GA2483761@robh.at.kernel.org> References: <1610189433-29985-1-git-send-email-stefan.wahren@i2se.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1610189433-29985-1-git-send-email-stefan.wahren@i2se.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210113_103724_484897_E0E57516 X-CRM114-Status: GOOD ( 28.53 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, David Airlie , dri-devel@lists.freedesktop.org, Eric Anholt , Maxime Ripard , Daniel Vetter , Nicolas Saenz Julienne Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Sat, Jan 09, 2021 at 11:50:32AM +0100, Stefan Wahren wrote: > This converts the v3d bindings to yaml format. > > Signed-off-by: Stefan Wahren > --- > > Changes in V3: > - drop redundant maxItems in case we already have items defined > - fix order of reg-names enum > - tag required items in description > - add reg-names to required properties > - drop clock-names > > .../devicetree/bindings/gpu/brcm,bcm-v3d.txt | 33 ---------- > .../devicetree/bindings/gpu/brcm,bcm-v3d.yaml | 72 ++++++++++++++++++++++ > 2 files changed, 72 insertions(+), 33 deletions(-) > delete mode 100644 Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > create mode 100644 Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > > diff --git a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > deleted file mode 100644 > index b2df82b..0000000 > --- a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > +++ /dev/null > @@ -1,33 +0,0 @@ > -Broadcom V3D GPU > - > -Only the Broadcom V3D 3.x and newer GPUs are covered by this binding. > -For V3D 2.x, see brcm,bcm-vc4.txt. > - > -Required properties: > -- compatible: Should be "brcm,7268-v3d" or "brcm,7278-v3d" > -- reg: Physical base addresses and lengths of the register areas > -- reg-names: Names for the register areas. The "hub" and "core0" > - register areas are always required. The "gca" register area > - is required if the GCA cache controller is present. The > - "bridge" register area is required if an external reset > - controller is not present. > -- interrupts: The interrupt numbers. The first interrupt is for the hub, > - while the following interrupts are separate interrupt lines > - for the cores (if they don't share the hub's interrupt). > - See bindings/interrupt-controller/interrupts.txt > - > -Optional properties: > -- clocks: The core clock the unit runs on > -- resets: The reset line for v3d, if not using a mapping of the bridge > - See bindings/reset/reset.txt > - > -v3d { > - compatible = "brcm,7268-v3d"; > - reg = <0xf1204000 0x100>, > - <0xf1200000 0x4000>, > - <0xf1208000 0x4000>, > - <0xf1204100 0x100>; > - reg-names = "bridge", "hub", "core0", "gca"; > - interrupts = <0 78 4>, > - <0 77 4>; > -}; > diff --git a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > new file mode 100644 > index 0000000..3b543d4 > --- /dev/null > +++ b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > @@ -0,0 +1,72 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/gpu/brcm,bcm-v3d.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Broadcom V3D GPU Bindings > + > +maintainers: > + - Eric Anholt > + - Nicolas Saenz Julienne > + > +properties: > + $nodename: > + pattern: '^gpu@[a-f0-9]+$' > + > + compatible: > + enum: > + - brcm,7268-v3d > + - brcm,7278-v3d > + > + reg: > + items: > + - description: hub register (required) > + - description: core0 register (required) > + - description: GCA cache controller register (if GCA controller present) > + - description: bridge register (if no external reset controller) > + minItems: 2 > + > + reg-names: > + items: > + enum: [ hub, core0, bridge, gca ] Need to define the order at least for the required ones: items: - const: hub - const: core0 - enum: [ bridge, gca ] - enum: [ bridge, gca ] If you have dts files that are different, then fix them. > + minItems: 2 > + maxItems: 4 > + > + interrupts: > + items: > + - description: hub interrupt (required) > + - description: core interrupts (if it doesn't share the hub's interrupt) > + minItems: 1 > + > + clocks: > + maxItems: 1 > + > + resets: > + maxItems: 1 > + > + power-domains: > + maxItems: 1 > + > +required: > + - compatible > + - reg > + - reg-names > + - interrupts > + > +additionalProperties: false > + > +examples: > + - | > + gpu@f1200000 { > + compatible = "brcm,7268-v3d"; > + reg = <0xf1204000 0x100>, > + <0xf1200000 0x4000>, > + <0xf1208000 0x4000>, > + <0xf1204100 0x100>; > + reg-names = "bridge", "hub", "core0", "gca"; > + interrupts = <0 78 4>, > + <0 77 4>; > + }; > + > +... > -- > 2.7.4 > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-14.0 required=3.0 tests=BAYES_00,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 12502C433DB for ; Wed, 13 Jan 2021 15:38:05 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D29B323383 for ; Wed, 13 Jan 2021 15:38:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726693AbhAMPiE (ORCPT ); Wed, 13 Jan 2021 10:38:04 -0500 Received: from mail-oo1-f43.google.com ([209.85.161.43]:41596 "EHLO mail-oo1-f43.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726523AbhAMPiE (ORCPT ); Wed, 13 Jan 2021 10:38:04 -0500 Received: by mail-oo1-f43.google.com with SMTP id q6so608053ooo.8 for ; Wed, 13 Jan 2021 07:37:48 -0800 (PST) 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; bh=5kG+UaHsX0V2DzmZsJoGVERE52cozjiwmwEVWUmr6BI=; b=DDSK+KWd61Ss/6MoJ7/wRN9dj3z4xxkAv3JwLmKuhZ2y7PyPeDood7o5XVUFbXjnFn 7CYRg8xRWK3407niDFNBOAb2r1CnpNfw9JpoZpE8pHjSLsemhdKyBliV42DvBKQEuImj pafevIMUH65PTr2n55uLK+mZ1XDhdORj9Racw8drbTxWcy/9iD+UV1Qc8UUTdRICaWQX YZNcyEf48n5IFJHwsBdySoEQd+0Q/Ox2wXleMZWWbkEnU1TcG3jXVny3oMUdedxXz2HV aL1VTCpdOGx2k1XgMzPxo+GqW+J6zrt8qI45pQipAdZhMmWIm2BH7lN1G/3e23LtvTRP +i6w== X-Gm-Message-State: AOAM533DoTUAw89EQ1BnTt1NEusPXILTc3jHedC7x3JkUAN4fyj+nx0f SStL4utCjwEQfhJruGDIvA== X-Google-Smtp-Source: ABdhPJz9xwVKMJuGX/FtAZ5bpt3tFVGkkyKSZAa9e6zltw1cl6vr7ZrxhX4LFcwReYcQSRExztNTvQ== X-Received: by 2002:a4a:e8d1:: with SMTP id h17mr1609987ooe.71.1610552242970; Wed, 13 Jan 2021 07:37:22 -0800 (PST) Received: from robh.at.kernel.org (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.gmail.com with ESMTPSA id p132sm439131oia.41.2021.01.13.07.37.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Jan 2021 07:37:22 -0800 (PST) Received: (nullmailer pid 2494140 invoked by uid 1000); Wed, 13 Jan 2021 15:37:21 -0000 Date: Wed, 13 Jan 2021 09:37:21 -0600 From: Rob Herring To: Stefan Wahren Cc: Eric Anholt , Maxime Ripard , David Airlie , Daniel Vetter , Nicolas Saenz Julienne , dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH V3] dt-bindings: gpu: Convert v3d to json-schema Message-ID: <20210113153721.GA2483761@robh.at.kernel.org> References: <1610189433-29985-1-git-send-email-stefan.wahren@i2se.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1610189433-29985-1-git-send-email-stefan.wahren@i2se.com> Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org On Sat, Jan 09, 2021 at 11:50:32AM +0100, Stefan Wahren wrote: > This converts the v3d bindings to yaml format. > > Signed-off-by: Stefan Wahren > --- > > Changes in V3: > - drop redundant maxItems in case we already have items defined > - fix order of reg-names enum > - tag required items in description > - add reg-names to required properties > - drop clock-names > > .../devicetree/bindings/gpu/brcm,bcm-v3d.txt | 33 ---------- > .../devicetree/bindings/gpu/brcm,bcm-v3d.yaml | 72 ++++++++++++++++++++++ > 2 files changed, 72 insertions(+), 33 deletions(-) > delete mode 100644 Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > create mode 100644 Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > > diff --git a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > deleted file mode 100644 > index b2df82b..0000000 > --- a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > +++ /dev/null > @@ -1,33 +0,0 @@ > -Broadcom V3D GPU > - > -Only the Broadcom V3D 3.x and newer GPUs are covered by this binding. > -For V3D 2.x, see brcm,bcm-vc4.txt. > - > -Required properties: > -- compatible: Should be "brcm,7268-v3d" or "brcm,7278-v3d" > -- reg: Physical base addresses and lengths of the register areas > -- reg-names: Names for the register areas. The "hub" and "core0" > - register areas are always required. The "gca" register area > - is required if the GCA cache controller is present. The > - "bridge" register area is required if an external reset > - controller is not present. > -- interrupts: The interrupt numbers. The first interrupt is for the hub, > - while the following interrupts are separate interrupt lines > - for the cores (if they don't share the hub's interrupt). > - See bindings/interrupt-controller/interrupts.txt > - > -Optional properties: > -- clocks: The core clock the unit runs on > -- resets: The reset line for v3d, if not using a mapping of the bridge > - See bindings/reset/reset.txt > - > -v3d { > - compatible = "brcm,7268-v3d"; > - reg = <0xf1204000 0x100>, > - <0xf1200000 0x4000>, > - <0xf1208000 0x4000>, > - <0xf1204100 0x100>; > - reg-names = "bridge", "hub", "core0", "gca"; > - interrupts = <0 78 4>, > - <0 77 4>; > -}; > diff --git a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > new file mode 100644 > index 0000000..3b543d4 > --- /dev/null > +++ b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > @@ -0,0 +1,72 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/gpu/brcm,bcm-v3d.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Broadcom V3D GPU Bindings > + > +maintainers: > + - Eric Anholt > + - Nicolas Saenz Julienne > + > +properties: > + $nodename: > + pattern: '^gpu@[a-f0-9]+$' > + > + compatible: > + enum: > + - brcm,7268-v3d > + - brcm,7278-v3d > + > + reg: > + items: > + - description: hub register (required) > + - description: core0 register (required) > + - description: GCA cache controller register (if GCA controller present) > + - description: bridge register (if no external reset controller) > + minItems: 2 > + > + reg-names: > + items: > + enum: [ hub, core0, bridge, gca ] Need to define the order at least for the required ones: items: - const: hub - const: core0 - enum: [ bridge, gca ] - enum: [ bridge, gca ] If you have dts files that are different, then fix them. > + minItems: 2 > + maxItems: 4 > + > + interrupts: > + items: > + - description: hub interrupt (required) > + - description: core interrupts (if it doesn't share the hub's interrupt) > + minItems: 1 > + > + clocks: > + maxItems: 1 > + > + resets: > + maxItems: 1 > + > + power-domains: > + maxItems: 1 > + > +required: > + - compatible > + - reg > + - reg-names > + - interrupts > + > +additionalProperties: false > + > +examples: > + - | > + gpu@f1200000 { > + compatible = "brcm,7268-v3d"; > + reg = <0xf1204000 0x100>, > + <0xf1200000 0x4000>, > + <0xf1208000 0x4000>, > + <0xf1204100 0x100>; > + reg-names = "bridge", "hub", "core0", "gca"; > + interrupts = <0 78 4>, > + <0 77 4>; > + }; > + > +... > -- > 2.7.4 > From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-14.0 required=3.0 tests=BAYES_00,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 44FC2C433DB for ; Wed, 13 Jan 2021 15:37:26 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id CA7242339F for ; Wed, 13 Jan 2021 15:37:25 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CA7242339F Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 222246EACF; Wed, 13 Jan 2021 15:37:25 +0000 (UTC) Received: from mail-oo1-f46.google.com (mail-oo1-f46.google.com [209.85.161.46]) by gabe.freedesktop.org (Postfix) with ESMTPS id CF6696EACF for ; Wed, 13 Jan 2021 15:37:23 +0000 (UTC) Received: by mail-oo1-f46.google.com with SMTP id s19so618933oos.2 for ; Wed, 13 Jan 2021 07:37:23 -0800 (PST) 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; bh=5kG+UaHsX0V2DzmZsJoGVERE52cozjiwmwEVWUmr6BI=; b=OO8kvgUV4pYuvO95XjVBCegWk4zB0o8f3WNuWE/JdQank/DEMMRITiyMJT+97q6XUM M+1f3i3cFZYLrLI7n+4ItY0er4XVqgHzr6IIP592KzKQgQ+iFnmPTFowh3iNq2ZGDXW0 3oiy45RwuCT594iItAMWEGs8BjMKTpkvrfgTUE6Sn+ULPiom6kXchuVMKyKIkpyaAQ4J M+QaAoJCTAzYLxJzws4PZigc6GDNE+/hGI5GUbw1jYgd5krVxM+WHIgNPKpWaUHaxTMz 3CMmINeClyJaUJjggWTqYaquMtvwKghkuNrzC+DulpceTSCSyDXU314QGGCpy+BOELg3 YPCg== X-Gm-Message-State: AOAM532HsqUvvkKjaSNrsEidEtRGavEaFSP1t8jVI0UyFQgtqCyAoOhg Yv/wdP4h8zuyxETqUbEob69ydoNzdQ== X-Google-Smtp-Source: ABdhPJz9xwVKMJuGX/FtAZ5bpt3tFVGkkyKSZAa9e6zltw1cl6vr7ZrxhX4LFcwReYcQSRExztNTvQ== X-Received: by 2002:a4a:e8d1:: with SMTP id h17mr1609987ooe.71.1610552242970; Wed, 13 Jan 2021 07:37:22 -0800 (PST) Received: from robh.at.kernel.org (24-155-109-49.dyn.grandenetworks.net. [24.155.109.49]) by smtp.gmail.com with ESMTPSA id p132sm439131oia.41.2021.01.13.07.37.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Jan 2021 07:37:22 -0800 (PST) Received: (nullmailer pid 2494140 invoked by uid 1000); Wed, 13 Jan 2021 15:37:21 -0000 Date: Wed, 13 Jan 2021 09:37:21 -0600 From: Rob Herring To: Stefan Wahren Subject: Re: [PATCH V3] dt-bindings: gpu: Convert v3d to json-schema Message-ID: <20210113153721.GA2483761@robh.at.kernel.org> References: <1610189433-29985-1-git-send-email-stefan.wahren@i2se.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1610189433-29985-1-git-send-email-stefan.wahren@i2se.com> X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, David Airlie , dri-devel@lists.freedesktop.org, Nicolas Saenz Julienne Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" On Sat, Jan 09, 2021 at 11:50:32AM +0100, Stefan Wahren wrote: > This converts the v3d bindings to yaml format. > > Signed-off-by: Stefan Wahren > --- > > Changes in V3: > - drop redundant maxItems in case we already have items defined > - fix order of reg-names enum > - tag required items in description > - add reg-names to required properties > - drop clock-names > > .../devicetree/bindings/gpu/brcm,bcm-v3d.txt | 33 ---------- > .../devicetree/bindings/gpu/brcm,bcm-v3d.yaml | 72 ++++++++++++++++++++++ > 2 files changed, 72 insertions(+), 33 deletions(-) > delete mode 100644 Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > create mode 100644 Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > > diff --git a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > deleted file mode 100644 > index b2df82b..0000000 > --- a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.txt > +++ /dev/null > @@ -1,33 +0,0 @@ > -Broadcom V3D GPU > - > -Only the Broadcom V3D 3.x and newer GPUs are covered by this binding. > -For V3D 2.x, see brcm,bcm-vc4.txt. > - > -Required properties: > -- compatible: Should be "brcm,7268-v3d" or "brcm,7278-v3d" > -- reg: Physical base addresses and lengths of the register areas > -- reg-names: Names for the register areas. The "hub" and "core0" > - register areas are always required. The "gca" register area > - is required if the GCA cache controller is present. The > - "bridge" register area is required if an external reset > - controller is not present. > -- interrupts: The interrupt numbers. The first interrupt is for the hub, > - while the following interrupts are separate interrupt lines > - for the cores (if they don't share the hub's interrupt). > - See bindings/interrupt-controller/interrupts.txt > - > -Optional properties: > -- clocks: The core clock the unit runs on > -- resets: The reset line for v3d, if not using a mapping of the bridge > - See bindings/reset/reset.txt > - > -v3d { > - compatible = "brcm,7268-v3d"; > - reg = <0xf1204000 0x100>, > - <0xf1200000 0x4000>, > - <0xf1208000 0x4000>, > - <0xf1204100 0x100>; > - reg-names = "bridge", "hub", "core0", "gca"; > - interrupts = <0 78 4>, > - <0 77 4>; > -}; > diff --git a/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > new file mode 100644 > index 0000000..3b543d4 > --- /dev/null > +++ b/Documentation/devicetree/bindings/gpu/brcm,bcm-v3d.yaml > @@ -0,0 +1,72 @@ > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/gpu/brcm,bcm-v3d.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Broadcom V3D GPU Bindings > + > +maintainers: > + - Eric Anholt > + - Nicolas Saenz Julienne > + > +properties: > + $nodename: > + pattern: '^gpu@[a-f0-9]+$' > + > + compatible: > + enum: > + - brcm,7268-v3d > + - brcm,7278-v3d > + > + reg: > + items: > + - description: hub register (required) > + - description: core0 register (required) > + - description: GCA cache controller register (if GCA controller present) > + - description: bridge register (if no external reset controller) > + minItems: 2 > + > + reg-names: > + items: > + enum: [ hub, core0, bridge, gca ] Need to define the order at least for the required ones: items: - const: hub - const: core0 - enum: [ bridge, gca ] - enum: [ bridge, gca ] If you have dts files that are different, then fix them. > + minItems: 2 > + maxItems: 4 > + > + interrupts: > + items: > + - description: hub interrupt (required) > + - description: core interrupts (if it doesn't share the hub's interrupt) > + minItems: 1 > + > + clocks: > + maxItems: 1 > + > + resets: > + maxItems: 1 > + > + power-domains: > + maxItems: 1 > + > +required: > + - compatible > + - reg > + - reg-names > + - interrupts > + > +additionalProperties: false > + > +examples: > + - | > + gpu@f1200000 { > + compatible = "brcm,7268-v3d"; > + reg = <0xf1204000 0x100>, > + <0xf1200000 0x4000>, > + <0xf1208000 0x4000>, > + <0xf1204100 0x100>; > + reg-names = "bridge", "hub", "core0", "gca"; > + interrupts = <0 78 4>, > + <0 77 4>; > + }; > + > +... > -- > 2.7.4 > _______________________________________________ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel