Netdev List
 help / color / mirror / Atom feed
From: netdev-bot+sashiko@kernel.org
To: namiltd@yahoo.com
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
Subject: Re: [PATCH net-next v11 13/13] net: dsa: realtek: rtl8365mb: add support for RTL8367S-VB
Date: Thu, 19 Nov 2026 22:36:36 +0000	[thread overview]
Message-ID: <179512779630.3136.16071397271955524893@kernel.org> (raw)
In-Reply-To: <836bf744-b589-4d9e-80cb-ad20fb6725aa@yahoo.com>

Thank you for your contribution! Sashiko AI review found more severe
issue(s) in other patches of this series. This mail is only an FYI, in case
you want to address the nit picks below when you respin.

Low priority / nit picks for your consideration:

- [Low] In drivers/net/dsa/realtek/rtl8365mb_main.c, the new
  rtl8365mb_family_d descriptor sets `.jam_table =…

--

net: dsa: realtek: rtl8365mb: add support for RTL8367S-VB

This adds the RTL8367S-VB (chip ID 0x6642) to the chip table as the first
family D chip. It also adds an rtl8365mb_family_d descriptor that selects
the family D force-mode, VLAN, PVID and L2 helpers from the earlier
patches. The chip has 8 ports and reuses the existing initialization jam
table.

> diff --git a/drivers/net/dsa/realtek/rtl8365mb_main.c b/drivers/net/dsa/realtek/rtl8365mb_main.c
> index c7f209b41cac9..9b821b3230a0e 100644
> --- a/drivers/net/dsa/realtek/rtl8365mb_main.c
> +++ b/drivers/net/dsa/realtek/rtl8365mb_main.c

[ ... ]

> @@ -816,6 +829,25 @@ static const struct rtl8365mb_family_info rtl8365mb_family_c = {
>  	.l2_mc_to_data = rtl8365mb_c_l2_mc_to_data,
>  };
>  
> +static const struct rtl8365mb_family_info rtl8365mb_family_d = {
> +	.family = RTL8365MB_FAMILY_D,
> +	.num_ports = RTL8365MB_D_MAX_NUM_PORTS,
> +	.jam_table = rtl8365mb_init_jam_8365mb_vc,
> +	.jam_size = ARRAY_SIZE(rtl8365mb_init_jam_8365mb_vc),

[Severity: Low]
Is there an RTL8367D vendor reference showing that this init table is
valid for the RTL8367S-VB?

rtl8365mb_switch_init() writes each entry of fi->jam_table[] as a whole
register with regmap_write(). That means every family D probe now gets the
RTL8367C vendor init values. The commit message says only "The chip reuses
the existing initialization jam table" and does not give a source.

The new header comment says this chip's registers differ in the VLAN table,
the external interface/RGMII configuration, the SerDes, the LUT and the
table access control register. Other family D code in the series cites the
RTL8367D vendor API, for example dal_rtl8367d_l2_init() and
dal_rtl8367d_port_macForceLink_set(). Nothing like that backs this table.

Some entries, such as 0x18E0=0x4004, 0x122B=0x241C and 0x1305=0xC000, are
full-register values. They were built from RTL8367C read-modify-write
sequences on top of RTL8367C reset defaults.

Nothing in the tree says what 0x1303, 0x1304, 0x18E0, 0x122B, 0x13F0,
0x13EB, 0x13E2, 0x121E, 0x1233, 0x1237, 0x1239, 0x123A, 0x0301 or 0x1349
mean on family D.

At least one entry means something different on family D:

rtl8365mb_init_jam_8365mb_vc[]:
	{ 0x13E2, 0x003F }, { 0x13F9, 0x0090 }, { 0x121E, 0x03CA },

#define RTL8365MB_D_REG_EXT_TXC_DLY				0x13f9
#define   RTL8365MB_D_EXT1_RGMII_TX_DLY_MASK			GENMASK(5, 3)

The value 0x0090 sets the EXT1 RGMII TX delay field to 2. The RGMII path in
rtl8365mb_ext_config_rgmii() then has to clear it again:

	if (rtl8365mb_is_d(priv) && extint->id == 1) {
		ret = regmap_update_bits(priv->map,
					 RTL8365MB_D_REG_EXT_TXC_DLY,
					 RTL8365MB_D_EXT1_RGMII_TX_DLY_MASK, 0);

That particular case looks harmless. If the RTL8367D vendor switch init
uses different registers or values, though, could the other entries leave
analog, PHY or interface registers set wrongly on this chip?

The SGMII/HSGMII tests suggest nothing is badly wrong. RGMII mode is listed
as untested, though.

[ ... ]

-- 
Sashiko AI review · https://netdev-ai.bots.linux.dev/sashiko/#/patchset/cf3fd237-2290-4002-8de0-ea4100ef0f85%40yahoo.com

      reply	other threads:[~2026-11-19 22:36 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cf3fd237-2290-4002-8de0-ea4100ef0f85.ref@yahoo.com>
2026-11-17  7:34 ` [PATCH net-next v11 00/13] net: dsa: realtek: rtl8365mb: add support for RTL8367S-VB Mieczyslaw Nalewaj
2026-11-17  7:35   ` [PATCH net-next v11 01/13] dt-bindings: net: dsa: realtek: add RTL8367S-VB Mieczyslaw Nalewaj
2026-11-17  7:36   ` [PATCH net-next v11 02/13] net: dsa: realtek: rtl8365mb: add chip family infrastructure Mieczyslaw Nalewaj
2026-11-17  7:36   ` [PATCH net-next v11 03/13] net: dsa: realtek: rtl8365mb: refactor forcemode handling Mieczyslaw Nalewaj
2026-11-17  7:37   ` [PATCH net-next v11 04/13] net: dsa: realtek: rtl8365mb: set speed for family D Mieczyslaw Nalewaj
2026-11-17  7:38   ` [PATCH net-next v11 05/13] net: dsa: realtek: rtl8365mb: set RGMII mode " Mieczyslaw Nalewaj
2026-11-17  7:38   ` [PATCH net-next v11 06/13] net: dsa: realtek: rtl8365mb: refactor VLAN 4k handling Mieczyslaw Nalewaj
2026-11-17  7:39   ` [PATCH net-next v11 07/13] net: dsa: realtek: rtl8365mb: set and get vlan 4k for family D Mieczyslaw Nalewaj
2026-11-17  8:23     ` Linus Walleij
2026-11-18  1:48       ` Gustavo Foletto Mora
2026-11-18  7:59         ` Mieczyslaw Nalewaj
2026-11-19  1:47           ` Gustavo Foletto Mora
2026-11-19 22:36     ` netdev-bot+sashiko
2026-11-17  7:39   ` [PATCH net-next v11 08/13] net: dsa: realtek: rtl8365mb: refactor PVID handling Mieczyslaw Nalewaj
2026-11-17  8:34     ` Linus Walleij
2026-11-17  8:53       ` Mieczyslaw Nalewaj
2026-11-18  1:55     ` Gustavo Foletto Mora
2026-11-17  7:40   ` [PATCH net-next v11 09/13] net: dsa: realtek: rtl8365mb: use raw VID for PVID on family D Mieczyslaw Nalewaj
2026-11-18  2:00     ` Gustavo Foletto Mora
2026-11-19 22:36     ` netdev-bot+sashiko
2026-11-17  7:41   ` [PATCH net-next v11 10/13] net: dsa: realtek: rtl8365mb: add family D SDS13 PCS support Mieczyslaw Nalewaj
2026-11-19 22:36     ` netdev-bot+sashiko
2026-11-17  7:41   ` [PATCH net-next v11 11/13] net: dsa: realtek: rtl8365mb: refactor L2 MAC handling Mieczyslaw Nalewaj
2026-11-17  7:42   ` [PATCH net-next v11 12/13] net: dsa: realtek: rtl8365mb: make L2/LUT access work on family D Mieczyslaw Nalewaj
2026-11-19 22:36     ` netdev-bot+sashiko
2026-11-17  7:43   ` [PATCH net-next v11 13/13] net: dsa: realtek: rtl8365mb: add support for RTL8367S-VB Mieczyslaw Nalewaj
2026-11-19 22:36     ` netdev-bot+sashiko [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=179512779630.3136.16071397271955524893@kernel.org \
    --to=netdev-bot+sashiko@kernel.org \
    --cc=alvin.sipraga@analog.com \
    --cc=andrew@lunn.ch \
    --cc=contact@c127.dev \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=fabianotassotti@gmail.com \
    --cc=gabonpivovich@gmail.com \
    --cc=gusfmora@gmail.com \
    --cc=kuba@kernel.org \
    --cc=kuncy7@gmail.com \
    --cc=linusw@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=luizluca@gmail.com \
    --cc=maxime.chevallier@bootlin.com \
    --cc=namiltd@yahoo.com \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=pabeni@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox