🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #19015

RE: [PATCH net-next v8 10/11] r8152: add TGPHY register access for RTL8157 and RTL8159

#19015
From: Chih Kai Hsu
Date: Thu, 19 Nov 2026 07:18
21 lines
11668 bytes
On 19/11/2026 12:42 pm, Birger Koblitz wrote:
> On 18/11/2026 2:42 pm, Andrew Lunn wrote:
> >> I plan to add two new functions, rtl_nway_restart() and
> >> rtl8152_get_link_ksettings, to replace mii_nway_restart() and
> mii_ethtool_get_link_ksettings, respectively.
> >
> > Ideally, you should port this driver to phylink.
> >
> >        Andrew
> 
> Indeed, all of the (integrated) PHYs on the adapters supporeted by r8152 I
> looked at are already supported under drivers/net/phy/realtek/ It should be
> straight-forward with many immediate benefits.
> 
> Birger

I agree that a phylink conversion is a better long-term direction. I'd like to
keep it out of this series. This series fixes and completes the existing RTL8157/59
support. The phylink conversion is a larger change. r8152 has no MDIO bus and 
accesses PHY through OCP registers, and the MAC code also does PHY configuration,
firmware patching, UPS and EEE handling that would need to move or coexist with
the phylib drivers. The two helpers here are self-contained and will be removed by
the phylink port.

Best Regards,
Chih-Kai

Technical Details
Message-ID: <b53ecd5dc96f4890956f051959b74e32@realtek.com>
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-366806-linux-kernel-netdev=dewy.ru
References: <20261110032416.16968-11-nic_swsd@realtek.com> <179464851836.2199510.10154643847175029122@kernel.org> <0c6318e175b14ce8b86a957c7c79d5db@realtek.com> <cafe3b8f-2b65-41d6-b31d-a1cabbf93720@lunn.ch> <2e601d9c-1271-4802-a45c-a16a0d9cfa8d@birger-koblitz.de>

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-366806-linux-kernel-netdev=dewy.ru
From: hsu.chih.kai@realtek.com (Chih Kai Hsu)
Newsgroups: linux.kernel.netdev
Subject: RE: [PATCH net-next v8 10/11] r8152: add TGPHY register access for
 RTL8157 and RTL8159
Date: Thu, 19 Nov 2026 07:18:16 +0000
Organization: Usenet Network
Message-ID: <b53ecd5dc96f4890956f051959b74e32@realtek.com>
References: <20261110032416.16968-11-nic_swsd@realtek.com>
 <179464851836.2199510.10154643847175029122@kernel.org>
 <0c6318e175b14ce8b86a957c7c79d5db@realtek.com>
 <cafe3b8f-2b65-41d6-b31d-a1cabbf93720@lunn.ch>
 <2e601d9c-1271-4802-a45c-a16a0d9cfa8d@birger-koblitz.de>
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: base64
Injection-Info: usenet.network;
	logging-data="2816146"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:31E+WKMZnEcCuHtAJ+FsjkVa34s= sha256:SAAOhIUoamgtE55Mvgm3sK5iKOqpizUIKWm400xEo/Q=
	sha1:PAJbMSj1iH76enoW6mpU5eeJzJg= sha256:ZRNnaxy+nB9GZ6fuAV+0PoAMayLoD5qCMQZs5kNa7iM=
Content-Language: zh-TW
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 25C1F115540; Thu, 19 Nov 2026 10:19:13 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.05
X-Spam-Status: No, score=-3.05 tagged_above=-9999 required=6.31
	tests=[DCC_REPUT_70_89=0.1, DKIM_SIGNED=0.1, DKIM_VALID=-0.1,
	DKIM_VALID_AU=-0.1, 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, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key)
	header.d=realtek.com
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 bU7bkApnheFh;
	Thu, 19 Nov 2026 10:19:10 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.105.105.114; helo=tor.lore.kernel.org; envelope-from=netdev+bounces-366806-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=realtek.com
