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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240228152222.GA272403@bhelgaas>
Date: Wed, 28 Feb 2024 09:22:22 -0600
From: Bjorn Helgaas <helgaas@...nel.org>
To: Saurabh Singh Sengar <ssengar@...ux.microsoft.com>
Cc: bhelgaas@...gle.com, linux-pci@...r.kernel.org,
	linux-kernel@...r.kernel.org, alexander.stein@...tq-group.com,
	decui@...rosoft.com,
	Krzysztof WilczyƄski <kwilczynski@...nel.org>
Subject: Re: [PATCH] PCI/sysfs: Fix race in pci sysfs creation

On Tue, Feb 27, 2024 at 09:14:58AM -0800, Saurabh Singh Sengar wrote:
> On Wed, Feb 07, 2024 at 08:30:27AM -0800, Saurabh Singh Sengar wrote:
> > On Tue, Feb 06, 2024 at 04:07:15PM -0600, Bjorn Helgaas wrote:
> > > On Fri, Dec 08, 2023 at 07:46:16PM -0800, Saurabh Sengar wrote:
> > > > Currently there is a race in calling pci_create_resource_files function
> > > > from two different therads, first therad is triggered by pci_sysfs_init
> > > > from the late initcall where as the second thread is initiated by
> > > > pci_bus_add_devices from the respective PCI drivers probe.
> ...

> > > Krzysztof has done a ton of work to convert these files to static
> > > attributes, where the device model prevents most of these races:
> > > 
> > >   506140f9c06b ("PCI/sysfs: Convert "index", "acpi_index", "label" to static attributes")
> > >   d93f8399053d ("PCI/sysfs: Convert "vpd" to static attribute")
> > >   f42c35ea3b13 ("PCI/sysfs: Convert "reset" to static attribute")
> > >   527139d738d7 ("PCI/sysfs: Convert "rom" to static attribute")
> > >   e1d3f3268b0e ("PCI/sysfs: Convert "config" to static attribute")
> > > 
> > > and he even posted a series to do the same for the resource files:
> > > 
> > >   https://lore.kernel.org/linux-pci/20210910202623.2293708-1-kw@linux.com/
> > > 
> > > I can't remember why we didn't apply that at the time, and it no
> > > longer applies cleanly, but I think that's the direction we should go.
> > 
> > Thanks for you review.
> > 
> > Please inform me if there's existing feedback explaining why this
> > series hasn't been merged yet. I am willing to further improve it
> > if necessary.
> 
> Let us know your opinion so that we can move ahead in fixing this
> long pending bug.

There's no feedback on the mailing list (I checked the link above), so
the way forward is to update the series so it applies cleanly again
and post it as a v3.

There's no need to wait for Krzysztof to refresh it, and if you have
time to do it, it would be very welcomed!  The best base would be
v6.8-rc1.

Bjorn

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