[net-next,4/8] dt-bindings: net: ethernet-switch: Add missing 'ethernet-ports' level
Message ID | 20231016-dt-net-cleanups-v1-4-a525a090b444@kernel.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:612c:2908:b0:403:3b70:6f57 with SMTP id ib8csp3740727vqb; Mon, 16 Oct 2023 14:45:52 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEC3YYKltzPGmBGr6B8taptGdObSdliTD7gBF5uW8MciUohduMuSPe1rSCStxaZ6kmzVgNI X-Received: by 2002:a05:6a20:9741:b0:163:ab09:196d with SMTP id hs1-20020a056a20974100b00163ab09196dmr304029pzc.1.1697492751693; Mon, 16 Oct 2023 14:45:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697492751; cv=none; d=google.com; s=arc-20160816; b=HUjhNRQ4rlq+0u90vJgn12a9uN0mDpDimGCdWQ4/+mduWm9jlx/VYEgOFNjwKMgXlg BjrnTz6feHqqne8G6SKgtox8CSCIax3Lv+0xt1XIJbGiaOsKT4nNNEZx+/B8ILfUGJ20 py6lHBZzCTA7Wi7OsQj7MtKozNkuzCo1t4xToWJREO0TlVXiOkfMkoS5SdUa5dzGfP73 OtcMdjLpDNbkgIOc8NZGN4C3QrTC0r+1QRcP9lrdcgYWgcZwsWNMEk1aRazTo09QcDLg K6/Ai9CVHiyXZcA/azifJQOVIQqw0sRX7UhF0LBpmBkMvsnBiCf53H+uJx9DUuBndXS4 CNkw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from; bh=gmfkMrLhqQX7VpvIedVUrmMesFIoJFx2r4z/RkhPLxM=; fh=W75KIt5z29NZQuSJpsWFLRgwoWVSDt7JDSz2XKjQ91Y=; b=Pb9lLiV/3wb8iB5R0knPtY4XwC9BibbcLUEkqh/N6qwOzIYBBzFJUtQRRlosMTjuwE 4tB3fu6+OkDy0I29OsV7d24t3wMZ54qltiPdtORnw0pQyzkvCFsKPW7veg3pepu+c1FQ MSJ8yKMNDZoJ8gF8/0+gfV+JgSOAjwDl5C7jH+nvx2GwoBTd2zfDDSGkBXOHTJ1k88e5 +s8h9/AUE6TDUXOmB7vatDmiTqNO2Iv6h7XlegsoHwFqafEO1wmyR5SLM2syrFT6ngDH 00yZVin9tNSdA7AGF2pGCZTsk96mArBM4jSopXE6G8+epRlisj+kytRhk+KkTkPhZqE0 8o6w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from pete.vger.email (pete.vger.email. [2620:137:e000::3:6]) by mx.google.com with ESMTPS id k7-20020a633d07000000b005ad91e8b473si200163pga.626.2023.10.16.14.45.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Oct 2023 14:45:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) client-ip=2620:137:e000::3:6; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:6 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id D01D58076170; Mon, 16 Oct 2023 14:45:11 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234169AbjJPVou (ORCPT <rfc822;hjfbswb@gmail.com> + 18 others); Mon, 16 Oct 2023 17:44:50 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45048 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234205AbjJPVoq (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Mon, 16 Oct 2023 17:44:46 -0400 Received: from mail-oi1-f175.google.com (mail-oi1-f175.google.com [209.85.167.175]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D317CFC; Mon, 16 Oct 2023 14:44:44 -0700 (PDT) Received: by mail-oi1-f175.google.com with SMTP id 5614622812f47-3ae2f8bf865so3136385b6e.2; Mon, 16 Oct 2023 14:44:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697492684; x=1698097484; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=gmfkMrLhqQX7VpvIedVUrmMesFIoJFx2r4z/RkhPLxM=; b=Y6iFOa6Ri94YEcJK8IQ2tZp3cTVSrXrWXlc6Pp9Dbk2NaTQNuJ7dIY+UPJRkgU4OOT vVnHP1XABn2Q+Tnj59wWnXYYA8E416YnL96Ipq7gZcI6xDlIabR/W3ryJJFRY9PLgl7r nqOuVGgYaBhdZo6DXWqRGSvBGfdJSgRQuVz66FBdi0p+YfvRUpUW4KsSlaWbZUS9Hbeg BsWAZaHBiuk8/o6rzpFXoSJB+/+dSBVH1BlQG/0+ckDPjpovauO8+oM3if60AL2YcD09 3aPKl9BkEKmnb9Rs11NynYOGzLul1J9tvl4EpoOu9j9kdJwE3nH0sH2tnaJWAh53JxgT pICQ== X-Gm-Message-State: AOJu0Yxe6QdbOioPMxsf6r9de2cCs83J3Tm4K8BRfotnsrq/OaRFyryQ InjwEq36g1Rdg0p9U/cUAA== X-Received: by 2002:a05:6808:18a2:b0:3a7:4b9a:43c2 with SMTP id bi34-20020a05680818a200b003a74b9a43c2mr700359oib.13.1697492684081; Mon, 16 Oct 2023 14:44:44 -0700 (PDT) Received: from robh_at_kernel.org (66-90-144-107.dyn.grandenetworks.net. [66.90.144.107]) by smtp.gmail.com with ESMTPSA id bi5-20020a056808188500b003ac9e775706sm32192oib.1.2023.10.16.14.44.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Oct 2023 14:44:43 -0700 (PDT) Received: (nullmailer pid 3823216 invoked by uid 1000); Mon, 16 Oct 2023 21:44:35 -0000 From: Rob Herring <robh@kernel.org> Date: Mon, 16 Oct 2023 16:44:23 -0500 Subject: [PATCH net-next 4/8] dt-bindings: net: ethernet-switch: Add missing 'ethernet-ports' level MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20231016-dt-net-cleanups-v1-4-a525a090b444@kernel.org> References: <20231016-dt-net-cleanups-v1-0-a525a090b444@kernel.org> In-Reply-To: <20231016-dt-net-cleanups-v1-0-a525a090b444@kernel.org> To: "David S. Miller" <davem@davemloft.net>, Eric Dumazet <edumazet@google.com>, Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>, Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>, Conor Dooley <conor+dt@kernel.org>, Chen-Yu Tsai <wens@csie.org>, Jernej Skrabec <jernej.skrabec@gmail.com>, Samuel Holland <samuel@sholland.org>, Andrew Lunn <andrew@lunn.ch>, Florian Fainelli <f.fainelli@gmail.com>, Vladimir Oltean <olteanv@gmail.com>, Matthias Brugger <matthias.bgg@gmail.com>, AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>, Woojung Huh <woojung.huh@microchip.com>, UNGLinuxDriver@microchip.com, Linus Walleij <linus.walleij@linaro.org>, =?utf-8?q?Alvin_=C5=A0ipraga?= <alsi@bang-olufsen.dk>, =?utf-8?b?Q2zDqW1l?= =?utf-8?b?bnQgTMOpZ2Vy?= <clement.leger@bootlin.com>, Geert Uytterhoeven <geert+renesas@glider.be>, Magnus Damm <magnus.damm@gmail.com>, Maxime Ripard <mripard@kernel.org>, =?utf-8?b?bsOnIMOcTkFM?= <arinc.unal@arinc9.com>, Landen Chao <Landen.Chao@mediatek.com>, DENG Qingfang <dqfext@gmail.com>, Sean Wang <sean.wang@mediatek.com>, Daniel Golle <daniel@makrotopia.org>, John Crispin <john@phrozen.org>, Gerhard Engleder <gerhard@engleder-embedded.com>, Heiner Kallweit <hkallweit1@gmail.com>, Sergey Shtylyov <s.shtylyov@omp.ru>, Sergei Shtylyov <sergei.shtylyov@gmail.com>, Justin Chen <justin.chen@broadcom.com>, Florian Fainelli <florian.fainelli@broadcom.com>, Grygorii Strashko <grygorii.strashko@ti.com>, Sekhar Nori <nsekhar@ti.com>, Claudiu Manoil <claudiu.manoil@nxp.com>, Alexandre Belloni <alexandre.belloni@bootlin.com> Cc: Vladimir Oltean <vladimir.oltean@nxp.com>, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-renesas-soc@vger.kernel.org, bcm-kernel-feedback-list@broadcom.com X-Mailer: b4 0.13-dev X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Mon, 16 Oct 2023 14:45:12 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1779950159635892097 X-GMAIL-MSGID: 1779950159635892097 |
Series |
dt-bindings: net: Child node schema cleanups
|
|
Commit Message
Rob Herring
Oct. 16, 2023, 9:44 p.m. UTC
The '$defs/ethernet-ports' schema is referenced by schemas defining a
child node 'ethernet-ports', but this schema misses the
'ethernet-ports' node. It would work if referring schemas made a
reference like this:
properties:
ethernet-ports:
$ref: ethernet-switch.yaml#/$defs/ethernet-ports
However, that would be different from how dsa.yaml works. For
consistency, align the schema definition with dsa.yaml and add the
missing level.
Signed-off-by: Rob Herring <robh@kernel.org>
---
Documentation/devicetree/bindings/net/ethernet-switch.yaml | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
Comments
On 17.10.2023 00:44, Rob Herring wrote: > The '$defs/ethernet-ports' schema is referenced by schemas defining a > child node 'ethernet-ports', but this schema misses the > 'ethernet-ports' node. It would work if referring schemas made a > reference like this: > > properties: > ethernet-ports: > $ref: ethernet-switch.yaml#/$defs/ethernet-ports > > However, that would be different from how dsa.yaml works. For > consistency, align the schema definition with dsa.yaml and add the > missing level. > > Signed-off-by: Rob Herring <robh@kernel.org> Acked-by: Arınç ÜNAL <arinc.unal@arinc9.com> Arınç
On Mon, Oct 16, 2023 at 04:44:23PM -0500, Rob Herring wrote: > The '$defs/ethernet-ports' schema is referenced by schemas defining a > child node 'ethernet-ports', but this schema misses the > 'ethernet-ports' node. It would work if referring schemas made a > reference like this: > > properties: > ethernet-ports: > $ref: ethernet-switch.yaml#/$defs/ethernet-ports > > However, that would be different from how dsa.yaml works. For > consistency, align the schema definition with dsa.yaml and add the > missing level. > > Signed-off-by: Rob Herring <robh@kernel.org> > --- > Documentation/devicetree/bindings/net/ethernet-switch.yaml | 10 ++++++---- > 1 file changed, 6 insertions(+), 4 deletions(-) > > diff --git a/Documentation/devicetree/bindings/net/ethernet-switch.yaml b/Documentation/devicetree/bindings/net/ethernet-switch.yaml > index dcbffe19d71a..688938c2e261 100644 > --- a/Documentation/devicetree/bindings/net/ethernet-switch.yaml > +++ b/Documentation/devicetree/bindings/net/ethernet-switch.yaml > @@ -58,9 +58,11 @@ $defs: > $ref: '#' > > patternProperties: > - "^(ethernet-)?port@[0-9a-f]+$": > - description: Ethernet switch ports > - $ref: ethernet-switch-port.yaml# > - unevaluatedProperties: false > + "^(ethernet-)?ports$": > + patternProperties: > + "^(ethernet-)?port@[0-9a-f]+$": > + description: Ethernet switch ports > + $ref: ethernet-switch-port.yaml# > + unevaluatedProperties: false > > ... > > -- > 2.42.0 > Huh, interesting. Reviewed-by: Vladimir Oltean <vladimir.oltean@nxp.com>
diff --git a/Documentation/devicetree/bindings/net/ethernet-switch.yaml b/Documentation/devicetree/bindings/net/ethernet-switch.yaml index dcbffe19d71a..688938c2e261 100644 --- a/Documentation/devicetree/bindings/net/ethernet-switch.yaml +++ b/Documentation/devicetree/bindings/net/ethernet-switch.yaml @@ -58,9 +58,11 @@ $defs: $ref: '#' patternProperties: - "^(ethernet-)?port@[0-9a-f]+$": - description: Ethernet switch ports - $ref: ethernet-switch-port.yaml# - unevaluatedProperties: false + "^(ethernet-)?ports$": + patternProperties: + "^(ethernet-)?port@[0-9a-f]+$": + description: Ethernet switch ports + $ref: ethernet-switch-port.yaml# + unevaluatedProperties: false ...