From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796081157; b=E0UxAG2YK9ASNhKytfS5eS4dhAZ6Bwih11oRJ2MWcg5XmnFQ5Grv28IXR0eW12AlrphF 9pH324mQTWuvqvQmfqNq7bcUB2qZa8aywxnIFh6hX8QHDIBOOIluXplI2hphXHf3bOmCz sGTe8KI1r7juEXcprUA0qYY4jFZoKCprshv+ugnrFPHpgT7O7LckLoYUp4hZzcmQrDxKr Eqj9Nq7f+OQb7+sNwXS2VpawhOhL9w/vYh76g9p1MmyeRcjKzSAh6yHBeD+LcCm8YRcUL lBRXQLdDcb6S/Nac3cz1BdnRSu0jgXFUMOno8FkDtsFROTXTuSDZ3MxWidxve4HHhnw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796081157; h=Received:DKIM-Signature:Message-ID:From:Subject:Reply-To:To:Cc: In-Reply-To:References:Content-Type:Content-Transfer-Encoding:Date; bh=QdxHHHgqmHdlnWvagBOzWyXPkKym1oavSDxioPSg6yY=; b=gy5ofZu8QdRBcgpBY5w41CIfKsA7dDwGP0J/9Xmp8SryknYDz52d3t4J3QfHkvU9hmNl 56CfD7he+Cegb1tLhxLlBHDfgwr7VXRBSbTce5ScEMSDaBj4bEJcrueSM+8gUb7RYEftO uRNn0Q5bSMdD499jjo2BDbyqGtqGQzi9cKtX04ebq50iUuq2NI6Z4oUiQ7JZbb8o6+QjB J9J4M5kcLRlpucfxUh6F8HKIFHf2or1oH5vUVANxQoUyE8qCUYX4lZOnB7IHkvc88hZ8D pHX4SZoqossG8jRt/sqx+HaRmNBFB4obcf1fUkkIHaRfIBKB7cjTzuqcplWmJ2lYo+w== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=M6X9m6Wm; arc=none smtp.remote-ip=100.103.45.18 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 113CC606A320 for ; Mon, 30 Nov 2026 23:25:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=M6X9m6Wm Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2BC291F00927; Mon, 30 Nov 2026 23:25:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796081156; bh=QdxHHHgqmHdlnWvagBOzWyXPkKym1oavSDxioPSg6yY=; h=From:Subject:Reply-To:To:Cc:In-Reply-To:References:Date; b=M6X9m6WmQgOyH+YhE9kTeclwTGS+hIo/OXJKBRU2Tw89mEO51C7p9A8nugNJYEyql 2wMkT7zz+Nb/dmRwC1NLzKEy1Uh9NKQCQUKGkcW0xrAPD6crDoKsCLpdYEi0c0upGS UFYv84ojv5NPdhhZhxolHOXGmQWGiYCED8z4WGgRjCiAGnDWRhaVbkSyoTmPvDSuP5 seAFDepW6r2GOzzLU/QLPBZTIkUSAkHfiMpUd+dGjFxwQFa9BrMXFRGjUTxwKK9tnF sjavAbgTK6Mvyfo5RTZ+kkcIRcaqcz7EX4ORylzrylpGps0uldPdM4DS2kbE8kNZbJ yrPvHpda2xxZA== Message-ID: From: sashiko-bot@kernel.org Subject: Re: [PATCH net-next v23 13/15] dt-bindings: net: pcs: Document support for Airoha Ethernet PCS Reply-To: sashiko-reviews@lists.linux.dev To: "Christian Marangi" , devicetree@vger.kernel.org Cc: robh@kernel.org, conor+dt@kernel.org In-Reply-To: <20261129230558.612526-14-ansuelsmth@gmail.com> References: <20261129230558.612526-1-ansuelsmth@gmail.com> <20261129230558.612526-14-ansuelsmth@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Date: Mon, 30 Nov 2026 23:25:55 +0000 X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list Thank you for your contribution! Sashiko AI review found 4 potential issues to consider: - [Medium] dt-bindings: net: pcs: airoha,scu conflicts with SCU PHY and PCIe PHY MMIO - [Medium] dt-bindings: net: pcs: missing resets and #pcs-cells consumer mismatch - [Low] dt-bindings: net: pcs: unwieldy per-compatible conditionals in airoha,pcs.yaml - [Low] dt-bindings: net: pcs: typo 10BASE-R for 10GBASE-R in description -- commit 6b51fe520d3567df1745ff58edfff93a1c09b45b Author: Christian Marangi dt-bindings: net: pcs: Document support for Airoha Ethernet PCS This commit adds the Device Tree binding schema for the Airoha Ethernet PCS and SerDes on the AN7581 SoC. > diff --git a/Documentation/devicetree/bindings/net/pcs/airoha,pcs.yaml b/= Documentation/devicetree/bindings/net/pcs/airoha,pcs.yaml > new file mode 100644 > index 0000000000000..9c1d116c1b016 > --- /dev/null > +++ b/Documentation/devicetree/bindings/net/pcs/airoha,pcs.yaml > @@ -0,0 +1,261 @@ > +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/net/pcs/airoha,pcs.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Airoha Ethernet PCS and Serdes > + > +maintainers: > + - Christian Marangi > + > +description: > + Airoha AN7581 SoC expose multiple Physical Coding Sublayer (PCS) for > + the various Serdes port supporting different Media Independent Interfa= ce > + (10BASE-R, USXGMII, 2500BASE-X, 1000BASE-X, SGMII). [Severity: Low] As reported by Benjamin Larsson on RFC v5 [1], should 10BASE-R be 10GBASE-R here and in the commit message? The reg item descriptions below also mix "reg" and "register". > + > +properties: > + compatible: > + enum: > + - airoha,an7581-pcs-eth > + - airoha,an7581-pcs-pon > + - airoha,an7581-pcs-pcie > + - airoha,an7581-pcs-usb > + > + reg: > + minItems: 6 > + maxItems: 15 > + > + reg-names: > + minItems: 6 > + maxItems: 15 > + > + airoha,scu: > + $ref: /schemas/types.yaml#/definitions/phandle > + description: phandle to the SCU node required to configure > + the serdes line to the correct interface mode. [Severity: Medium] As reported by Jakub Kicinski on v22 [2], is a bare airoha,scu phandle the right interface for selecting the SerDes mode while forbidding phys on the eth, pon, and pcie variants? The AN7581 SCU node (scuclk, compatible airoha,en7581-scu) already exposes SerDes mode selection on REG_NP_SCU_SSTR and REG_NP_SCU_SSR3 under priv->lock as a generic PHY provider (#phy-cells =3D <1>). Because scuclk is not a syscon, syscon_regmap_lookup_by_phandle() in airoha_pcs_probe() fails with -EINVAL when given &scuclk as shown in the examples, and a separate regmap would access those SCU registers without priv->lock. In addition, in the airoha,an7581-pcs-pcie example below, pcs_ana (0x1fa5a000), pcs_pma0 (0x1fa5b000), and pcs_pma1 (0x1fa5c000) claim the same MMIO ranges as csr-2l, pma0, and pma1 of phy@1fa5a000 (airoha,en7581-pcie-phy in arch/arm64/boot/dts/airoha/en7581.dtsi), causing an exclusive memory region conflict (-EBUSY) when both drivers probe. > + > + phys: > + maxItems: 1 > + > + "#pcs-cells": true > + > +required: > + - compatible > + - reg > + - reg-names > + - "#pcs-cells" > + > +allOf: > + - if: > + properties: > + compatible: > + contains: > + enum: > + - airoha,an7581-pcs-eth > + - airoha,an7581-pcs-pon [Severity: Low] This isn't a bug, but the variants share almost no top-level constraints and override reg, reg-names, #pcs-cells, phys, and airoha,scu across three large per-compatible if/then blocks. Would splitting the distinct variants into separate schema documents be cleaner? [ ... ] > + "#pcs-cells": > + const: 1 > + > + required: > + - airoha,scu > + > + - if: > + properties: > + compatible: > + contains: > + const: airoha,an7581-pcs-usb > + > + then: > + properties: > + reg: > + items: > + - description: PCS MAC reg > + - description: HSGMII AN reg > + - description: HSGMII PCS reg > + - description: MULTI SGMII reg > + - description: HSGMII rate adaption reg > + - description: PCS Analog register > + > + reg-names: > + items: > + - const: pcs_mac > + - const: hsgmii_an > + - const: hsgmii_pcs > + - const: multi_sgmii > + - const: hsgmii_rate_adp > + - const: pcs_ana > + > + airoha,scu: false > + > + "#pcs-cells": > + const: 0 > + > + required: > + - phys > + > +additionalProperties: false [Severity: Medium] As reported by Jakub Kicinski on v22 [2], should resets and reset-names be documented here? airoha_pcs_probe() requests the "mac" and "phy" resets, so with additionalProperties: false any DT node providing them will fail schema validation. Also, requiring #pcs-cells =3D <1> for airoha,an7581-pcs-pcie conflicts with Documentation/devicetree/bindings/net/ethernet-controller.yaml (referenced by airoha,en7581-eth.yaml), which restricts each pcs-handle entry to maxItems: 1 (phandle only, with no argument cells). [1] https://lore.kernel.org/r/5f3b3b38-1b53-4b9a-9673-de4ca321b3f1@genexis.= eu [2] https://lore.kernel.org/r/20261121232654.1365615-1-kuba@kernel.org --=20 Sashiko AI review =C2=B7 https://sashiko.dev/#/patchset/20261129230558.6125= 26-1-ansuelsmth@gmail.com?part=3D13