🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #18517

Re: [PATCH net-next v4 2/2] net: dsa: mxl-gsw1xx: reset the switch through reset-gpios

#18517
From: Daniel Golle
Date: Wed, 18 Nov 2026 13:07
34 lines
9128 bytes
On Sun, Nov 15, 2026 at 05:33:46PM -0500, Joseph Telaak via B4 Relay wrote:
> From: Joseph Telaak <joseph@telaak.dev>
> 
> The switch keeps the configuration the bootloader left in it, and the
> driver never resets it. The MDIO core asserts and releases reset-gpios
> only for PHY devices, so a reset line described on the switch node has
> no effect either.
> 
> On the GL.iNet GL-SFT1200, nothing answers at internal MDIO address 0
> after the bootloader, and the PHY that answers at each port's address
> belongs to the neighboring port, so port 0 fails with "failed to
> connect to PHY: -ENODEV". Describing the PHYs at the addresses they
> answer at is not enough: with them at 1 to 3 and no reset, neither LAN
> port passes traffic. After a hardware reset every PHY is back at its
> port's address and all ports work. GL.iNet's own firmware resets the
> switch from Linux too.
> 
> Get the reset through the reset controller API and pulse it before the
> first register access. The reset core hands a reset-gpios property to
> the reset-gpio driver, so a board that wires the reset this way needs
> CONFIG_RESET_GPIO; without it the reset is skipped. Imply it, so it is
> enabled by default, and say so in the help text. The timing follows the
> vendor's driver for the GSW150: asserted for 250 ms, then 1 s before the
> switch is accessed. No timing is known for the other GSW1xx parts, so
> they get the same.
> 
> The reset also returns the RGMII slew rates to their power-on defaults,
> so a board that uses reset-gpios sets the ones it needs in its device
> tree.
> 
> Signed-off-by: Joseph Telaak <joseph@telaak.dev>

Reviewed-by: Daniel Golle <daniel@makrotopia.org>
Technical Details
Message-ID: <av2jBEtrEq96xV2-@makrotopia.org>
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-366130-linux-kernel-netdev=dewy.ru
References: <20261115-mxl-gsw1xx-reset-v4-0-4ecd18c922e2@telaak.dev> <20261115-mxl-gsw1xx-reset-v4-2-4ecd18c922e2@telaak.dev>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-366130-linux-kernel-netdev=dewy.ru
From: daniel@makrotopia.org (Daniel Golle)
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH net-next v4 2/2] net: dsa: mxl-gsw1xx: reset the switch
 through reset-gpios
Date: Wed, 18 Nov 2026 13:07:16 +0000
Organization: Usenet Network
Message-ID: <av2jBEtrEq96xV2-@makrotopia.org>
References: <20261115-mxl-gsw1xx-reset-v4-0-4ecd18c922e2@telaak.dev>
 <20261115-mxl-gsw1xx-reset-v4-2-4ecd18c922e2@telaak.dev>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Injection-Info: usenet.network;
	logging-data="2599984"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:BJizXPWEcPgZV7Pa3OiTxOw4hEs= sha256:OylGeqbxoAikn1jK7M7a0m9UqvBJEvDw53ipGtIsEdI=
	sha1:ZbJmXjH60Dte31PthjOD9loxJXM= sha256:4AaU3vKjblzEpbJGo841Eotbbx679B8TdmuuHfbbDyg=
