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=-15.3 required=3.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 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 9485CC433B4 for ; Thu, 8 Apr 2021 12:28:17 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 74E3A610FB for ; Thu, 8 Apr 2021 12:28:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231132AbhDHM21 (ORCPT ); Thu, 8 Apr 2021 08:28:27 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:16842 "EHLO szxga07-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229741AbhDHM2Z (ORCPT ); Thu, 8 Apr 2021 08:28:25 -0400 Received: from DGGEMS410-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga07-in.huawei.com (SkyGuard) with ESMTP id 4FGL8S4DC9z7tyl; Thu, 8 Apr 2021 20:26:00 +0800 (CST) Received: from [127.0.0.1] (10.174.179.202) by DGGEMS410-HUB.china.huawei.com (10.3.19.210) with Microsoft SMTP Server id 14.3.498.0; Thu, 8 Apr 2021 20:28:09 +0800 Subject: Re: [PATCH v2 2/2] ASoC: dt-bindings: renesas, rsnd: Clear warning 'ports' does not match any of the regexes From: "Leizhen (ThunderTown)" To: Rob Herring CC: Liam Girdwood , Mark Brown , alsa-devel , devicetree , linux-kernel , Kuninori Morimoto References: <20210331091616.2306-1-thunder.leizhen@huawei.com> <20210331091616.2306-3-thunder.leizhen@huawei.com> <20210401202056.GA947212@robh.at.kernel.org> Message-ID: <15a406ba-b288-c98c-46f1-36933c11fb11@huawei.com> Date: Thu, 8 Apr 2021 20:28:08 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.179.202] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2021/4/7 10:04, Leizhen (ThunderTown) wrote: > > > On 2021/4/2 4:20, Rob Herring wrote: >> On Wed, Mar 31, 2021 at 05:16:16PM +0800, Zhen Lei wrote: >>> Currently, if there are more than two ports, or if there is only one port >>> but other properties(such as "#address-cells") is required, these ports >>> are placed under the "ports" node. So add the schema of property "ports". >> >> A given binding should just use 'ports' or 'port' depending on it's >> need. Supporting both forms is needless complexity. Hi Rob: I don't think of a good way to avoid "port" and "ports" to be used at the same time. Should I disable the use of "port"? Convert the two usages of "port" into "ports". But usually no one will use both of them in one dts file. And even if it's used at the same time, it's not a big mistake. So I decided not to test it. > > Right, I'll adjust this patch again. > >> >>> Otherwise, warnings similar to the following will be reported: >>> arch/arm64/boot/dts/renesas/r8a774a1-beacon-rzg2m-kit.dt.yaml: \ >>> sound@ec500000: 'ports' does not match any of the regexes: \ >>> '^rcar_sound,ctu$', '^rcar_sound,dai$', '^rcar_sound,dvc$', ... >>> >>> Signed-off-by: Zhen Lei >>> --- >>> Documentation/devicetree/bindings/sound/renesas,rsnd.yaml | 5 +++++ >>> 1 file changed, 5 insertions(+) >>> >>> diff --git a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml >>> index 384191ee497f534..a42992fa687d3f3 100644 >>> --- a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml >>> +++ b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml >>> @@ -115,6 +115,11 @@ properties: >>> $ref: audio-graph-port.yaml# >>> unevaluatedProperties: false >>> >>> + ports: >> >> $ref: /schemas/graph.yaml#/properties/ports > > OK, thanks > >> >>> + patternProperties: >>> + '^port@[0-9]': >>> + $ref: "#/properties/port" >> >> Then this should be: $ref: audio-graph-port.yaml# > > OK, thanks > >> >> Also, what each port is should be defined, but that's a separate >> problem. >> >>> + >>> # use patternProperties to avoid naming "xxx,yyy" issue >>> patternProperties: >>> "^rcar_sound,dvc$": >>> -- >>> 1.8.3 >>> >>> >> >> . >> 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=-15.3 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 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 295D9C433B4 for ; Thu, 8 Apr 2021 12:29:41 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (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 874E761106 for ; Thu, 8 Apr 2021 12:29:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 874E761106 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=huawei.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 1BAEF15F9; Thu, 8 Apr 2021 14:28:47 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 1BAEF15F9 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1617884977; bh=I2Pu6767lUQHrWaA8yQGY9b14KgvUkSN1iUXerPoMHo=; h=Subject:From:To:References:Date:In-Reply-To:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=QrUE02rwU7M9mYEqwwZlVdrIBHTuV3maYVWxzRkmO3JzIxA5meng+c6qUbr71R1nV Xu/6CKHZBK62idNPyJUFZ+UBkL4nNY3N3psNpJ6PDqU4NcWXq1+Z++rP7IdotIMAfK EVZmEOUPS9+KghrUKTa2j8pcKmIFtd5u3HvwkHcQ= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 4E24BF80169; Thu, 8 Apr 2021 14:28:46 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 585C1F8020B; Thu, 8 Apr 2021 14:28:30 +0200 (CEST) Received: from szxga07-in.huawei.com (szxga07-in.huawei.com [45.249.212.35]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id A7320F800BD for ; Thu, 8 Apr 2021 14:28:19 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz A7320F800BD Received: from DGGEMS410-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga07-in.huawei.com (SkyGuard) with ESMTP id 4FGL8S4DC9z7tyl; Thu, 8 Apr 2021 20:26:00 +0800 (CST) Received: from [127.0.0.1] (10.174.179.202) by DGGEMS410-HUB.china.huawei.com (10.3.19.210) with Microsoft SMTP Server id 14.3.498.0; Thu, 8 Apr 2021 20:28:09 +0800 Subject: Re: [PATCH v2 2/2] ASoC: dt-bindings: renesas, rsnd: Clear warning 'ports' does not match any of the regexes From: "Leizhen (ThunderTown)" To: Rob Herring References: <20210331091616.2306-1-thunder.leizhen@huawei.com> <20210331091616.2306-3-thunder.leizhen@huawei.com> <20210401202056.GA947212@robh.at.kernel.org> Message-ID: <15a406ba-b288-c98c-46f1-36933c11fb11@huawei.com> Date: Thu, 8 Apr 2021 20:28:08 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.174.179.202] X-CFilter-Loop: Reflected Cc: devicetree , alsa-devel , Kuninori Morimoto , Liam Girdwood , linux-kernel , Mark Brown X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" On 2021/4/7 10:04, Leizhen (ThunderTown) wrote: > > > On 2021/4/2 4:20, Rob Herring wrote: >> On Wed, Mar 31, 2021 at 05:16:16PM +0800, Zhen Lei wrote: >>> Currently, if there are more than two ports, or if there is only one port >>> but other properties(such as "#address-cells") is required, these ports >>> are placed under the "ports" node. So add the schema of property "ports". >> >> A given binding should just use 'ports' or 'port' depending on it's >> need. Supporting both forms is needless complexity. Hi Rob: I don't think of a good way to avoid "port" and "ports" to be used at the same time. Should I disable the use of "port"? Convert the two usages of "port" into "ports". But usually no one will use both of them in one dts file. And even if it's used at the same time, it's not a big mistake. So I decided not to test it. > > Right, I'll adjust this patch again. > >> >>> Otherwise, warnings similar to the following will be reported: >>> arch/arm64/boot/dts/renesas/r8a774a1-beacon-rzg2m-kit.dt.yaml: \ >>> sound@ec500000: 'ports' does not match any of the regexes: \ >>> '^rcar_sound,ctu$', '^rcar_sound,dai$', '^rcar_sound,dvc$', ... >>> >>> Signed-off-by: Zhen Lei >>> --- >>> Documentation/devicetree/bindings/sound/renesas,rsnd.yaml | 5 +++++ >>> 1 file changed, 5 insertions(+) >>> >>> diff --git a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml >>> index 384191ee497f534..a42992fa687d3f3 100644 >>> --- a/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml >>> +++ b/Documentation/devicetree/bindings/sound/renesas,rsnd.yaml >>> @@ -115,6 +115,11 @@ properties: >>> $ref: audio-graph-port.yaml# >>> unevaluatedProperties: false >>> >>> + ports: >> >> $ref: /schemas/graph.yaml#/properties/ports > > OK, thanks > >> >>> + patternProperties: >>> + '^port@[0-9]': >>> + $ref: "#/properties/port" >> >> Then this should be: $ref: audio-graph-port.yaml# > > OK, thanks > >> >> Also, what each port is should be defined, but that's a separate >> problem. >> >>> + >>> # use patternProperties to avoid naming "xxx,yyy" issue >>> patternProperties: >>> "^rcar_sound,dvc$": >>> -- >>> 1.8.3 >>> >>> >> >> . >>