X-Received: from tor.lore.kernel.org (tor.lore.kernel.org [172.105.105.114])
	by mail.dewy.ru (Postfix) with ESMTPS id DDFFA11553B; Thu, 19 Nov 2026 10:19:01 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by tor.lore.kernel.org (Postfix) with ESMTP id 3D76A1270C6; Thu, 19 Nov 2026 07:18:59 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=fail;
	t=1795072735;
	b=dpPi1+tjIqXTrhONQD8u8PxofIvDoAm4WyesJF0OrM9i3h5vKV1zS1hhudxc7h5PB7Wr
	 CSZwNFtLmaTAO/VQAy2V2ATxiAto491uWO7ot97Qq8pmZqsPAhZGBP/9GglG6armq2JPM
	 Pw6IEVkLMeFKmi5rbGomLD5WBWXES07diAXi5s4yp7qnclffds9ilXzkn/MQ//neYcpnX
	 9ZgYuS+cBtfNTkMhB6vZfhEwu/YGwywHWy/45njpd6JVzA2OMCAPsol//2oxy+e5jpOqG
	 P8Ikcua3tSiU5szWF79M7W+dxJqsEHrY0wQAez6h1XhMOGl1Pz5NlD2f5Q9Aqo49m9Q==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1795072735;
	h=X-Original-To:Received:DMARC-Filter:X-SpamFilter-By:DKIM-Signature:
	 Received:Received:Received:Received:From:To:CC:Subject:Thread-Topic:
	 Thread-Index:Date:Message-ID:References:In-Reply-To:Accept-Language:
	 Content-Language:Content-Type:Content-Transfer-Encoding:
	 X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe:
	 List-Unsubscribe:List-Owner:Precedence:MIME-Version;
	bh=n+LVyi43MxsRwsz1nrwE1G07r0INc4jpFn7KaXglckw=;
	b=Ln51PXKJjlqGblN+PvwzqqZsz5WqRdpAMhXkml2X5ExDNV4y9cRoLRD4unBY9CykfW5E
	 oRHColYhxZ96WhRAFl4rO9wZDHAVpTuMIZNcfNU8btki3DutzXS++DSJuGOLesw2/ta/k
	 xZ2/RsOVuoGcVkDKgMwHeWvIiu/vSa/298RT+6p4taHDaVPyRJd4z+d0UHvEAyF6oNIs4
	 9RbNP/ibyHdYr+5KjAPlXoL3a7NNt2qw/1QosPj1GzBoW2F2WeFx4Okv5yfC+PYNW4PmU
	 5aU/1WJiBJe6cJiFK4TD6O+Wk3t8GSzS+dXY9K5kiJ+lZpkP+GlUAA7Pig1lPZFNZPg==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=realtek.com header.i=@realtek.com header.a=rsa-sha256 header.s=dkim header.b=mJRWAuQw;
	dmarc=pass header.from=realtek.com;
	spf=pass smtp.mailfrom=realtek.com;
	arc=fail 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 B1D70606A335;
	Thu, 19 Nov 2026 07:18:55 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (2048-bit key) header.d=realtek.com header.i=@realtek.com header.a=rsa-sha256 header.s=dkim header.b=mJRWAuQw
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=211.75.126.72
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1795072734;
	b=bcuHQ6n5pxVeRl4eWHZ8avzslsdumusy2DXNhxfFJtpF3AD+pt5xKerGmueocGNi2ykU
	 ZAsYtXHyOvzL4E6GevbnhVjh6uEgmfGu/L+2Z0UZ2jQkz7zqD4JJe+ci7j8bACeP9syCa
	 nDpod6yCyWThnMOal4OklH91gKpuvy9/Dtk1+Zfn5xYNsNtCWeTYHM90OGVoXCTdK1WPv
	 DU0ufHHseEAUjNI+dJNCaaznXBXAqxgrFQ+4IOYhXOJu4rYQULd5H+u5bcr6oofCCHC/b
	 Dc+66+6EF8M/JhVNW8wsUSr+NK4bqjvxVO1Kt61lGLXob18o1p13qARos8onAtedOzA==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1795072734;
	h=DMARC-Filter:X-SpamFilter-By:DKIM-Signature:Received:Received:
	 Received:Received:From:To:CC:Subject:Thread-Topic:Thread-Index:Date:
	 Message-ID:References:In-Reply-To:Accept-Language:Content-Language:
	 x-originating-ip:Content-Type:Content-Transfer-Encoding:MIME-Version;
	bh=n+LVyi43MxsRwsz1nrwE1G07r0INc4jpFn7KaXglckw=;
	b=AllwfPGZcvLgYD2h4UZarTDIlzq+I+AgwnS7TB5DWAxC8WSSHwbD1GAD/LQM6SB82UAR
	 oqzoJS/3b2mhXKZnArqgfZVz5d9UtXH7ioO8pphSigWjnskaCsbBdzS6jP54WgMOzvUUf
	 l0yZSYLc3gpLgRUXmUaNM3yPwdyP6Iy3LZZ4lRLP8FKtbJfs3CZn0Q8HxXhfDnU7PEzfn
	 i+MfesXKJKAzl/g71429uoMIXom6Q1bKJJmfAvjknBvuA84jJSEYca+l0ttSLLVfLTfWF
	 fxlBxMR7y7OcBIlGl6MRR6dqYHxjm6XvTpEPl/HD2mD/Vna31F91xpYoeq69k6BAdhA==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dmarc=pass header.from=realtek.com;
	spf=pass smtp.mailfrom=realtek.com;
	dkim=pass header.d=realtek.com header.i=@realtek.com header.a=rsa-sha256 header.s=dkim header.b=mJRWAuQw;
	arc=none smtp.remote-ip=211.75.126.72
