🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #16014

Re: [PATCH net-next 2/3] net: phy: dap8211r: add extended register write helper

#16014
From: Andrew Lunn
Date: Fri, 13 Nov 2026 20:28
15 lines
8693 bytes
> + * The caller must hold the MDIO bus lock.
> + *
> + * Return: 0 on success, or negative error code
> + */
> +static int dap8211r_write_ext(struct phy_device *phydev, u16 reg, u16 data)
> +{
> +	int ret;
> +
> +	phy_lock_mdio_bus(phydev);

How does this not deadlock, if the caller is already holding the MDIO
bus lock, as commented on above?

	Andrew
Technical Details
Message-ID: <583c58dd-3587-4c2f-af5b-9b4a10fd916c@lunn.ch>
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-362902-linux-kernel-netdev=dewy.ru
References: <20261113110546.173624-1-a.shimko.dev@gmail.com> <20261113110546.173624-3-a.shimko.dev@gmail.com>

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-362902-linux-kernel-netdev=dewy.ru
From: andrew@lunn.ch (Andrew Lunn)
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH net-next 2/3] net: phy: dap8211r: add extended register
 write helper
Date: Fri, 13 Nov 2026 21:28:15 +0100
Organization: Usenet Network
Message-ID: <583c58dd-3587-4c2f-af5b-9b4a10fd916c@lunn.ch>
References: <20261113110546.173624-1-a.shimko.dev@gmail.com>
 <20261113110546.173624-3-a.shimko.dev@gmail.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Injection-Info: usenet.network;
	logging-data="1449149"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:CFJ8mXgvYZVXH5unPsKYA5dW38k= sha256:3xlT7URDADEvKtJ98LxcfJLaTOi/umhHo1tQpsxIjXE=
	sha1:vtKqsZs/P+QuljIgXQsQ/SJaoKU= sha256:T8OXkPMqOZ9zIQJ1Zwi+nBMa0Pn7IOE3KmUWd2rraU4=
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 DF4D41146B8; Sat, 14 Nov 2026 00:56:50 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -1.951
X-Spam-Status: No, score=-1.951 tagged_above=-9999 required=6.31
	tests=[DCC_CHECK=1.1, 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]
	autolearn=ham autolearn_force=no
X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (1024-bit key)
	header.d=lunn.ch
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 j-3OsaXK6EVc;
	Sat, 14 Nov 2026 00:56:47 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-362902-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=lunn.ch
