Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp166615ybz; Tue, 21 Apr 2020 06:51:04 -0700 (PDT) X-Google-Smtp-Source: APiQypL/V/n5gW8zTKld8/CFkX6SN2NNp9LQHcO4G13wqPZ/I4PJqssTi6yH6bSw4eWmUUGaEZUV X-Received: by 2002:a05:6402:8c1:: with SMTP id d1mr13394637edz.236.1587477064475; Tue, 21 Apr 2020 06:51:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587477064; cv=none; d=google.com; s=arc-20160816; b=yAfWwfyo7Bj6nMaT7TNhyI4ZwJa8X85AAYowkPKLnJs5BMps5K3lHGjhF9DZSUgPuh nI7+h7XqbZ5uLDDIolwBc71A78ZxK8EmafSrduQfjyF5jeDg3Y+/9vAvO20mLY3rkbE5 khlDzof75oNnV/VZlJZkseoix8/s/WfwsFr0PCWNfQY8wGYjWF/0pLazKnnYWyWhMM+Z 4jdJMzxUhqRN+Qxl+Hy6OVQdUmOLYyHXdV/55IocuFg8FdxJtjUh3v7JflmXKw4hzcSL creuceY06mBtf5pKOL9cGWxhxUmMaEjuSVh3b6uRDQ2cdmrKv1xzxfJFjomt7ddk78qK kGgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=nHsFGBXTZxOOAWfWq9UpnSF8z5ix0upOxVEOOA8HefE=; b=yCZmPs/EU79eTWSjaLspZczg2FAJVB1Eh9an3hK+R9BbRrxr7kkoxGKmVdsBOIm+IL RFtFEFjgp0N4uMKNXUD5bBbO+rJI11XNEBmt+VA6hEW7X0dcy55Qrgjc729Sd3RsKR6o quHqZmhO1rbxjlsrtBCSBEW7IytHhTtb2qWi/ciydpqPhw6BHDTyhHcIgZLlfGdg8P4h F1R/aSgoAY3ENLAcYrr2NBDIYYGcltLTeEXzrE6fnXsC9c10ZrF+LnLEj12b03gQcH8Z vIqXQgLlXaKZBOBhzJ116B1He0SS6ljkNxCcmZ7xg+gXn5F5vkIYU6wHLzpvwYswYSLm kv/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=Aj5pQid4; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r15si1627764ejr.33.2020.04.21.06.50.39; Tue, 21 Apr 2020 06:51:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=Aj5pQid4; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728994AbgDUNrK (ORCPT + 99 others); Tue, 21 Apr 2020 09:47:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42092 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1728479AbgDUNrJ (ORCPT ); Tue, 21 Apr 2020 09:47:09 -0400 Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BC1CEC061A10; Tue, 21 Apr 2020 06:47:09 -0700 (PDT) Received: from pendragon.ideasonboard.com (81-175-216-236.bb.dnainternet.fi [81.175.216.236]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 81BB2528; Tue, 21 Apr 2020 15:47:07 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1587476827; bh=etmf9PYF8EvQ0KcScRiA46EXmW/61wAdo5/3jftZZH4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Aj5pQid4RjTwp4IsZVTXPL7pQGtTHv84JajtYI4NhCjyEyQnOk7WRljQWz8gQZPJH qqxStFM/e59/tkUUFb6slNEWx9mBQzEqIMzbAV4ylIiiSIjkBHnTumiobQmCWp07HS sFbOMLUjIeG7AGY8RBUwskz6F25u2NKwM3hnvHx0= Date: Tue, 21 Apr 2020 16:46:54 +0300 From: Laurent Pinchart To: Masahiro Yamada Cc: Rob Herring , DTML , Linux Kernel Mailing List , Michal Marek , Linux Kbuild mailing list Subject: Re: [PATCH v2 1/2] kbuild: Always validate DT binding examples Message-ID: <20200421134654.GD5983@pendragon.ideasonboard.com> References: <20200229003731.2728-1-robh@kernel.org> <20200421100749.GA5429@pendragon.ideasonboard.com> <20200421110537.GC5983@pendragon.ideasonboard.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Yamada-san, On Tue, Apr 21, 2020 at 10:15:02PM +0900, Masahiro Yamada wrote: > On Tue, Apr 21, 2020 at 8:05 PM Laurent Pinchart wrote: > > On Tue, Apr 21, 2020 at 07:45:05PM +0900, Masahiro Yamada wrote: > > > On Tue, Apr 21, 2020 at 7:08 PM Laurent Pinchart wrote: > > > > On Fri, Feb 28, 2020 at 06:37:30PM -0600, Rob Herring wrote: > > > > > Most folks only run dt_binding_check on the single schema they care about > > > > > by setting DT_SCHEMA_FILES. That means example is only checked against > > > > > that one schema which is not always sufficient. > > > > > > > > > > Let's address this by splitting processed-schema.yaml into 2 files: one > > > > > that's always all schemas for the examples and one that's just the schema > > > > > in DT_SCHEMA_FILES for dtbs. > > > > > > > > This broke > > > > > > > > make DT_SCHEMA_FILES=Documentation/devicetree/.. dt_binding_check > > > > > > What is intended by > > > "DT_SCHEMA_FILES=Documentation/devicetree/.." ? > > > > My bad, I forgot to write that ... is the continuation of the string. > > It's any yaml schema file that has an example. > > Ah, OK. I just input verbatim. > > Is it broken? > > You can specify any individual file(s) under Documentation/devicetree/bindings/. > > For example, the following worked for me. > > $ make DT_SCHEMA_FILES=Documentation/devicetree/bindings/arm/psci.yaml > dt_binding_check > HOSTCC scripts/basic/fixdep > HOSTCC scripts/dtc/dtc.o > HOSTCC scripts/dtc/flattree.o > HOSTCC scripts/dtc/fstree.o > HOSTCC scripts/dtc/data.o > HOSTCC scripts/dtc/livetree.o > HOSTCC scripts/dtc/treesource.o > HOSTCC scripts/dtc/srcpos.o > HOSTCC scripts/dtc/checks.o > HOSTCC scripts/dtc/util.o > LEX scripts/dtc/dtc-lexer.lex.c > YACC scripts/dtc/dtc-parser.tab.[ch] > HOSTCC scripts/dtc/dtc-lexer.lex.o > HOSTCC scripts/dtc/dtc-parser.tab.o > HOSTCC scripts/dtc/yamltree.o > HOSTLD scripts/dtc/dtc > CHKDT Documentation/devicetree/bindings/arm/psci.yaml > SCHEMA Documentation/devicetree/bindings/processed-schema-examples.yaml > DTC Documentation/devicetree/bindings/arm/psci.example.dt.yaml > CHECK Documentation/devicetree/bindings/arm/psci.example.dt.yaml > SCHEMA Documentation/devicetree/bindings/processed-schema.yaml This is getting interesting. ~/src/kernel/linux $ make O=output/x86 DT_SCHEMA_FILES=Documentation/devicetree/bindings/arm/psci.yaml dt_binding_check make[1]: Entering directory '/home/laurent/src/kernel/linux/output/x86' HOSTCC scripts/basic/fixdep HOSTCC scripts/dtc/dtc.o HOSTCC scripts/dtc/flattree.o HOSTCC scripts/dtc/fstree.o HOSTCC scripts/dtc/data.o HOSTCC scripts/dtc/livetree.o HOSTCC scripts/dtc/treesource.o HOSTCC scripts/dtc/srcpos.o HOSTCC scripts/dtc/checks.o HOSTCC scripts/dtc/util.o LEX scripts/dtc/dtc-lexer.lex.c YACC scripts/dtc/dtc-parser.tab.[ch] HOSTCC scripts/dtc/dtc-lexer.lex.o HOSTCC scripts/dtc/dtc-parser.tab.o HOSTCC scripts/dtc/yamltree.o HOSTLD scripts/dtc/dtc CHKDT Documentation/devicetree/bindings/arm/psci.yaml SCHEMA Documentation/devicetree/bindings/processed-schema-examples.yaml DTC Documentation/devicetree/bindings/arm/psci.example.dt.yaml CHECK Documentation/devicetree/bindings/arm/psci.example.dt.yaml SCHEMA Documentation/devicetree/bindings/processed-schema.yaml make[1]: Leaving directory '/home/laurent/src/kernel/linux/output/x86' ~/src/kernel/this_is_a_long_directory_name/linux $ make O=output/x86 DT_SCHEMA_FILES=Documentation/devicetree/bindings/arm/psci.yaml dt_binding_check make[1]: Entering directory '/home/laurent/src/kernel/this_is_a_long_directory_name/linux/output/x86' HOSTCC scripts/basic/fixdep HOSTCC scripts/dtc/dtc.o HOSTCC scripts/dtc/flattree.o HOSTCC scripts/dtc/fstree.o HOSTCC scripts/dtc/data.o HOSTCC scripts/dtc/livetree.o HOSTCC scripts/dtc/treesource.o HOSTCC scripts/dtc/srcpos.o HOSTCC scripts/dtc/checks.o HOSTCC scripts/dtc/util.o LEX scripts/dtc/dtc-lexer.lex.c YACC scripts/dtc/dtc-parser.tab.[ch] HOSTCC scripts/dtc/dtc-lexer.lex.o HOSTCC scripts/dtc/dtc-parser.tab.o HOSTCC scripts/dtc/yamltree.o HOSTLD scripts/dtc/dtc CHKDT Documentation/devicetree/bindings/arm/psci.yaml make[2]: execvp: /bin/sh: Argument list too long make[2]: *** [/home/laurent/src/kernel/this_is_a_long_directory_name/linux/Documentation/devicetree/bindings/Makefile:38: Documentation/devicetree/bindings/processed-schema-examples.yaml] Error 127 make[1]: *** [/home/laurent/src/kernel/this_is_a_long_directory_name/linux/Makefile:1300: dt_binding_check] Error 2 make[1]: Leaving directory '/home/laurent/src/kernel/this_is_a_long_directory_name/linux/output/x86' make: *** [Makefile:180: sub-make] Error 2 It seems to only fail with out of tree builds (O=...). I expect that failures will become more common the more YAML bindings we have, even without long directory names. -- Regards, Laurent Pinchart