🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #24303

Re: [PATCH] net: phy: motorcomm: add downshift tunable support for YT8531/YT8531S

#24303
From: chengke
Date: Mon, 30 Nov 2026 01:06
39 lines
10009 bytes
Hi,

Replying to the automated review of the v1 patch (the series was
restructured in v2; this is not a repost).

[High] .get_tunable/.set_tunable on the YT8531 entry

Legitimate, and already addressed in v2
(<20261125091638.1847020-2-mjkchengke@163.com>): the tunable support is
now scoped to the YT8531S entry only, which has .read_page and
.write_page (yt8521_read_page/yt8521_write_page), so the paged helpers
are safe there. The YT8531 entry was dropped from the series.

[Medium] raw UTP-space BMCR reset in yt8531s_set_downshift()

Legitimate concern; both sub-cases are real:

(a) forced link: unlike genphy_soft_reset(), the helper does not
    re-apply the forced speed/duplex settings after the reset, so a
    link forced with "ethtool -s ... autoneg off" would come back with
    autoneg enabled while phydev->autoneg still says AUTONEG_DISABLE.

(b) suspended: the reset clears BMCR_PDOWN while phydev->suspended
    stays set, powering the copper side back up behind phylib's back.

For reference, marvell's m88e1111_set_downshift() ends with
genphy_soft_reset(), which handles (a) via genphy_setup_forced() but
has the same exposure to (b).

Unless maintainers prefer otherwise, I plan to handle both in v3:
restore the forced settings after the commit reset when
phydev->autoneg == AUTONEG_DISABLE, and skip the commit reset with
-EBUSY when phydev->suspended is set.

pw-bot: cr

Thanks,
chengke
Technical Details
Message-ID: <20261130011500.1847020-1-mjkchengke@163.com>
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-373751-linux-kernel-netdev=dewy.ru
References: <20261125085509.1844883-1-mjkchengke@163.com> <179594341431.3146.13055685725510422390@kernel.org>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!newsfeed.bofh.team!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-373751-linux-kernel-netdev=dewy.ru
From: mjkchengke@163.com (chengke)
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH] net: phy: motorcomm: add downshift tunable support for YT8531/YT8531S
Date: Mon, 30 Nov 2026 09:06:21 +0800
Organization: Usenet Network
Message-ID: <20261130011500.1847020-1-mjkchengke@163.com>
References: <20261125085509.1844883-1-mjkchengke@163.com> <179594341431.3146.13055685725510422390@kernel.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 8bit
Injection-Info: usenet.network;
	logging-data="1299874"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:MBmK9/MCuNussey6ov2hVVJvQR4= sha256:R0e054ewvCtRyWTrbgH4aOYB0ZbvVzOj5gV+5D43iyo=
	sha1:o7X6ZGF7hjI1mXmp8Dt7jXnHUao= sha256:zJV3XeDVBD/berDzn7tJvXcCqTgtKSNugAOAPc2+h8I=
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 3F38E125FBB; Mon, 30 Nov 2026 04:07:36 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.148
X-Spam-Status: No, score=-3.148 tagged_above=-9999 required=6.31
	tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1,
	FREEMAIL_FORGED_FROMDOMAIN=0.001, FREEMAIL_FROM=0.001,
	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,
	UNPARSEABLE_RELAY=0.001] autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (1024-bit key)
	header.d=163.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 fPcER15Oh4pB;
	Mon, 30 Nov 2026 04:07:33 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.105.105.114; helo=tor.lore.kernel.org; envelope-from=netdev+bounces-373751-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=163.com
