Article View: linux.kernel.netdev
Article #11781Re: [PATCH 03/17] net: phy: Attach generic PHY drivers through the driver core
From: Andrew Lunn
Date: Thu, 05 Nov 2026 14:50
Date: Thu, 05 Nov 2026 14:50
20 lines
10359 bytes
10359 bytes
On Thu, Nov 05, 2026 at 01:42:16PM +0200, Leon Romanovsky wrote:
> From: Leon Romanovsky <leonro@nvidia.com>
>
> The generic PHY fallback probes directly before publishing its binding,
> bypassing driver-core admission and supplier checks.
>
> Attach through the driver core so admission precedes functional setup.
> Callers hold RTNL, which a concurrent bind of a specific driver may wait
> for with the device lock held, so for this flow let's add
> device_driver_try_attach() so the attachment never waits for that lock.
FYI: This code is fragile, and causes issues. I will need to stare
long and hard at it before accepting it. So i'm unlikely to do that
until the basic idea is accepted.
I also wounder how a PHY is a threat. What is your threat model for an
Ethernet PHY?
Andrew
Technical Details
Message-ID:
<9866a873-e71d-48cd-9153-be1bfce51eda@lunn.ch>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-357455-linux-kernel-netdev=dewy.ruReferences:
<20261105-device-trust-core-v1-0-1e536825b4eb@nvidia.com> <20261105-device-trust-core-v1-3-1e536825b4eb@nvidia.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-357455-linux-kernel-netdev=dewy.ru From: andrew@lunn.ch (Andrew Lunn) Newsgroups: linux.kernel.netdev Subject: Re: [PATCH 03/17] net: phy: Attach generic PHY drivers through the driver core Date: Thu, 5 Nov 2026 15:50:35 +0100 Organization: Usenet Network Message-ID: <9866a873-e71d-48cd-9153-be1bfce51eda@lunn.ch> References: <20261105-device-trust-core-v1-0-1e536825b4eb@nvidia.com> <20261105-device-trust-core-v1-3-1e536825b4eb@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: usenet.network; logging-data="3660835"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:KSf1Itk0vLbizMijFfHYV2rNlk0= sha256:Ntiey0YdHc69GZ0kJqPX88MPS3sgy9xQM5uodXp8JAo= sha1:gV6Kkqq6pp9QCdaJhgNtJoXYcQc= sha256:HIjJRW+nhYMSjAF+qDwfiE5a4O+WD7OM9gcvqrMUX4s= 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 327E6112EF5; Thu, 5 Nov 2026 18:04:04 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -1.95 X-Spam-Status: No, score=-1.95 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, URIBL_BLOCKED=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 PUjYEiSmpcl0; Thu, 5 Nov 2026 18:03:52 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-357455-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 C0FE8112FB5; Thu, 5 Nov 2026 18:03:43 +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 84CDD336CD; Thu, 5 Nov 2026 14:51:13 +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=1793890262; b=41itTtgV93/YreeMZOoLycHfAwfPNisPVWJGGZza52K7fBpEm+mbk+tcp6rHHoqcIZvR DY8IUXAgip1o/BYjLHT3HGpyeL2r6zyrx4jYu+ShVE2yvXuoyc110Upr218tLeZRdGGUn Idm/kJ8O4icv1woptJ0OLBCo1WBeKSGnBfJhImZ5hanvo2DRSOOe+tMRoiccYO4BqmFJ1 83xQIGmvtM49IyDCCvmk83Q4yuTrhjYAW3Kt8JuFmzAz+gu2OTDmCIVCkc0Jt/w0FWFcb 74S8SmYG+Gm9DG71Ef7cHXBirg4SZAlcHkhnLOPn/BpWJJI2lEOgmpBpkM4qzq1v2KA== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1793890262; 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=0QVs4UmW82faR41mfhaV+h9cFqICsfNx9N9UbV3NoAI=; b=P1Y5NFHPkA6jV16k4w5Wuo6ql1vvV06dEg6FvolsNcow+hVimPS1IlkabnMne+q/SaH5 Tx5Y6q6KKZ0sWdcz7Pcynz8H5KPnCXasr+439FzDsm9UXF2mN+bYfNGvsBlZVmsYwQyUP LlMnOIkhXuwaWEaqaijaMQYjtlEqlgqr4lOwezc/hbYyV9a59E8BzNByIO2eJR766tWuu VHVAcBhYYVHN7+Gx6A5f+sK1EtDOT++ewWJGdeHwkj4zhuvCSBH9h+CLEMoRJh3ES4BGa bjXZzqfSow1Q7Z94bMYeEusLPBLwTLk9iP2fGu34C4Yuz1xTX/TFraIaczO+w1gurAQ== 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=DNoY4vhi; 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 EDEB0606A33D; Thu, 5 Nov 2026 14:51:01 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key, unprotected) header.d=lunn.ch header.i=@lunn.ch header.a=rsa-sha256 header.s=20171124 header.b=DNoY4vhi 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=1793890253; b=YaP/OSMxw07/YYvPoYskwYy09LKQ+VkcUBLm2sap8KhPagUvcASBwGAX5CbBS/8pMgo1 EXBu8vTh9DPwep2IzHBCjQrOpkgahLn2J4tNgR2LLMprj2nwONX4qgOZiWt50L2E09syZ ewlTL8xmv6WuiMCCXkdgxqLU4UnH1Xkq/Wh88r8BPsVsSe3iD2OngAMCyKGEdENFN4Jmg GZ/UH5JF2eSLs66f4T6QopIiAXHkVdCYyKxBgn2NecUCxjKv0srd67uzcqLF39hfsywVA n4/7uY8b6Vbvrpc2ayupyCf2Xky22AYx6/mQbeOXOckX3dySoQGRv4o/V2dCLXKIbdw== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1793890253; h=DMARC-Filter:DKIM-Signature:Received:Date:From:To:Cc:Subject: Message-ID:References:MIME-Version:Content-Type:Content-Disposition: In-Reply-To; bh=0QVs4UmW82faR41mfhaV+h9cFqICsfNx9N9UbV3NoAI=; b=ra2CnasgvyUHBmR29AY4TKSkNzceAQhFfsISJ61slGBQ8mb7Mz6zDsV0Cd7Im6D/b9a1 YMclkrH4N5DgFwgdSbLePiFf8QL/LexwFaxBAi+ZA5/EUrxAMtzMTDVvbpyb8BPCGTLDz 0HKCPXcfwKxgtXotgDJ7mpxj7L0QBB782vG5G23qYmdEMwFfNQHNugIpBvAzOed3RtCBG WQYVkmbCJdavs0dIbd8edC/VPoczBZmJhtPsVZfDX7bG6C3gqFxQ7etazzG4oeQoTWWs/ 90lphiPYNDCTzo2VSB3rwmAAhs5bZgT4xK7Nfqto2dhQlG1mVi/l9f/a+cszECBNAlg== 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=DNoY4vhi; 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 CCCD1606A31B; Thu, 5 Nov 2026 14:50:52 +0000 (UTC) X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org CCCD1606A31B 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=0QVs4UmW82faR41mfhaV+h9cFqICsfNx9N9UbV3NoAI=; b=DNoY4vhiJHpefpc0K6k4ZEejnE z7BMrzdQ39NWlIM0NCy3i0azEyJUm7qdCzDTWvFOnHtGFFojpS2FV6+ZhBEddcut8CT3kNR7w9vtJ EbHP1y7vEIfqNZfBSV2OfralcPASt52j8xroqTNGzcNbawSyJl9tZWOJnJhANmXQBWjA=; X-Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from <andrew@lunn.ch>) id 1xOynT-00Eacz-Jh; Thu, 05 Nov 2026 15:50:35 +0100 X-Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>, "Rafael J. Wysocki" <rafael@kernel.org>, Danilo Krummrich <dakr@kernel.org>, Dmitry Torokhov <dmitry.torokhov@gmail.com>, Heiner Kallweit <hkallweit1@gmail.com>, Russell King <linux@armlinux.org.uk>, "David S. Miller" <davem@davemloft.net>, Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>, Johannes Berg <johannes@sipsolutions.net>, Jonathan Corbet <corbet@lwn.net>, Shuah Khan <skhan@linuxfoundation.org>, Randy Dunlap <rdunlap@infradead.org>, Bjorn Helgaas <bhelgaas@google.com>, "Joerg Roedel (AMD)" <joro@8bytes.org>, Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>, Vasant Hegde <vasant.hegde@amd.com>, Will Deacon <will@kernel.org>, Robin Murphy <robin.murphy@arm.com>, David Woodhouse <dwmw2@infradead.org>, Lu Baolu <baolu.lu@linux.intel.com>, Johan Hovold <johan@kernel.org>, Eric Dumazet <edumazet@kernel.org>, Marcel Holtmann <marcel@holtmann.org>, Luiz Augusto von Dentz <luiz.dentz@gmail.com>, Nipun Gupta <nipun.gupta@amd.com>, Nikhil Agarwal <nikhil.agarwal@amd.com>, Pieter Jansen van Vuuren <pieter.jansen-van-vuuren@amd.com>, linux-kernel@vger.kernel.org, driver-core@lists.linux.dev, linux-input@vger.kernel.org, netdev@vger.kernel.org, linux-wireless@vger.kernel.org, linux-usb@vger.kernel.org, linux-bluetooth@vger.kernel.org, linux-acpi@vger.kernel.org, linux-doc@vger.kernel.org, linux-pci@vger.kernel.org, iommu@lists.linux.dev, Jason Gunthorpe <jgg@ziepe.ca> 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: <20261105-device-trust-core-v1-3-1e536825b4eb@nvidia.com>