Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp8674325imu; Thu, 15 Nov 2018 15:43:26 -0800 (PST) X-Google-Smtp-Source: AJdET5faNkbdoWITJXbv2pf/lz0kPpIViVO0NGLinxAbF6hegQKVLPi1L3zKjIssU3U/pNJ4j9It X-Received: by 2002:aa7:868f:: with SMTP id d15mr400330pfo.225.1542325406007; Thu, 15 Nov 2018 15:43:26 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1542325405; cv=none; d=google.com; s=arc-20160816; b=f8eSI6iiWSg6XNYIs4T9B9MWzTmaKg7RyPFlgwBw5tpMEtuT4XEdqpFO+ffKquDk6U MS/BHPtu7E9xeOdUqCwhTiUWk/NDFqb548PHejS1gisNOz/Jk5EVVTj6dlVf0ucGd6Op Cfo9qD561lWZ5q0bH6/Q10vcIXdoeFWb54QYCbuMN2XuRIq8H86yfa60Pf1rLzBDlu1C ow15jCU6zac80XPn+Cf92RRefAkGGqGj1FPBLWrVgJ38gnErgN42F3heWWpUrAdsItju modmx40MC3tNvZwZWejif2pm6hrZOX3iO0dmxya0Q/FkP0KKpj1A8gHhgUs8JtHpKMqL aqCA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=DJdl/aQE4Bb/td9fW8l9il6SHzBdgc524KJz+5OfLjQ=; b=sJNegtXSK/m7932N8LHW/kD3FXN2iNSgTVYSTicxRZcP+z8P6+R5IfsMTh+pPl7vUD 9vPGF688gDoiY3Nwb//MBaCNsQy+gg6aKRMbWPfkhR4zqJo0vrrEUfOEVvoi71wMB9P0 Y3UCJuMX3J45LCW/K7EWq6XwJN9Acv6GuVfuDV5H/TZ4gaFpjm2qqhdqTW3qOVN7494B 8+dWMPm9MOdUiyZ5HUVHB9juz2K5n6dGmRS0SFSf51fMIiT7QmdsWLST2XnL2Rppezj0 z701V3c+cShrTKRp0pnS8i6MWZGbeWL+LaVHWRDGg/af219jhh2w+cf/hjsU0DkE7xCs BenQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=C4fFja1L; 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=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 y40-v6si29923835pla.391.2018.11.15.15.43.11; Thu, 15 Nov 2018 15:43:25 -0800 (PST) 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=@kernel.org header.s=default header.b=C4fFja1L; 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=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388265AbeKPJw0 (ORCPT + 99 others); Fri, 16 Nov 2018 04:52:26 -0500 Received: from mail.kernel.org ([198.145.29.99]:42918 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726352AbeKPJw0 (ORCPT ); Fri, 16 Nov 2018 04:52:26 -0500 Received: from mail-qk1-f170.google.com (mail-qk1-f170.google.com [209.85.222.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B20D821582; Thu, 15 Nov 2018 23:42:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1542325346; bh=DJdl/aQE4Bb/td9fW8l9il6SHzBdgc524KJz+5OfLjQ=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=C4fFja1LhkSSRe1Gu3IaVRk15/5kmfYaeTTJcV9qYRxr+Px/Ouslgku4EpTM3tZaS umE0/JcWtOrxAyFrMRG8KNqKv987y4nZGzghv7uCrZnpcayp7h0M9+u4bur8TK3KFd m73/27VD9VhNsCiDpf4gn7IJr5t3ZYtVvWpJJZ+k= Received: by mail-qk1-f170.google.com with SMTP id q1so34701451qkf.13; Thu, 15 Nov 2018 15:42:26 -0800 (PST) X-Gm-Message-State: AGRZ1gJ5JFstD9Vn22lg39duLm7NnvEq2jKdt5dshYBTXWxj0R5KvA2P YEO9a5t6MPO2qFsgs0AKjbsm/7Xt65HVZOd3HQ== X-Received: by 2002:aed:29a5:: with SMTP id o34mr7794386qtd.257.1542325345848; Thu, 15 Nov 2018 15:42:25 -0800 (PST) MIME-Version: 1.0 References: <20180418222905.10414-1-robh@kernel.org> In-Reply-To: From: Rob Herring Date: Thu, 15 Nov 2018 17:42:14 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [RFC PATCH] dt-bindings: add a jsonschema binding example To: jonsmirl@gmail.com Cc: Frank Rowand , devicetree@vger.kernel.org, devicetree-spec@vger.kernel.org, "linux-kernel@vger.kernel.org" , Grant Likely , Mark Rutland , Geert Uytterhoeven , Linus Walleij , Thierry Reding , Mark Brown , Shawn Guo , Bjorn Andersson , Arnd Bergmann , Stephen Boyd , Jonathan Cameron Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 14, 2018 at 1:39 PM jonsmirl@gmail.com wrote: > > On Fri, Apr 20, 2018 at 9:36 PM Rob Herring wrote: > > I share the concern as I doubt most kernel developers don't know > > jsonschema. But then the alternative is us defining and writing our > > own thing which is C like 'cause that's what kernel developers > > understand. My hope is to simplify and restrict things enough that it > > writing a binding doc is straightforward without being jsonschema > > experts. That was the intent of this patch without going into all the > > details behind it. > > When schemas were first discussed long, long ago the idea was to have > a n arbitrator who controls the schema (like Grant/Rob) so there is no > need for general schema design knowledge in random kernel developers. > > First a developer should try and build their device tree using the > existing schema. Then only if they find that impossible to do so > should they propose schema changes. The schema arbitrator would then > look at those changes and work them into the existing schemas as > needed. Doing this via an arbitrator will ensure consistency in the > overall schema design while eliminating redundancy with slight > variations (like we have now). > > Another side effect of schemas is that as they evolve and enforce > commonality among driver implementation it will become possible to > turn those in-common pieces into driver libraries. If we replace 'schemas' everywhere above with 'bindings', then this pretty much describes the status quo today. Most device specific bindings are a collection of standard bindings. Occasionally, we have new common bindings. All the bindings get reviewed by me. The only real change here is submitters have to have some level of understanding of json-schema instead of just English (for writing free form text). I think it will continue to largely be following existing examples of other bindings. Rob