X-Received: from tor.lore.kernel.org (tor.lore.kernel.org [172.105.105.114])
	by mail.dewy.ru (Postfix) with ESMTPS id 107F4125FB8; Mon, 30 Nov 2026 04:07:22 +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 4C10523780; Mon, 30 Nov 2026 01:07:21 +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=1796000840;
	b=d342L9t2hP7wC63DWpe6V0bwt5UZcEQzSulWhiIJHJxAP/09hECL4siFGYkRVjS5PMnp
	 ocem+0/cqwGUZcGKMjeMJfOQGDNoK6NwPHn6K0DYoitd4m/sP0me6VVsZzXNsPJGfZceV
	 yvXNvIx1DQZqSJcS+6ka8DX5VVdiVNq4mWFKR7S2xR/IMUjwRrMijgJR64PAZxTOQZ4gf
	 Bo3seabkiu6evY0Muq+xh1xkH2UWeEup5cYSej1SZvN8Wg1gf6nkKF+WgTssJd5/6/D/O
	 Vra2T8NnMH76BYnLZAPHt8ImKsnUj1GmpS0Ybk3r6EoegMEsWbg0gRwDnO0eRw2LOUw==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1796000840;
	h=X-Original-To:Received:DMARC-Filter:DKIM-Signature:Received:From:To:
	 Cc:Subject:Date:Message-ID:X-Mailer:In-Reply-To:References:
	 X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe:
	 List-Unsubscribe:List-Owner:Precedence:MIME-Version:Content-Type:
	 Content-Transfer-Encoding:X-CM-TRANSID:X-Coremail-Antispam:
	 X-CM-SenderInfo;
	bh=dy/7RK2OJ1tDJpo1gZHr6XLhf3ha2NwR/nqmhzONTnY=;
	b=oQSxeOvEQEQ6wsUSG+Zq10uluMKYMl4JoPw3i6dWyhAM2ioaaHuoZ/oKxovu/qhizuK/
	 4WYEJQxeDFSycC6inegb85Q/SzsDRK8I6WTi8JJiNAmjW268bhXIXyaiXxvB5qs2xUBEJ
	 VUdghyZquas1oFTe3+IMvPGTVPexRF6ceTND7um/Po++W6aaMire5mEoM1CqIEQhZ+jUi
	 jErTYvtbB4M+HtgcB/GDKKFrgwgXkwjdjFeJgipCWNxgjlXD9w5M6P9fX2aCSq8eZUcx0
	 XIQvojQ4ZMNLqURqxgn5hzhsgMVwxPE5DSxF28hulAglFnM7m2PjCpK5BonabVbJQoA==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=163.com header.i=@163.com header.a=rsa-sha256 header.s=s110527 header.b=ZJZf9RWl;
	dmarc=pass header.from=163.com;
	spf=pass smtp.mailfrom=163.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 68108606A336;
	Mon, 30 Nov 2026 01:07:20 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (1024-bit key) header.d=163.com header.i=@163.com header.a=rsa-sha256 header.s=s110527 header.b=ZJZf9RWl
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=220.197.31.5
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1796000839;
	b=Q29KYDq86M0koGZDIX9sZilFjPesH/eO8Zt9mpKKtIKfyjDaUYJwtMSytV5Zzt1M2U/j
	 t+DzSD5qz+C/5Kjpu74SW8MqKbXpOy9ZTPU8DAVyQqASTdXIbi92OBHaIc9sECUwL+jbF
	 CvUFujHG0RGSgO3xizBnlT4usDGNrp4Y7DE7rPAb1yNgr0+XT+myeR6qIZZUNXYg0wr12
	 ablxqUqOsy+YzvkPc0vdUh9Bml+KI9tH87JUyxkkr4lkIXztcZTCGy/6Q8pTvBgs0/3sd
	 AIghZWFMAK1K808oEcVWiMrmSLPv3kxX/xzrsXzGmuvVW0+O+cXtxxpAcorjx8vOn+Q==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1796000839;
	h=DMARC-Filter:DKIM-Signature:Received:From:To:Cc:Subject:Date:
	 Message-ID:X-Mailer:In-Reply-To:References:MIME-Version:Content-Type:
	 Content-Transfer-Encoding:X-CM-TRANSID:X-Coremail-Antispam:
	 X-CM-SenderInfo;
	bh=dy/7RK2OJ1tDJpo1gZHr6XLhf3ha2NwR/nqmhzONTnY=;
	b=XH1XjRzvpmGJP6XJ96KXK5QoQpx4qIkcaxedI6rxXbF76E9YsecM6eUGWTxrMihstx48
	 izTSdr2t3tCPpPmuZz8Gd21hiEZ719cL1EQdFqhA3VD+VMoGX5MMEqn+wZr010PtdSCjH
	 QHeVQ1ReU5GVNGhEwnLYELj8Nz/dsZJXd1V1rkwrdczt0+xJpWgjkuoHbmt57qtkSavNE
	 OpC2MZlZE/Wn+BhYbFhPpFpjN865FdbTkpmQvacIDkFFf4z3EhsFTF1NU2P/t5RuJavDa
	 rLJTg9YbodrBoqKSvf8tLX1kus81Z2YyoQiRf2UrxXqaz57F2/rhdn0w2c59rEupJhA==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dmarc=pass header.from=163.com;
	spf=pass smtp.mailfrom=163.com;
	dkim=pass header.d=163.com header.i=@163.com header.a=rsa-sha256 header.s=s110527 header.b=ZJZf9RWl;
	arc=none smtp.remote-ip=220.197.31.5