X-Received: from rtits2.realtek.com.tw (rtits2.realtek.com [211.75.126.72])
	(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 3F004606A320;
	Thu, 19 Nov 2026 07:18:53 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 3F004606A320
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=realtek.com
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=realtek.com
X-SpamFilter-By: ArmorX SpamTrap 5.80 with qID 6AJ7IGseC2103056, This message is accepted by code: ctloc85258
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=realtek.com; s=dkim;
	t=1795072696; bh=n+LVyi43MxsRwsz1nrwE1G07r0INc4jpFn7KaXglckw=;
	h=From:To:CC:Subject:Date:Message-ID:References:In-Reply-To:
	 Content-Type:Content-Transfer-Encoding:MIME-Version;
	b=mJRWAuQwDoiYaOeMcVQfyEoW6nR4WXrnyzB/C49aHSwvvVsQ8pzB4EZVlxPEJmNcw
	 agxBylEBH7If3AHlfnI97RG3iLPO+RvyrX+SvkYj5zfWyIo1RVZhZsRfjXPYzlbHdf
	 /ogwb9UQuUhHSrGk0cqQmqmVo1h1vqhGZbTH/VJm7uBbVBKd1Ow86STKWuNVS57YrK
	 2fmLTOQPaFsPmJggPhzuZGi+rcBC19KAuSc9BciIc6Jbe6tUlgoM7psd+3rGp1HMR6
	 CLsG47vOIlRk+L1vRMkbBzlnAEBlUQdJFmlNnqhTZGnVHr5UJaxgjFT7OKTULxrTSG
	 /IPuIXZNmmWyw==
X-Received: from mail.realtek.com (rtkexhmbs02.realtek.com.tw[172.21.6.41])
	by rtits2.realtek.com.tw (8.15.2/3.29/5.94) with ESMTPS id 6AJ7IGseC2103056
	(version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL);
	Thu, 19 Nov 2026 15:18:16 +0800
X-Received: from RTKEXHMBS01.realtek.com.tw (172.21.6.40) by
 RTKEXHMBS02.realtek.com.tw (172.21.6.41) with Microsoft SMTP Server
 (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id
 15.2.2562.56; Thu, 19 Nov 2026 15:18:17 +0800
X-Received: from RTKEXHMBS06.realtek.com.tw (10.21.1.56) by
 RTKEXHMBS01.realtek.com.tw (172.21.6.40) with Microsoft SMTP Server
 (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id
 15.2.2562.56; Thu, 19 Nov 2026 15:18:16 +0800
X-Received: from RTKEXHMBS06.realtek.com.tw ([fe80::eeeb:c765:ca73:5eef]) by
 RTKEXHMBS06.realtek.com.tw ([fe80::eeeb:c765:ca73:5eef%10]) with mapi id
 15.02.2562.056; Thu, 19 Nov 2026 15:18:16 +0800
X-CC: "netdev-bot+sashiko@kernel.org" <netdev-bot+sashiko@kernel.org>,
	"davem@davemloft.net" <davem@davemloft.net>, "kuba@kernel.org"
	<kuba@kernel.org>, "netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	nic_swsd <nic_swsd@realtek.com>, "linux-kernel@vger.kernel.org"
	<linux-kernel@vger.kernel.org>, "linux-usb@vger.kernel.org"
	<linux-usb@vger.kernel.org>, "edumazet@google.com" <edumazet@google.com>,
	"bjorn@mork.no" <bjorn@mork.no>, "pabeni@redhat.com" <pabeni@redhat.com>,
	"andrew+netdev@lunn.ch" <andrew+netdev@lunn.ch>
X-Thread-Topic: [PATCH net-next v8 10/11] r8152: add TGPHY register access for
 RTL8157 and RTL8159
X-Thread-Index: AQHdcMMAVp0iERnuiECMnOxwgdqzp7cszWwAgAbBatD//87JAIAAMkyAgAF2UFA=
X-In-Reply-To: <2e601d9c-1271-4802-a45c-a16a0d9cfa8d@birger-koblitz.de>
X-Accept-Language: zh-TW, en-US
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