Content-Disposition: inline
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 B1039115286; Wed, 18 Nov 2026 16:08:03 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.051
X-Spam-Status: No, score=-3.051 tagged_above=-9999 required=6.31
	tests=[HEADER_FROM_DIFFERENT_DOMAINS=0.249, MAILING_LIST_MULTI=-1,
	RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-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 Z8MNRWtoUe5V;
	Wed, 18 Nov 2026 16:07:56 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.232.135.74; helo=sto.lore.kernel.org; envelope-from=netdev+bounces-366130-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=none (p=none dis=none) header.from=makrotopia.org
X-Received: from sto.lore.kernel.org (sto.lore.kernel.org [172.232.135.74])
	by mail.dewy.ru (Postfix) with ESMTPS id 4ED5B11528D; Wed, 18 Nov 2026 16:07:49 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sto.lore.kernel.org (Postfix) with ESMTP id 2F79360B079; Wed, 18 Nov 2026 13:07:47 +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=1795007263;
	b=L8HaoB31RG5ncyf/2eacIVxvMQ+Jh8FIGsmAUY3HpvC60Pt1NWhGndanT3MGwGdWjaZZ
	 m7gwuJpHGHYCF2asiBy57bsaelGFJ813WVjNoMNZFOvpoPB8jQd/iJG5uRC6Qzp9PN0sM
	 4bdwIV6FQNk+EUjr0/qXDC+7dAltm1qlghPAjmGq3Wz6FJGIuH4xFyxO/+7Dp1ITn7n4F
	 bJ5BwulmX5QN1k0WWZcmMoe6sos6tVqDjtcoYgnhxCtqz2fJb+xrqK2RrFWZvWD7Hrjse
	 CCYTM56l7/l0xUgZagBu3Cl/IcJ31j/zzUQ9+vK69xLSe5N6B0B3MscZeAlbFy6/ygw==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1795007263;
	h=X-Original-To:Received:DMARC-Filter:Received:Date:From:To:Cc:Subject:
	 Message-ID:References:X-Mailing-List:List-Id:List-Post:List-Help:
	 List-Subscribe:List-Unsubscribe:List-Owner:Precedence:MIME-Version:
	 Content-Type:Content-Disposition:In-Reply-To;
	bh=RKlNE273qsLLyD+9WVGHZwPIwnj09V8yBbpoARQKCtU=;
	b=K3gU/vLS8KKNkJPyBVICNI6V1NLtU1VcbQxLJRicuNruu3i0zn7hsCdorEltI+arFFqV
	 rBEOB0Houc1bIuw9/3EfIEVyEdc/JUSzWGC/NXYeierXIQXSht8uzdIQPAuhd/6OPD9Z6
	 X1SYQAWUvvVNybvTsD5yeE8VyVf2CWJq+jIi2LOgENxQbFhhXzpnXvbFj1cU9JI9RUzjt
	 bojKbIpN+xi0kxlgHUk9G+Fl4qBe8xUqjvvV52NP9YL3a3s0FVIIkZ5u3DhLlHe7WFxnW
	 HKMB9abnrvO2w1BPexO283fd/37zwjMiM+39nFls+mkijQdjyhF+ghvZ/PDK+hhoSgQ==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dmarc=none header.from=makrotopia.org;
	spf=pass smtp.mailfrom=makrotopia.org;
	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 0711660A2606;
	Wed, 18 Nov 2026 13:07:43 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=185.142.180.65
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1795007262;
	b=xma/Y2/aYRpII01BWgk+An0Ly9HAbNtxbE0B4n3F/+9462n2n7kvcwzAcGA1j5skU46F
	 2FQuiS1FJgXTyWzle7FNgAxo5LJmWZXfCL9mtMOucM3vNOFuplQYEeBNPfrfQGxx0GqZK
	 ZAZTuQYTVZh6fNyOrfxMXRYyZFWGlJmJvPtcT4jaRXUqy7JBh5JeN6RAkp3BH9mQv4WmO
	 lC4w3DL/Hx73ziVFXbxZk3SLhRLZgo9OwzuxU8iOa3rCWFH85IgObuBpw0gIeyem27Pub
	 7gtiPkcafAdheUResqGllUgUtUDjCm5e5emOMXlAPF1PPaQjorYEj7ozzp0SDtnJDJQ==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1795007262;
	h=DMARC-Filter:Received:Date:From:To:Cc:Subject:Message-ID:References:
	 MIME-Version:Content-Type:Content-Disposition:In-Reply-To;
	bh=RKlNE273qsLLyD+9WVGHZwPIwnj09V8yBbpoARQKCtU=;
	b=sIIdjLuFVlH7nOzzxGoQvxKq810zPUH/i4lRxVZ3wq5wFF/C5Xg9M2/PHChJrSgOxVwK
	 oJqJ34+SNKP1qQAwoKziuiyn8HLCShwMb0ryOOm0J/FiVSyeSV/PBNMy6xyyzOwu9ngD4
	 Bxvukr1K5t4mXkuhl+R9APnXCuNOUb6i1joeTtYZ/OqIHwQIOrhAqnvw/0Nq3syySj+CF
	 2SQbqKpfGuW7xoXMNQkm4x0G9IgHWtDbZmys+5TW4IPFfKjOWMHxigpOT/Eud1096vS+o
	 2vGo5b/4c1nMlduLmOP1LP7AdRKI5U3gUWK8UAwCAjVJvt2FoddtTtIhAjjpKExSyBg==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dmarc=none header.from=makrotopia.org;
	spf=pass smtp.mailfrom=makrotopia.org;
	arc=none smtp.remote-ip=185.142.180.65
X-Received: from pidgin.makrotopia.org (pidgin.makrotopia.org [185.142.180.65])
	(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 E9A97606A338;
	Wed, 18 Nov 2026 13:07:41 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org E9A97606A338
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=makrotopia.org
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=makrotopia.org
X-Received: from local
	by pidgin.makrotopia.org with esmtpsa (TLS1.3:TLS_AES_256_GCM_SHA384:256:X25519MLKEM768)
	 (Exim 4.100.1)
	(envelope-from <daniel@makrotopia.org>)
	id 1xTfNm-000000004Qx-3Wtz;
	Wed, 18 Nov 2026 13:07:27 +0000
X-Cc: Hauke Mehrtens <hauke@hauke-m.de>, Andrew Lunn <andrew@lunn.ch>,
	Vladimir Oltean <olteanv@gmail.com>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@kernel.org>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Rob Herring <robh@kernel.org>,
	Krzysztof Kozlowski <krzk+dt@kernel.org>,
	Conor Dooley <conor+dt@kernel.org>,
	Philipp Zabel <p.zabel@pengutronix.de>, netdev@vger.kernel.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
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-In-Reply-To: <20261115-mxl-gsw1xx-reset-v4-2-4ecd18c922e2@telaak.dev>