X-Received: from m16.mail.163.com (m16.mail.163.com [220.197.31.5])
	(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 D1A20606A325
	for <netdev@vger.kernel.org>; Mon, 30 Nov 2026 01:07:17 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org D1A20606A325
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=163.com
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=163.com
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=163.com;
	s=s110527; h=From:To:Subject:Date:Message-ID:MIME-Version:
	Content-Type; bh=dy/7RK2OJ1tDJpo1gZHr6XLhf3ha2NwR/nqmhzONTnY=;
	b=ZJZf9RWlA+ge7ejwrn5HQ5XDQNhVZpLxZLkMRbRcZvIuk/kI4tmWmPOlmUiHZS
	3HLLoRZbksULGWgtgNkVd6QjnmMvGDNDd0/ImC8bcc/U4n7QCUAQ3iGq+4wo7Cxy
	9vPRUwLb2LLgDj0uDoUJ86MPVHPmDVtWcq34rIZIvdKcc=
X-Received: from ck.. (unknown [])
	by gzga-smtp-mtada-g1-4 (Coremail) with SMTP id _____wCHTs4NzAxr8RbJKw--.15750S2;
	Mon, 30 Nov 2026 09:06:21 +0800 (CST)
X-Cc: Frank.Sae@motor-comm.com,
	netdev@vger.kernel.org,
	andrew@lunn.ch,
	hkallweit1@gmail.com,
	linux@armlinux.org.uk,
	davem@davemloft.net,
	edumazet@google.com,
	kuba@kernel.org,
	pabeni@redhat.com,
	mjkchengke@163.com
X-Mailer: git-send-email 2.43.0
X-In-Reply-To: <179594341431.3146.13055685725510422390@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-CM-TRANSID: _____wCHTs4NzAxr8RbJKw--.15750S2
X-Coremail-Antispam: 1Uf129KBjvJXoW7tr47Cr4xCF1kCw1rWF1kuFg_yoW8Gw47pa
	yY9FWjvFykCryDtan7Xw4DAa4Uur4SkF4Yyr98Ga4fAw15ZF1Syr42qFnIyrWqkrs5C3y5
	GrsIqFy8ZFs8KFDanT9S1TB71UUUUU7qnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2
	9KBjDUYxBIdaVFxhVjvjDU0xZFpf9x0JU7Ma8UUUUU=
X-CM-SenderInfo: ppmnux5hqjyvi6rwjhhfrp/xtbC9g4UYmsMzA4wdwAA3s