From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=185.246.85.4 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1793721456; b=J00jgjN4nLsDrmetqIhPyN+Sk6OvdK8YViH2C+d95xVdUDvJW5kDyjdbFW0A107FN8JJ wfVEe/0XGCuh20Hfm14VP+a8KqIIn1YgldpRlfg3Mqn+LrdHMnkiqB3lW8fvy2VppctXr VjpXecPyxl//agCWFimeN8uye2Uq/bkq5KDdN9AcYOyKKZx8C+6rCEanfHrOhsSNDG37Z GOkA+B8It/9aDV01D+sBOOH1Zu2kxdblltlstvRR92VemNMXMQyHreoCWhOUAOJQM8B53 7Rocfy11vmkaiI6R10gdhGLcVNfh0IV3aDVZvxdMYi3QykHfgBJQ8rU3Po5B5mt6WgA== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1793721456; h=DMARC-Filter:Received:Received:Received:DKIM-Signature:From:To:Cc: Subject:Date:Message-ID:X-Mailer:In-Reply-To:References:MIME-Version: Content-Transfer-Encoding:X-Last-TLS-Session-Version; bh=3TQHW+G37rNifSwPn5OcXaV1kVqaTQJJTD1CKDTBVFc=; b=hhuuICu/go56J88WTODRt3/MYzISDTYbplEIXNVYD234eERGUHHuM+vjearhkQJBQbvm +dbTFWKkrs4oRwZOOIz0srIUCzAL0pDxA1YKMiUzX2uFWaAvVQ8MN9sd3TA5/K8VyFsR5 9jfaFq+O6SxExPQxGsFFW+KzdgwC8SlrH6jGqZ3WciorjobUMIv3tX/5C+jhj37FfynqV /+/w9J5qQv2H6S7fAUUY3itdQnXGDuT3iykBE3e+C5JOYUBphhcHGBcuS28BHkEsf8Ok8 /zxiexl/rxzLDasW6E71cYu9IDe84a8k2S/uXjFoaCTeTrj9jsn5vslf2zzAGW37Jlw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass header.d=bootlin.com header.i=@bootlin.com header.a=rsa-sha256 header.s=dkim header.b=PaAduEyD; arc=none smtp.remote-ip=185.246.85.4 Received: from smtpout-03.galae.net (smtpout-03.galae.net [185.246.85.4]) (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 9EAD0606D81D; Tue, 3 Nov 2026 15:57:35 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 9EAD0606D81D Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=bootlin.com header.i=@bootlin.com header.a=rsa-sha256 header.s=dkim header.b=PaAduEyD Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-03.galae.net (Postfix) with ESMTPS id 5DA184E413DC; Tue, 3 Nov 2026 15:57:34 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id 0FF276046C; Tue, 3 Nov 2026 15:57:34 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id BA751103291D1; Tue, 3 Nov 2026 16:57:21 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1793721446; h=from:subject:date:message-id:to:cc:mime-version: content-transfer-encoding:in-reply-to:references; bh=3TQHW+G37rNifSwPn5OcXaV1kVqaTQJJTD1CKDTBVFc=; b=PaAduEyDCKiozaMAq/dbarxqcBkANWIC2aB0HsWP1OIlitinSXRwJmd080PETJ66W+Xbhc kvnXVLvOXfVJOZeOXqxVw6Q2+WuYd7Hr0fzZLJGr5r5Sj7I2sSMsZqkHgrs8RMMIddsjDA Rae4XdC4ktEAtghXFnEwmNBBydfeRB2NqlHUrx3WFyMz5C0kDMXjVY9uGSfdNVU3PiwvXL VMFDw2VPbXETySxkUZj5enP2Nj9JGIQD/eQKB1w3DaF3WInUZ0jctPN1Q4PYSdFQwxwMdg gqw8dqlyAH6QlkMWbykPe9PQzMdjbJyBwH3BQmPslQUW0cKOqtOevFEION4HAQ== From: Herve Codina To: Abdurrahman Hussain , Richard Cheng , Andrew Lunn , Rob Herring , Saravana Kannan , Greg Kroah-Hartman , "Rafael J. Wysocki" , Danilo Krummrich , Johan Hovold , Bjorn Helgaas , David Rhodes , Richard Fitzgerald , Charles Keepax , Linus Walleij , Andy Shevchenko , Daniel Scally , Heikki Krogerus , Sakari Ailus , Bartosz Golaszewski , Len Brown , Davidlohr Bueso , Jonathan Cameron , Dave Jiang , Alison Schofield , Vishal Verma , Dan Williams , Ira Weiny , Li Ming , Herve Codina , Lizhi Hou Cc: driver-core@lists.linux.dev, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, linux-sound@vger.kernel.org, patches@opensource.cirrus.com, linux-gpio@vger.kernel.org, linux-acpi@vger.kernel.org, linux-cxl@vger.kernel.org, Allan Nielsen , Horatiu Vultur , Daniel Machon , Steen Hegelund , Luca Ceresoli , Thomas Petazzoni , stable@vger.kernel.org Subject: [PATCH v14 09/10] PCI: of: Remove fwnode_dev_initialized() call for a PCI root bridge node Date: Tue, 3 Nov 2026 16:55:15 +0100 Message-ID: <20261103155540.365294-10-herve.codina@bootlin.com> X-Mailer: git-send-email 2.56.0 In-Reply-To: <20261103155540.365294-1-herve.codina@bootlin.com> References: <20261103155540.365294-1-herve.codina@bootlin.com> X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Last-TLS-Session-Version: TLSv1.3 During the instantiation of devices described by a device-tree overlay applied on a PCI device, devlink displays the following kind of debug messages instead of creating the expected links: 'Not linking xxxx - might never become dev' Without those expected links, the device removal order cannot be correct. Those debug traces are printed by fw_devlink_create_devlink(). In our use case, they are all printed because the supplier of the link has at least one of its ancestor with its fwnode flag FWNODE_FLAG_INITIALIZED set. The culprit ancestor is the PCI root bridge. The fwnode related to the PCI root bridge is created dynamically by the of_pci_make_host_bridge_node() function. During this creation fwnode_dev_initialized() is called which set the FWNODE_FLAG_INITIALIZED flag. Calling fwnode_dev_initialized() tells devlink that the device related to this node is handled out of the driver core. This is not correct in our case. Indeed the device related to this firmware node is handled using driver core mechanisms and is fully compliant devlink expectations. Simply remove the fwnode_dev_initialized() call. With that done, the devlink debug messages are no more displayed and links that were missing are correctly created. Fixes: 1f340724419e ("PCI: of: Create device tree PCI host bridge node") Cc: stable@vger.kernel.org Signed-off-by: Herve Codina Acked-by: Bjorn Helgaas Reviewed-by: Richard Cheng Tested-by: Abdurrahman Hussain --- drivers/pci/of.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/pci/of.c b/drivers/pci/of.c index 8914bfa25dc1..0a5797652e18 100644 --- a/drivers/pci/of.c +++ b/drivers/pci/of.c @@ -894,7 +894,6 @@ void of_pci_make_host_bridge_node(struct pci_host_bridge *bridge) */ of_node_set_flag(np, OF_POPULATED); fw_devlink_set_device(&np->fwnode, &bridge->dev); - fwnode_dev_initialized(&np->fwnode, true); ret = of_changeset_apply(cset); if (ret) -- 2.56.0