From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtpout-03.galae.net (smtpout-03.galae.net [185.246.85.4]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A586348CD55; Mon, 12 Oct 2026 14:29:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.246.85.4 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1791815351; cv=none; b=ssxgHNB91pyzKqepQ8TvKIV9g49L5dNdRFT4tiee6/hTSo9foxRzIAa3pFXg4LAlylr8D2uFhlbVPpKBraMqqxtu8Thgu6CwZBlJ/FHuEEYeYz96F4EH5xHUKe2CE4DGQfxtC96yNCVkVuxIvr6ydYBUHw9xno3F6hk6pOWF4lc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1791815351; c=relaxed/simple; bh=LeDPnBgrM7pNQ8OlNZHsJRQR3r2PXLGLegBZ2Qsqzf8=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=nvyqM7kWChZkfouMT28MUz9fayCz7R8o1KzaZhprVjb1y580XEJFFJYF5Pi3I8A9jD3n9vsjyvRjdrpqDKYy1GBXcblzXLbCpck8x/jVADWXuYW4LaLSUq3EYjvJYt9Hj1no8w29tEWzByLqivpdyxb8YAt6ixf9grlGn1N72vw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=FjGgQOgH; arc=none smtp.client-ip=185.246.85.4 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) header.d=bootlin.com header.i=@bootlin.com header.b="FjGgQOgH" Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-03.galae.net (Postfix) with ESMTPS id 40C1E4E411A5; Mon, 12 Oct 2026 14:29:08 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id 0F22E601A6; Mon, 12 Oct 2026 14:29:08 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id F37FF11D708B4; Mon, 12 Oct 2026 16:28:50 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1791815339; h=from:subject:date:message-id:to:cc:mime-version: content-transfer-encoding:in-reply-to:references; bh=kAb7NHjVc8QoTRTxUb1OG7thf2F5YhXlem84GhsJqnE=; b=FjGgQOgHcTUDDGnIbSuozwmNqeMTRdBQVZaPNnUfhfNiHolctNHx1hOE21Ll6aYc6zsp1v tYfEnkKxdGOOtY680hMNAcNEJaM9GkRVagicVm8ou5DFrd5VuLmwgGbbtWaPBFa0nRcAW7 iuGKxtDnIWPKwfwaYZObdeJ9zckNqniI+KLN1vyuvrXhXy0sCRuVe0N2R2v06p+hCVJxzJ Oxu6iH3orqfi6ElTPOegR+Wj2TpZlYb7tN7T2IqKprgAnyueowX5lDSHa/Zsq+QxXiQiAc GNRjXOfG2P+7tWArtGJk8xGwxsp+opS6e8tVRR7Xqp4HXMpqP3lAkPgm74kLIg== From: Herve Codina To: Richard Cheng , Andrew Lunn , Rob Herring , Saravana Kannan , Greg Kroah-Hartman , "Rafael J. Wysocki" , Danilo Krummrich , Bjorn Helgaas , Charles Keepax , Richard Fitzgerald , David Rhodes , 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, Ulf Hansson , Bartosz Golaszewski Subject: [PATCH v13 01/10] driver core: fw_devlink: Introduce fw_devlink_set_device() Date: Mon, 12 Oct 2026 16:28:15 +0200 Message-ID: <20261012142826.159178-2-herve.codina@bootlin.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20261012142826.159178-1-herve.codina@bootlin.com> References: <20261012142826.159178-1-herve.codina@bootlin.com> Precedence: bulk X-Mailing-List: linux-acpi@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Last-TLS-Session-Version: TLSv1.3 Setting fwnode->dev is specific to fw_devlink. In order to avoid having a direct 'fwnode->dev = dev;' in several place in the kernel, introduce fw_devlink_set_device() helper to perform this operation. Having this helper allows to hide the fwnode devlink related stuff behind the helper. Cc: stable@vger.kernel.org Signed-off-by: Herve Codina Reviewed-by: Andy Shevchenko Reviewed-by: Ulf Hansson Reviewed-by: Charles Keepax Reviewed-by: Richard Cheng Reviewed-by: Bartosz Golaszewski --- Cc stable because used by other patches with Fixes + Cc stable --- include/linux/fwnode.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/linux/fwnode.h b/include/linux/fwnode.h index a9dcaf7e7076..3ce49575cf82 100644 --- a/include/linux/fwnode.h +++ b/include/linux/fwnode.h @@ -260,4 +260,10 @@ void fw_devlink_purge_absent_suppliers(struct fwnode_handle *fwnode); void fw_devlink_refresh_fwnode(struct fwnode_handle *fwnode); bool fw_devlink_is_strict(void); +static inline void fw_devlink_set_device(struct fwnode_handle *fwnode, + struct device *dev) +{ + fwnode->dev = dev; +} + #endif -- 2.55.0