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=-21.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING,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 6CD90C433DB for ; Fri, 22 Jan 2021 14:47:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 3A4DF239D1 for ; Fri, 22 Jan 2021 14:47:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728565AbhAVOna (ORCPT ); Fri, 22 Jan 2021 09:43:30 -0500 Received: from mail.kernel.org ([198.145.29.99]:39038 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728734AbhAVOlx (ORCPT ); Fri, 22 Jan 2021 09:41:53 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 852E0239EF for ; Fri, 22 Jan 2021 14:41:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1611326472; bh=gNNp57NP+5LbxVkjx/67W4zGV/me4qc6JzJVBRGZhUk=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=RuQCoSHfgj8wE7hapwzVFPr1BRYZtWnyX/zhdj3YkRjdV3/JPtfYyu4fhw0i1IjVi Up0p4SXe+cYrW55ETFWR5nN39GhKwMykFNRKk9REIxarkr4ZBx3V75wVRhwQ37O5XR 4Vg1dZ1jBH+5r793YxIT7PjbQQoxKgqnxgpe3vuCC7ikJ2IEtnrHLsHQuYkKE3nEsx v8WWlgB7iUf0U07JPm6NKG2EbKlvn5Iiw/hZbTIimpMierROajnExxGuDdk3tt86DQ C32j5zyX+UXqMZmr5UjLVMUuHJtyKSRuR36Sry3txR00qEBCrUTI7ZkTlgq/VSYSo1 JQVcl0Vk3TPDA== Received: by mail-ej1-f51.google.com with SMTP id w1so7935292ejf.11 for ; Fri, 22 Jan 2021 06:41:12 -0800 (PST) X-Gm-Message-State: AOAM530ScC33E4lQ8lh50P057JIJMk45j6RwVZL+Gz6J8kigEC9L19We 0unAMDVCyKsfekVudiJZKbDjyqcoSvg8oM79cA== X-Google-Smtp-Source: ABdhPJx2SH2VlFwlCNHLKsID1okcEyJPQwFmwQUkf5qp+AQB0ba9djnCbIzzSga3NPrQpNL8W9QFNJ5Ki+oNXS2iVEw= X-Received: by 2002:a17:906:c9d8:: with SMTP id hk24mr3299782ejb.468.1611326471140; Fri, 22 Jan 2021 06:41:11 -0800 (PST) MIME-Version: 1.0 References: <20210114113538.1233933-1-maxime@cerno.tech> <20210114113538.1233933-5-maxime@cerno.tech> <20210115013714.GA3798333@robh.at.kernel.org> <20210118101501.mmlgsiyj5rulrpgk@gilmour> In-Reply-To: <20210118101501.mmlgsiyj5rulrpgk@gilmour> From: Rob Herring Date: Fri, 22 Jan 2021 08:40:59 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 05/19] dt-bindings: bluetooth: realtek: Switch to unevaluatedProperties To: Maxime Ripard Cc: Frank Rowand , devicetree@vger.kernel.org, Chen-Yu Tsai , Jernej Skrabec , linux-arm-kernel , Alistair Francis , Vasily Khoruzhick Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org On Mon, Jan 18, 2021 at 4:15 AM Maxime Ripard wrote: > > Hi Rob, > > On Thu, Jan 14, 2021 at 07:37:14PM -0600, Rob Herring wrote: > > On Thu, Jan 14, 2021 at 12:35:24PM +0100, Maxime Ripard wrote: > > > additionalProperties prevent any property not explicitly defined in the > > > binding to be used. Yet, some serial properties like max-speed are valid > > > and validated through the serial/serial.yaml binding. > > > > > > Let's change additionalProperties to unevaluatedProperties to avoid > > > spurious warnings. > > > > > > Cc: Alistair Francis > > > Cc: Vasily Khoruzhick > > > Signed-off-by: Maxime Ripard > > > --- > > > Documentation/devicetree/bindings/net/realtek-bluetooth.yaml | 2 +- > > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > > > diff --git a/Documentation/devicetree/bindings/net/realtek-bluetooth.yaml b/Documentation/devicetree/bindings/net/realtek-bluetooth.yaml > > > index 4f485df69ac3..f4d4969d87f4 100644 > > > --- a/Documentation/devicetree/bindings/net/realtek-bluetooth.yaml > > > +++ b/Documentation/devicetree/bindings/net/realtek-bluetooth.yaml > > > @@ -37,7 +37,7 @@ properties: > > > required: > > > - compatible > > > > > > -additionalProperties: false > > > +unevaluatedProperties: false > > > > This would still fail because the serial schema is applied to the parent > > and this schema is applied to the child node. It's a common problem for > > how we've done bus schemas. We'd need to split them into 2 schemas and > > reference the child schema here. I'd rather not do that here because > > then we'd apply the schema twice assuming we keep bus schemas also > > applying the child schemas (which is good at least until we have schemas > > for *all* possible child devices). > > I couldn't find what requires additionalProperties in the meta-schemas, > could you point me to what enforces it? https://github.com/devicetree-org/dt-schema/commit/14db51af82b0ab52f4a69f9aaa86726087b3022a Rob 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=-19.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI, MENTIONS_GIT_HOSTING,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 632BDC433DB for ; Fri, 22 Jan 2021 14:42:38 +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 1A8C5239D1 for ; Fri, 22 Jan 2021 14:42:38 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 1A8C5239D1 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:To:Subject:Message-ID:Date:From:In-Reply-To: References:MIME-Version:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=2d05/Gg1d4uLqg+Z45kR1DE7LUDQBZX2ekrDE3JNg6I=; b=sD9ZfGzA0raT95uBeUpnARTCC srQdYhgasnJACps07pZJbkjfiVUG/20pGBGxSyJkV1k+dgIB8EMwXYjIWXUvzEjf+fUo6n17PjTAp BZhepQ4Y4S7ohyVrGVONX7xfyKC64fle7bJi/EKyRmZ7T5iEyVCTZrZ37G0SgQxhROaY3RiDZCPQo nRrcD/8x+WStosfPqKFeV+Ld9wUqzt4S9zbCchs28yx1fs84bMI0KE1UrmgPcGJs9BRn6RlY2Ljkf qJJCBiTT4IBqW+CA2O78uvJQpuslwGp19RO/U7SWHY0uSZgCUfR3/Y7tQXEZBjR2ZEHR+5Ok56sj3 14HuTw8tg==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1l2xci-0000Z9-Lv; Fri, 22 Jan 2021 14:41:16 +0000 Received: from mail.kernel.org ([198.145.29.99]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1l2xcf-0000Yd-Ki for linux-arm-kernel@lists.infradead.org; Fri, 22 Jan 2021 14:41:14 +0000 Received: by mail.kernel.org (Postfix) with ESMTPSA id 89FC223A53 for ; Fri, 22 Jan 2021 14:41:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1611326472; bh=gNNp57NP+5LbxVkjx/67W4zGV/me4qc6JzJVBRGZhUk=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=RuQCoSHfgj8wE7hapwzVFPr1BRYZtWnyX/zhdj3YkRjdV3/JPtfYyu4fhw0i1IjVi Up0p4SXe+cYrW55ETFWR5nN39GhKwMykFNRKk9REIxarkr4ZBx3V75wVRhwQ37O5XR 4Vg1dZ1jBH+5r793YxIT7PjbQQoxKgqnxgpe3vuCC7ikJ2IEtnrHLsHQuYkKE3nEsx v8WWlgB7iUf0U07JPm6NKG2EbKlvn5Iiw/hZbTIimpMierROajnExxGuDdk3tt86DQ C32j5zyX+UXqMZmr5UjLVMUuHJtyKSRuR36Sry3txR00qEBCrUTI7ZkTlgq/VSYSo1 JQVcl0Vk3TPDA== Received: by mail-ej1-f43.google.com with SMTP id ke15so7938576ejc.12 for ; Fri, 22 Jan 2021 06:41:12 -0800 (PST) X-Gm-Message-State: AOAM532LHUdYbvbISqAnpdi4m0kF+ix2L7HicxRY8x1ChXhPknBn8mX1 h7tUYkHJ9nXpARtX2VQsXIxcBmQA2MQyd/k10A== X-Google-Smtp-Source: ABdhPJx2SH2VlFwlCNHLKsID1okcEyJPQwFmwQUkf5qp+AQB0ba9djnCbIzzSga3NPrQpNL8W9QFNJ5Ki+oNXS2iVEw= X-Received: by 2002:a17:906:c9d8:: with SMTP id hk24mr3299782ejb.468.1611326471140; Fri, 22 Jan 2021 06:41:11 -0800 (PST) MIME-Version: 1.0 References: <20210114113538.1233933-1-maxime@cerno.tech> <20210114113538.1233933-5-maxime@cerno.tech> <20210115013714.GA3798333@robh.at.kernel.org> <20210118101501.mmlgsiyj5rulrpgk@gilmour> In-Reply-To: <20210118101501.mmlgsiyj5rulrpgk@gilmour> From: Rob Herring Date: Fri, 22 Jan 2021 08:40:59 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 05/19] dt-bindings: bluetooth: realtek: Switch to unevaluatedProperties To: Maxime Ripard X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210122_094113_792649_3619E9C6 X-CRM114-Status: GOOD ( 24.61 ) 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: devicetree@vger.kernel.org, Jernej Skrabec , Alistair Francis , Vasily Khoruzhick , Chen-Yu Tsai , Frank Rowand , linux-arm-kernel 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 Mon, Jan 18, 2021 at 4:15 AM Maxime Ripard wrote: > > Hi Rob, > > On Thu, Jan 14, 2021 at 07:37:14PM -0600, Rob Herring wrote: > > On Thu, Jan 14, 2021 at 12:35:24PM +0100, Maxime Ripard wrote: > > > additionalProperties prevent any property not explicitly defined in the > > > binding to be used. Yet, some serial properties like max-speed are valid > > > and validated through the serial/serial.yaml binding. > > > > > > Let's change additionalProperties to unevaluatedProperties to avoid > > > spurious warnings. > > > > > > Cc: Alistair Francis > > > Cc: Vasily Khoruzhick > > > Signed-off-by: Maxime Ripard > > > --- > > > Documentation/devicetree/bindings/net/realtek-bluetooth.yaml | 2 +- > > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > > > diff --git a/Documentation/devicetree/bindings/net/realtek-bluetooth.yaml b/Documentation/devicetree/bindings/net/realtek-bluetooth.yaml > > > index 4f485df69ac3..f4d4969d87f4 100644 > > > --- a/Documentation/devicetree/bindings/net/realtek-bluetooth.yaml > > > +++ b/Documentation/devicetree/bindings/net/realtek-bluetooth.yaml > > > @@ -37,7 +37,7 @@ properties: > > > required: > > > - compatible > > > > > > -additionalProperties: false > > > +unevaluatedProperties: false > > > > This would still fail because the serial schema is applied to the parent > > and this schema is applied to the child node. It's a common problem for > > how we've done bus schemas. We'd need to split them into 2 schemas and > > reference the child schema here. I'd rather not do that here because > > then we'd apply the schema twice assuming we keep bus schemas also > > applying the child schemas (which is good at least until we have schemas > > for *all* possible child devices). > > I couldn't find what requires additionalProperties in the meta-schemas, > could you point me to what enforces it? https://github.com/devicetree-org/dt-schema/commit/14db51af82b0ab52f4a69f9aaa86726087b3022a Rob _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel