From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=66.163.184.199 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796365318; b=NpRGniPQJ56Dh5QiR7P91G8EQnqKnzeY2yijnvPpVUCQX4vYrP9s29hP8UqZKNf5Jx/D SunLBkykwWDTEuPsse5mKTkMeB3l5JKzEElpripPjtfIWHkJBrFE6cj3BLi8yJmZFxMBi igprHtpLfaWoY3iALhNUvpI+klG11ku9Kr0/d1XKsnlLZ2sZ+8882BWp9NsXmnSsXLGxu r7b6UbCXSzgzNgPDFL/DjQPe+cP2etl7UB4F5bGpX85VzZxb2ZwS/L3/+bfhMTBeE68tE FrOJcsF7Yd9anfpiYsz4DSeuBx3eiNObpUu3F9xVKMQ1AJKTlT5FDUW2gGUw98hjTtQ== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796365318; h=DMARC-Filter:DKIM-Signature:X-SONIC-DKIM-SIGN:X-YMail-OSG:X-Sonic-MF: X-Sonic-ID:Received:Received:Message-ID:Date:MIME-Version:User-Agent: Subject:To:Cc:References:Content-Language:From:In-Reply-To: Content-Type:Content-Transfer-Encoding:X-Mailer; bh=3/Lf2dCkx43KXlLSSzlyC5Xi+D42rzLrH842wdkTgLk=; b=k7vOXapmwyPAHoNByyUw4rRYMkpMT9WGBTm+OYqUI0fmObiXJcdq1K/44tv54ohySIht +gWOHJnzADfdjvQvoZFbAgSgkXKwQoCr5yF+oLOXMbrZu2GuMvAa6bryZ1gqkrJxRvvYb 3+GOP9PFC3wewsWPY+95slWhQzFK43LXzwFeKNeNvY9SkWm9S1Tbg3nyOKPNmXNcVun43 k37ry/VIxeonbyAO5/wPaI99qDaURTG34HGN/9nKme+zipsn5gGh/A33FT9KeM6L65ggR zGQkpRWbudNNY2/nH411ls+CW4u/OThMkqqS77ynNXaOx6FZwvs/MRkNNELTiW6zgWw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=yahoo.com; spf=pass smtp.mailfrom=yahoo.com; dkim=pass header.d=yahoo.com header.i=@yahoo.com header.a=rsa-sha256 header.s=s2048 header.b="PCg/ucVx"; arc=none smtp.remote-ip=66.163.184.199 Received: from sonic301-30.consmr.mail.ne1.yahoo.com (sonic301-30.consmr.mail.ne1.yahoo.com [66.163.184.199]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 4FC0F606A338 for ; Fri, 4 Dec 2026 06:21:58 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 4FC0F606A338 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=yahoo.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=yahoo.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=yahoo.com header.i=@yahoo.com header.a=rsa-sha256 header.s=s2048 header.b=PCg/ucVx DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1796365317; bh=3/Lf2dCkx43KXlLSSzlyC5Xi+D42rzLrH842wdkTgLk=; h=Date:Subject:To:Cc:References:From:In-Reply-To:Content-Type:From:Subject:Reply-To:Content-Type; b=PCg/ucVxjKSf5TLo4NA/tHKYYV8wwPhZoT25+lXqp8N0umrsEPwYm417VeWrnXspPoax1J8BGVqPSQ1lNST8L+Gfdo9KeDZ5qZFhwfLEaJL3O5EC72K8FtQ41q833sbr+CbR70kUMM/w+6w2S41toPX3NPU+WvIxum2N9N1wyOkbbvOXJS4pPGXeEbS6Z7QEye51d9rOIUSFrPMjHduo0XbjiHLbK+iCSOap4idAMBnQjBfueRkewjpl6pkt+mhFSnvMfQdwvyYufGKmTwY6KU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gKgufyN24 mYys2FcdqeBs2t6gCasMnCX32u3Y7n38b_HuiZ1cotS4dE434THzHtjJRJ_Qgym3GUH8lUHuS0Id 5hsMw.oZxDhO66_M7JevxFV6Db64xJO8_TAjSnrlR2kUfjf6YXnIf8eEXtSRyl9xNyOkpqgtIzJE nkyRxHNoKViJMxD0Ty9vcBpEbBsfAo2D9EqwEvAJXnMaKVLLEnRqfCCqTx1DFM3TFOzhzc_FfetL FUgiEwiUOGsSxuIUM9MlnX.TKiUWoRqs6KkRGpLq9liJJJTfrLFrFrWtqpIhICGuJJT97Yu_PDQr DIjW4V1lnciaWoCrSE6xXaGeQL7eLNNiWS8YOfoDMGRFgbpOZi7pawxUxxkWIvRI79q4YVNRolAI AMqWhmINOqgsR0U5fKwngN_tjI8iiDzO0KAP26wfhtwXa5NoFIKip3qocob0oyqG1fyzb3om1mVz MH9Tp7HNSGaxTFa635Jx9gi.vgZIYHQVRLyriVX.fhOT3.QtySBT0KrMOmgXKkaJfkOLX0NzjHWN s8xfelotMILJbmJySsjwTcskVWM_vaHYsqOeXM8ZHbP.7qRKvMIA1dF3vuhw8spTmFO2IsmViup6 LG40g7YDV0_nfhT.INHCmu1xyKSAA2KTs4D9T7y3jjzAjFvLt6WADOUhfBHhZUfxcgNhNDl_KMLj uwS4ErG1FNcp8mkGSQAQJe.nyUB_KnHgI.6kIYd78LU1pHjwjPVb195wmSKfNnFUkbCO_GVbXXVj sN7a9yd6KsuznFI0- X-Sonic-MF: X-Sonic-ID: a1dfa957-0947-41f0-9ec7-b7e884abc2b5 Received: from sonic.gate.mail.ne1.yahoo.com by sonic301.consmr.mail.ne1.yahoo.com with HTTP; Fri, 4 Dec 2026 06:21:57 +0000 Received: by hermes--production-ir2-7c4859dc89-v5pln (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID f1302f5557738d10beed073379693a10; Fri, 04 Dec 2026 06:21:53 +0000 (UTC) Message-ID: <760ac1bf-a52c-4710-b3d6-090a5e1edc64@yahoo.com> Date: Fri, 4 Dec 2026 07:21:46 +0100 X-Mailing-List: netdev@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH net-next v19 15/15] net: dsa: realtek: rtl8365mb: add support for RTL8367S-VB To: netdev-bot+sashiko@kernel.org Cc: linusw@kernel.org, andrew@lunn.ch, olteanv@gmail.com, kuba@kernel.org, davem@davemloft.net, edumazet@google.com, pabeni@redhat.com, linux@armlinux.org.uk, luizluca@gmail.com, maxime.chevallier@bootlin.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, alvin.sipraga@analog.com, gusfmora@gmail.com, kuncy7@gmail.com, fabianotassotti@gmail.com, gabonpivovich@gmail.com, contact@c127.dev, o.rempel@pengutronix.de References: <179635073149.3146.8834479666757845007@kernel.org> Content-Language: pl From: Mieczyslaw Nalewaj In-Reply-To: <179635073149.3146.8834479666757845007@kernel.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Mailer: WebService/1.1.27159 mail.backend.jedi.jws.acl:role.jedi.acl.token.atz.jws.hermes.yahoo On 12/4/2026 3:18 AM, 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 rtl8365mb_pcs_config() > (drivers/net/dsa/realtek/rtl8365mb_main.c), DIGITAL_INTERFACE_SELECT… > > -- > > net: dsa: realtek: rtl8365mb: add support for RTL8367S-VB > > This patch adds the RTL8367S-VB (chip ID 0x6642, version 0x0010) to the > chip table as the first family D chip. That makes the family D code paths > from the earlier patches reachable. The new rtl8365mb_family_d leaves > jam_table unset and maps the SerDes to port 6 / EXT0 and the RGMII > interface to port 7 / EXT1. > >> diff --git a/drivers/net/dsa/realtek/rtl8365mb_main.c b/drivers/net/dsa/realtek/rtl8365mb_main.c >> index b3fc6fbfac7c8..2b7b364542a6c 100644 >> --- a/drivers/net/dsa/realtek/rtl8365mb_main.c >> +++ b/drivers/net/dsa/realtek/rtl8365mb_main.c > > [ ... ] > >> @@ -845,6 +861,24 @@ static const struct rtl8365mb_family_info rtl8365mb_family_c = { >> .qos_set_untag_pcp = rtl8365mb_c_qos_set_untag_pcp, >> }; >> >> +static const struct rtl8365mb_family_info rtl8365mb_family_d = { >> + .family = RTL8365MB_FAMILY_D, >> + .ext_config_forcemode = rtl8365mb_d_ext_config_forcemode, > > [ ... ] > >> @@ -935,6 +969,19 @@ static const struct rtl8365mb_chip_info rtl8365mb_chip_infos[] = { >> }, >> .num_tx_queues = 8, >> }, >> + { >> + .name = "RTL8367S-VB", >> + .chip_id = 0x6642, >> + .chip_ver = 0x0010, >> + .family_info = &rtl8365mb_family_d, >> + .port_mask = PORT_MASK(GENMASK(4, 0) | BIT(6) | BIT(7)), >> + .extints = { >> + { 6, 0, PHY_INTF(SGMII) | PHY_INTF(HSGMII) }, >> + { 7, 1, PHY_INTF(MII) | PHY_INTF(TMII) | >> + PHY_INTF(RMII) | PHY_INTF(RGMII) }, >> + }, >> + .num_tx_queues = 8, >> + }, >> }; > > [Severity: Medium] > This entry puts the SerDes on EXT0, and rtl8365mb_family_d has no > jam_table. On family D, does anything ever program the EXT0 mode field > (bits[3:0]) of DIGITAL_INTERFACE_SELECT (0x1305)? > > In rtl8365mb_pcs_config(), the only write to that register is skipped on > family D: > > drivers/net/dsa/realtek/rtl8365mb_main.c:rtl8365mb_pcs_config() { > ... > /* On family D, SDS_MISC selects the SerDes mode. id (1) refers to > * RGMII port 7 on RTL8367S-VB and must not be overwritten. The EXT0 > * field of DIGITAL_INTERFACE_SELECT is not programmed here and keeps > * its power-on or strap default; whether the vendor sequence sets it > * for the SerDes was not verified, but the link came up on all tested > * boards. > */ > if (!is_d) { > val = sds_mode << RTL8365MB_DIGITAL_INTERFACE_SELECT_MODE_OFFSET(id); > ret = regmap_update_bits(priv->map, > RTL8365MB_DIGITAL_INTERFACE_SELECT_REG(id), > ... > } > > On family C, the jam table in rtl8365mb_setup() also writes > { 0x1305, 0xC000 }. Here fi->jam_table is NULL, so that write is skipped > as well. On family D, rtl8365mb_ext_config_rgmii() only writes the EXT1 > nibble (bits[7:4]) for port 7. > > That leaves the EXT0 field and bits[15:14] at whatever value they have > after rtl8365mb_reset_chip(), which is the power-on or strap value. > > What happens on a board where that default leaves EXT0 in a non-SerDes > or disabled mode? rtl8365mb_d_ext_config_forcemode() would still force > MAC6 up from mac_link_up(), and pcs_get_state() only reads the SerDes > link bit. Could the CPU port then report link up but pass no traffic, > with no error logged? > > If the hardware ignores the EXT0 nibble once SDS_MISC selects > RTL8365MB_D_SDS_MISC_MAC6_SEL_SDS0, there is no problem. Can that be > checked against the vendor RTL8367D sequence? If not, should the EXT0 > field be programmed explicitly for the SerDes on family D? > Thanks for the review. I checked this against the vendor RTL8367D port API. In dal_rtl8367d_port_extMode_set() the SerDes path for MAC6 (id == 1) does not touch DIGITAL_INTERFACE_SELECT (0x1305) at all. It sets MAC6_SEL_SDS0, loads the SGCfg/HSGCfg tuning table through the SDS indirect window, sets the FIBER_CFG_2 RX disable field, and then programs PA12PC_EN, PA33PC_EN and the mode field in SDS_MISC. The EXT0 field (SELECT_GMII_0, bits 3:0) is defined in the vendor register header but is not used anywhere in the vendor code. Every write to 0x1305 there is to SELECT_GMII_1 (EXT1, RGMII on port 7). So on this family the SerDes mode is selected by SDS_MISC alone, and the driver matches the vendor sequence by not writing EXT0. No code change is needed.