lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250616090406.32f62ca4@bootlin.com>
Date: Mon, 16 Jun 2025 09:04:06 +0200
From: Herve Codina <herve.codina@...tlin.com>
To: Saravana Kannan <saravanak@...gle.com>
Cc: Andrew Lunn <andrew@...n.ch>, Greg Kroah-Hartman
 <gregkh@...uxfoundation.org>, "Rafael J. Wysocki" <rafael@...nel.org>,
 Danilo Krummrich <dakr@...nel.org>, Shawn Guo <shawnguo@...nel.org>, Sascha
 Hauer <s.hauer@...gutronix.de>, Pengutronix Kernel Team
 <kernel@...gutronix.de>, Fabio Estevam <festevam@...il.com>, Michael
 Turquette <mturquette@...libre.com>, Stephen Boyd <sboyd@...nel.org>, Andi
 Shyti <andi.shyti@...nel.org>, Wolfram Sang
 <wsa+renesas@...g-engineering.com>, Peter Rosin <peda@...ntia.se>, Derek
 Kiernan <derek.kiernan@....com>, Dragan Cvetic <dragan.cvetic@....com>,
 Arnd Bergmann <arnd@...db.de>, Rob Herring <robh@...nel.org>, Bjorn Helgaas
 <bhelgaas@...gle.com>, Mark Brown <broonie@...nel.org>, Len Brown
 <lenb@...nel.org>, Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
 Daniel Scally <djrscally@...il.com>, Heikki Krogerus
 <heikki.krogerus@...ux.intel.com>, Sakari Ailus
 <sakari.ailus@...ux.intel.com>, Wolfram Sang <wsa@...nel.org>, Geert
 Uytterhoeven <geert+renesas@...der.be>, Davidlohr Bueso
 <dave@...olabs.net>, Dave Jiang <dave.jiang@...el.com>, Alison Schofield
 <alison.schofield@...el.com>, Vishal Verma <vishal.l.verma@...el.com>, Ira
 Weiny <ira.weiny@...el.com>, Dan Williams <dan.j.williams@...el.com>,
 linux-kernel@...r.kernel.org, imx@...ts.linux.dev,
 linux-arm-kernel@...ts.infradead.org, linux-clk@...r.kernel.org,
 linux-i2c@...r.kernel.org, devicetree@...r.kernel.org,
 linux-pci@...r.kernel.org, linux-spi@...r.kernel.org,
 linux-acpi@...r.kernel.org, linux-cxl@...r.kernel.org, Allan Nielsen
 <allan.nielsen@...rochip.com>, Horatiu Vultur
 <horatiu.vultur@...rochip.com>, Steen Hegelund
 <steen.hegelund@...rochip.com>, Luca Ceresoli <luca.ceresoli@...tlin.com>,
 Thomas Petazzoni <thomas.petazzoni@...tlin.com>
Subject: Re: [PATCH v3 06/28] driver core: fw_devlink: Introduce
 fw_devlink_set_device()

Hi Saravana,

On Fri, 13 Jun 2025 14:13:49 -0700
Saravana Kannan <saravanak@...gle.com> wrote:

> On Fri, Jun 13, 2025 at 6:49 AM Herve Codina <herve.codina@...tlin.com> wrote:
> >
> > 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.
> >  
> 
> This should not be set anywhere outside the driver core files. I'll
> get to reviewing the series, but until then, NACK to this.
> 
> Is there a specific patch that explain why we need to set this outside
> driver core?

We need to set it in case of creating device-tree node for PCI.

Usually, fwnode are created (based on DT or ACPI) and then, dev are
created.

In the PCI DT node creation case, device are already created and then, based
on information already computed by the kernel, DT node are created.

You can see that on patch 11 (dev setting was already upstream and it is
replace by a call to the helper for PCI host bridge) and on patch 13 (PCI
device).

Other patches (8, 9 and 10) replace the existing direct setting of the dev
member by a call to the helper.

Best regards,
Hervé

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