X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10])
	by mail.dewy.ru (Postfix) with ESMTPS id 3E4A4114636; Sat, 14 Nov 2026 00:56:39 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sea.lore.kernel.org (Postfix) with ESMTP id 2EF80203B97; Fri, 13 Nov 2026 20:28:36 +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=1794601715;
	b=QS9+QUevN2MZmO/sbCEdZnfLZINLBdCNBPssnomhsRQIdHKUwS2C7AQr4hK5ghlTUCR5
	 IlxxiJpht1DxYIQaRpBOU6WWUkEjAW2ZebRK/j5t7Uvhz50f6nyDE6fbLnG/FrtJSy6x+
	 FXBSwwISSS90PTLMAImm1zgd10qOcl6JdZ2d3cT3B9VAfDR+ZbrQxQ8aZ1QoupjQ5dK2C
	 aQzyfZ8EJxRxINlcTadMI3/Ex+erAnL7ZU2VPWZcFkdP28UqN8SM0YpOQNgaXlxBP4lMG
	 nETxrJAPru4igJz31LSNre/2V2sdnx6oV91rxueEejRzInKhFCm4wxhhW+OUH6nEKdQ==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794601715;
	h=X-Original-To:Received:DMARC-Filter:DKIM-Signature: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=gaD+xb7cU1GGj4SMRBCAddtYxjohBzdn3/H4c3ybKBg=;
	b=C5qHS2X2gvslyftcyeRj+s/7KLSTdBp19QX4nD/5M8WD75IPawdai6+orYo/lhpUdh+k
	 Kwbk+DqwYz3GfdCj9ZQhHs5nQLx9GBU2Z39sweaqEjZpsr/yT2HqOhG7hjFgBI2MG0zWx
	 xM+M6Ddo+TQQiECivI+jNTZbVUm1jiypvi3sndKTRMFTSm3+qPjAT5iak+Y1xBAFB5c78
	 y9NV7b8c+roya63T2JpV9zSyeR/6x9IY7KVXKY0bnda0ZSI2wFV+O0QyXHs88jxAVsF2i
	 1KunOZOVneXehDTBPwfeto5K8k2CEBuTDPxjZLyrFdvdxk+pnH6P6wDjuyFh/wo7PVA==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=lunn.ch header.i=@lunn.ch header.a=rsa-sha256 header.s=20171124 header.b=RZ51UcpA;
	dmarc=pass header.from=lunn.ch;
	spf=pass smtp.mailfrom=lunn.ch;
	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 14543606A33A;
	Fri, 13 Nov 2026 20:28:35 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (1024-bit key) header.d=lunn.ch header.i=@lunn.ch header.a=rsa-sha256 header.s=20171124 header.b=RZ51UcpA
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=156.67.10.101
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1794601714;
	b=jIx+Hpr4ATdXK9B77KtjWtoCD1vZ9LFaaGSVyoqX3VTEHMNvwzdRy7sS1cBWr1XD3GzK
	 Q8NSwRVohiQRkI4BxVHgyF+k1eFRxkJYZiFh1SE0+guXW8gI0nTpD2c4KcAIfEAqL2NzN
	 XNLSpEAOG+ppwm7FzXMORHNm1HHBj7QCsIvBJWhn6bd4b5PrAnESgRR/maa5StwgeI3Al
	 GGyM8hH8fwsUWazYnImfaHvd1OCcFBhuvmIu5oz3NigKm6gOMIRsw5O6ntMd3MfM/dyq6
	 ny0dXeBCrxyvHBMRMeMOawcOVt6uHrW8NN+kVb32fQj9uMyKTfP8kpBCsUsOHnr8fFQ==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794601714;
	h=DMARC-Filter:DKIM-Signature:Received:Date:From:To:Cc:Subject:
	 Message-ID:References:MIME-Version:Content-Type:Content-Disposition:
	 In-Reply-To;
	bh=gaD+xb7cU1GGj4SMRBCAddtYxjohBzdn3/H4c3ybKBg=;
	b=FlmgdSlgrQfMSXhDGi5ULBl8E/wcSpVwdjK09HkqPf4h1ssKwJJBDnuOaw8LIb4e/sbC
	 lEosjm3bG7fLbG6zf1a0LX6VVU23opSW5GjGo8UFGoHSMjfx3HpWskkVO4yAAihNCF2Aa
	 RbKxjjRdMRuLxsxKEMQRcqcHh47gc3sYmVjf0OFMdelNspUNVgd2xLlJdeV4zi4PT6SHx
	 8Z1ttVB2cVGTJNSKqw7vhmOsIwPrshUNgmPpQXu7x6kAdezj7fhDEyqK0pkT4G6GXVsUN
	 vEgpoigEy9jfnnZ70HKkqds7awTVxtZN63rIIkmX57tXXwO1tFaomwhgV12xZAP7+mw==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dmarc=pass header.from=lunn.ch;
	spf=pass smtp.mailfrom=lunn.ch;
	dkim=pass header.d=lunn.ch header.i=@lunn.ch header.a=rsa-sha256 header.s=20171124 header.b=RZ51UcpA;
	arc=none smtp.remote-ip=156.67.10.101
X-Received: from vps0.lunn.ch (vps0.lunn.ch [156.67.10.101])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange ECDHE (prime256v1) server-signature ECDSA (prime256v1) server-digest SHA256)
	(No client certificate requested)
	by smtp.subspace.kernel.org (Postfix) with ESMTPS id BB594606A323;
	Fri, 13 Nov 2026 20:28:33 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org BB594606A323
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lunn.ch
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lunn.ch
X-DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch;
	s=20171124; h=In-Reply-To:Content-Disposition:Content-Type:MIME-Version:
	References:Message-ID:Subject:Cc:To:From:Date:From:Sender:Reply-To:Subject:
	Date:Message-ID:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding:
	Content-ID:Content-Description:Content-Disposition:In-Reply-To:References;
	bh=gaD+xb7cU1GGj4SMRBCAddtYxjohBzdn3/H4c3ybKBg=; b=RZ51UcpAhDfFYthIQyaCqUG+Si
	EEZBY3IKu+hb02QW5rh1a2hlZMp1dDdNZg6u4ckbmNOj9pZw00N5pHHx6rC9jxXYsM7epxtazew99
	Ktewk8DaF1rzt830ww+QfBjrnS5tZOhY/LNiGfqxOppwIuubS5pe+QCEBy60GKrpjG7A=;
X-Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2)
	(envelope-from <andrew@lunn.ch>)
	id 1xRxsd-00GMG7-3D; Fri, 13 Nov 2026 21:28:15 +0100
X-Cc: hkallweit1@gmail.com, linux@armlinux.org.uk, davem@davemloft.net,
	edumazet@google.com, kuba@kernel.org, pabeni@redhat.com,
	robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org,
	maxime.chevallier@bootlin.com, pavel@ucw.cz,
	linux-kernel@vger.kernel.org, devicetree@vger.kernel.org,
	linux-leds@vger.kernel.org, netdev@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: <20261113110546.173624-3-a.shimko.dev@gmail.com>