๐Ÿš€ go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #26808

Re: [PATCH net-next V29 1/3] dt-bindings: net: Document Motorcomm YT8824 PHY package

#26808
From: Kyle Switch
Date: Fri, 04 Dec 2026 07:20
109 lines
12203 bytes
On 12/4/26 11:46, netdev-bot+sashiko@kernel.org wrote:
> Thank you for your contribution! Sashiko AI review found 1 potential
> issue(s) to consider.
>
> Critical: 0 ยท High: 0 ยท Medium: 1 ยท Low: 0
>
> If you believe none of the issues are legitimate, please reply to each
> issue of Medium severity or higher and explain why the AI is wrong.
> If any of them are legitimate and you plan to respin, please let patchwork
> know by including "pw-bot: cr" as a separate line at the end of your reply
> (one such reply per series is enough).
>
> - [Medium] In motorcomm,yt8824.yaml, the description of the external
>    (10g-qxgmii) mode says the address can vary, but the schema fixes it.
>
> --
>
> dt-bindings: net: Document Motorcomm YT8824 PHY package
>
> This patch adds a binding for the Motorcomm YT8824 quad PHY package. It
> builds on ethernet-phy-package.yaml and adds a new
> motorcomm,package-mode property to choose internal or 10g-qxgmii mode.
> It also adds a maintainer and an F: entry to the MOTORCOMM PHY DRIVER
> section in MAINTAINERS.
>
>> diff --git a/Documentation/devicetree/bindings/net/motorcomm,yt8824.yaml b/Documentation/devicetree/bindings/net/motorcomm,yt8824.yaml
>> new file mode 100644
>> index 0000000000000..1065e5382670f
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/net/motorcomm,yt8824.yaml
> [ ... ]
>
>> +  motorcomm,package-mode:
>> +    description: |
>> +      PHY package can be configured in 2 modes:
>> +      - internal: YT8824 is embedded in the switch, using
>> +        an internal interface to the MAC. The member PHYs are
>> +        fixed at MDIO addresses 4..7 and the shared top
>> +        extended register block is at address 9.
>> +      - 10g-qxgmii: YT8824 is a standalone external PHY,
>> +        connected via 10G QXGMII. The member PHYs start at
>> +        the base MDIO address and the shared top extended
>> +        register block is at base + 4.
>> +    $ref: /schemas/types.yaml#/definitions/string
>> +    enum: [ internal, 10g-qxgmii ]
>> +
>> +  reg:
>> +    description:
>> +      The absolute MDIO address of the YT8824 shared top extended
>> +      register block.
>> +      For internal mode, this is fixed at 9;
>> +      For external mode, it is the base MDIO address of the four
>> +      member PHYs plus 4, where base is typically 0x0.
>> +      Note that this is NOT the reg of the first member PHY.
> [ ... ]
>
>> +  - if:
>> +      properties:
>> +        motorcomm,package-mode:
>> +          const: 10g-qxgmii
>> +    then:
>> +      properties:
>> +        reg:
>> +          const: 4
> [Severity: Medium]
> Do the text and the schema agree for the 10g-qxgmii case?
>
> The motorcomm,package-mode description says the member PHYs "start at the
> base MDIO address" and the top block is "at base + 4". The reg description
> says base is "typically 0x0". Both suggest the base can be something other
> than 0.
>
> This branch sets reg to const 4, so 0 is the only base that passes the
> schema. The parent ethernet-phy-package.yaml allows any reg from 0 to 31:
>
>    reg:
>      minimum: 0
>      maximum: 31
>
> So the limit to 4 comes only from this binding.
>
> Suppose an external YT8824 is strapped to a non-zero base, for example
> PHYs at 8..11 with the top block at 12. Would its DT fail
> dt_binding_check? It also seems that two external YT8824 packages could
> never share one MDIO bus in a schema-valid DT.
>
> The driver patch later in this series ("net: phy: Add driver for
> Motorcomm Quad 2.5GbE phy") makes the same assumption.
> yt8824_utp_shared_group() in drivers/net/phy/motorcomm.c hard-codes a base
> of 0 for non-internal mode:
>
> 	if (priv->package_mode == PHY_INTERFACE_MODE_INTERNAL)
> 		base = 4;
> 	else
> 		base = 0;
>
> 	if (addr < base || addr >= base + YT8824_UTP_SHARED_GROUPS * 2)
> 		return -EINVAL;
>
> The schema and the driver match each other, but neither matches the
> binding text. The binding is unchanged at the end of the series.
>
> This is new DT ABI, so which one is intended? If the hardware supports a
> variable base, could reg be a range, with driver support for that base?
> If the external base is hard-wired to 0, could the text say so and drop
> the "base" and "typically 0x0" wording?
okay, will be fixed in next patch.
Technical Details
Message-ID: <55fa1201-f1c1-49f0-a9b5-fca1efc95f5e@motor-comm.com>
Path: mbox-mo1.pugleaf.net!feed-us-txt.newsdeef.eu!feed-us-mo.newsdeef.eu!srv.newsdeef.eu!news.mb-net.net!open-news-network.org!3.eu.feeder.erje.net!feeder.erje.net!feeder1.feed.ams11.usenet.farm!feed.usenet.farm!feeder.usenetexpress.com!tr3.eu1.usenetexpress.com!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-377149-linux-kernel-netdev=dewy.ru
References: <20261201094405.3036391-1-kyle.switch@motor-comm.com> <179635601335.3146.13283218503536356094@kernel.org>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!feed-us-txt.newsdeef.eu!feed-us-mo.newsdeef.eu!srv.newsdeef.eu!news.mb-net.net!open-news-network.org!3.eu.feeder.erje.net!feeder.erje.net!feeder1.feed.ams11.usenet.farm!feed.usenet.farm!feeder.usenetexpress.com!tr3.eu1.usenetexpress.com!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-377149-linux-kernel-netdev=dewy.ru
From: kyle.switch@motor-comm.com (Kyle Switch)
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH net-next V29 1/3] dt-bindings: net: Document Motorcomm YT8824 PHY package
Date: Fri, 4 Dec 2026 15:20:49 +0800
Organization: Usenet Network
Message-ID: <55fa1201-f1c1-49f0-a9b5-fca1efc95f5e@motor-comm.com>
References: <20261201094405.3036391-1-kyle.switch@motor-comm.com> <179635601335.3146.13283218503536356094@kernel.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Info: usenet.network; logging-data="2701810"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:s/HnDwpNWLdvHVR48r13dcTq/ck= sha256:UiVHyuDJp71r4HQa7cnl/BIGI5lz86kW24FYDpa3b78= sha1:WzkGLETYO34x4ASKOYOuDop3j3w= sha256:BdCSFytkU+6tfOQVHVjgI/j7gTHsft/ucPFD94ZMIOE=
Content-Language: en-US
List-ID: <netdev.vger.kernel.org>
X-Mailpost-Empty-Hdrs: X-Spam-Level
X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id C9687117B55; Fri,  4 Dec 2026 10:21:41 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.198
X-Spam-Status: No, score=-3.198 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.001, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, UNPARSEABLE_RELAY=0.001] autolearn=ham autolearn_force=no
X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Qn_ewIsYA4Hw; Fri,  4 Dec 2026 10:21:29 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=104.64.211.4; helo=sin.lore.kernel.org; envelope-from=netdev+bounces-377149-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN>
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=motor-comm.com
X-Received: from sin.lore.kernel.org (sin.lore.kernel.org [104.64.211.4]) by mail.dewy.ru (Postfix) with ESMTPS id BC937117B36; Fri,  4 Dec 2026 10:21:16 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by sin.lore.kernel.org (Postfix) with ESMTP id 0C6D321C91; Fri,  4 Dec 2026 07:21:09 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1796368865; b=Kd7M0c4AjflqUVSB3YidZlMp3GosXvo9isi3o4YTAew4qfq7LbTIXF9MZp6k+ny4HoKM UudHRiZiR2ksM9mIG8Eyp5banZyt+SXlVUCjyD8J8W0NA0XSbCCl6iyrnTXHe3tarvXrd /7LYIIKveFOsrSVD3dSDk+MiPa5UHM2t2qSqoUYbFKuhdNx33HwJJVnq4VQaiMkjOXi1H 5bpgZg6C2S9m8U7bnP5zLOzll1kJAh/09/L+YeRK45vJCori68A60P5m7LvvlB3gxycpp aggWfpcJPchEtSh0Sn/9iwOoBu7S2QgQgxIsqg6mFV3ZSZ0tHLumYeiK8xJfmKCGoIQ==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796368865; h=X-Original-To:Received:DMARC-Filter:X-Alimail-AntiSpam:Received: Message-ID:Date:X-Mailing-List:List-Id:List-Post:List-Help: List-Subscribe:List-Unsubscribe:List-Owner:Precedence:MIME-Version: User-Agent:Subject:To:Cc:References:Content-Language:From:In-Reply-To: Content-Type:Content-Transfer-Encoding; bh=98r7bTwqsn6zp7jSTN/xyCXrHD0Rk4sOmk9bRDcERZE=; b=sBpCgSVOoq/8hGeClFh7LoevxH6OF95JAERg7aFpbs6E3Vgi5qrEINhS6VBUNxizVpyO cIPMhZ/gylM9qrBq7i6pzYD9HcAXJ+Y6U8XDSku0zMz2pXwlY+/Rm54YJrlukYszE28VI DggoJnZ2qwvhWJDVb6hnmGluZce1nDoPe+jkRvy36vr0bMoLWhR2mS22aCEz0t0oLRlur up6p4wR6mQz9I+spa8mY4FAuiirMViAp1uofwf74ifX1nSrl5csDbwavjNNviqpuyL3Gh C7pkH1nz4G/qQ9WSnXQLbx1MsdI318n7wu6JeEaixJUhuD9fvEJ7hW+vinxWS7PEYqg==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass header.from=motor-comm.com; spf=pass smtp.mailfrom=motor-comm.com; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id DDA02606A339; Fri,  4 Dec 2026 07:21:05 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=115.124.28.52
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796368865; b=avJQcQJBmmICay9jGWNmSvpy621wZo8+2nDVPNGfP557+IDab+de0Szb/O5QRz1vQFzM az/ps5CTcZNajGC6TTRVz3IFfmfLJeGluOEv4vOQGWPRUJRMrMQpaOIKlHqxmSVZ0bDQP 6ud3UJxc3zscWwC1gTS3WgL80aBjYynHQhFKdZkfvTy/7OkY0mlko2gqagU7eYzgBfYg4 qa+5iW4ZqRfdRlvVZiAcAOw83O0EgHsDmEcoUbWhRlTSv3w6n3j4metHMYsqpG5XNPniU s2Kj/xDwI10lcqvulVtW4svbZ861FTf5s2noxOS3m0lCxpanYO/dgeYN62qmwnLLx1A==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796368865; h=DMARC-Filter:X-Alimail-AntiSpam:Received:Message-ID:Date: MIME-Version:User-Agent:Subject:To:Cc:References:Content-Language: From:In-Reply-To:Content-Type:Content-Transfer-Encoding; bh=98r7bTwqsn6zp7jSTN/xyCXrHD0Rk4sOmk9bRDcERZE=; b=j0ix4rhg9ICBubOSWPs2RHtj0swUq+8UtJKbA4JXRYelFM5p++chwR3XKtu7STKINnq7 vWrc6G/IsWaArPQrlRq7TlmW+whmCw7CEN91jWc13CXjJX1N0OCv6RgSf9tgJop9CgMR/ oz7nuRjTXGLUcf/tilUOwfAAkDt8C+nN0qBqcAbJatarqgcdXKgt9NyNwWDF5mwnFQZMC Ub7/ffHGxCErwy90EhcUpgqWRe+S8r+aP4b3k+lpBBTLvGM+mkr+Ndg3Gd7WgO4EL2OsZ 01Md76FY1akQTjFyIFwrHNxx6Fedes7uUF0UcNROtPz3Gnung2knAlPc/ysAUfB95Lg==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=motor-comm.com; spf=pass smtp.mailfrom=motor-comm.com; arc=none smtp.remote-ip=115.124.28.52
X-Received: from out28-52.mail.aliyun.com (out28-52.mail.aliyun.com [115.124.28.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 14F91606A322; Fri,  4 Dec 2026 07:21:01 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 14F91606A322
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=motor-comm.com
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=motor-comm.com
X-Alimail-AntiSpam: AC=CONTINUE;BC=0.07449161|-1;CH=green;DM=|CONTINUE|false|;DS=CONTINUE|ham_system_inform|0.01635-0.000836693-0.982813;FP=16204260130053686007|0|0|0|0|-1|-1|-1;HT=maildocker-contentspam033032106048;MF=kyle.switch@motor-comm.com;NM=1;PH=DS;RN=19;RT=19;SR=0;TI=SMTPD_---.kGRZPLa_1796368850;
X-Received: from 10.10.26.192(mailfrom:kyle.switch@motor-comm.com fp:SMTPD_---.kGRZPLa_1796368850 cluster:ay29) by smtp.aliyun-inc.com; Fri, 04 Dec 2026 15:20:52 +0800
X-Mailing-List: netdev@vger.kernel.org
X-List-Post: <mailto:netdev@vger.kernel.org>
X-List-Help: <mailto:netdev+help@vger.kernel.org>
X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org>
X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org>
X-List-Owner: <mailto:netdev+owner@vger.kernel.org>
X-Precedence: list
X-User-Agent: Mozilla Thunderbird
X-Cc: andrew+netdev@lunn.ch, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, andrew@lunn.ch, hkallweit1@gmail.com, linux@armlinux.org.uk, Frank.Sae@motor-comm.com, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, ming.xu@motor-comm.com, xiaolin.xu@motor-comm.com, jianmin.wang@motor-comm.com
X-In-Reply-To: <179635601335.3146.13283218503536356094@kernel.org>