Received: by 2002:a05:7208:13ca:b0:7f:395a:35b6 with SMTP id r10csp34293rbe; Wed, 28 Feb 2024 09:44:07 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWK7q8B8cUBz0G1BYRYjQ56G8wFuVItAg2ufN6RwCkF/Jm8Z5F4MOrVhVEYCB+zV+YFA3S00MUybO882Dt2vQmdE9adCv4049B4p4XXQw== X-Google-Smtp-Source: AGHT+IGODN1Uq/+mNiQL/mfb9tjZ2pPpYxlYxasRXE3t9HY7d61vInEFvIeo1ziQRehRt6fwcbY9 X-Received: by 2002:a05:6808:4495:b0:3c1:b8bd:ad61 with SMTP id eq21-20020a056808449500b003c1b8bdad61mr3817130oib.52.1709142247094; Wed, 28 Feb 2024 09:44:07 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709142247; cv=pass; d=google.com; s=arc-20160816; b=XOJexYFL0GgcbKDT9PlHO9WtV3W5Z9kt6c6o0QG2+qgDyhKrZLT1aAn+3bwWoQzyB9 pJzK8GRR70fDv8Bm8sGJY60btZyIcsSH9EWzni/vwseke+4sgRlERYAA9QVdls4dQFP2 jQIZXxtdtoFUK2hqk3X+onG9EgKZm7tFhlT1ryagtLCEug/RB3KvzLgbwIAaIEXxKzND 2gzyUjx75R+V4mXTLfpJEg3yLHAkC9eFZrkLltxNzpU8ypH0/DB5tVmVB95W3ziTxExz cZgZouPJCwW9e9S0T+ARPh5VTOLNAPJTwRBkKd/CWF3dfACLRyFIfDuS7FOmn3oH+dRL 1AgQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=etOh6wdVEyQfgdgf5OI+lviMXti/j7GkfR4ACCbml0I=; fh=musr13uupMQy4Hr/bN7Ejx7HnA5VrSheLSWfyLcI7dk=; b=gn7Vbc/6qftlTxpdGLHINZfi/KJnYoyFfDjzW0PV3Ss7i4yXoWwMs4J5yzY+DFxLST Av8txVG0OBMKKfmRqVH3ISv46AoohzLz2pGyRPNGvOdkCwWeVWR/G4pI60oD9szt/Tdg hJoaHxV8w3mwIcZ8Krc/5C8W+idSHyWb+VwtV/5pdUlaMoqopf/3hmKJGT1cCcBVZ74/ KHP5KeXhWoG4YTjreohEzSr/jl+RHgGrId4mCLhN4mUGUADssP8Q8bM0jmO/ZAacFERy Lw4Z0CoFxtRl5FAxxIftuZjU8X+i4Eydvr0ciiUAwOClJMa4uO72kNCSqhCfm7wyJjK1 0eFw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="pFP76c/2"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-85430-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-85430-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id s15-20020a056a00194f00b006e476b6392bsi7998864pfk.287.2024.02.28.09.44.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Feb 2024 09:44:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-85430-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="pFP76c/2"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-85430-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-85430-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id E64C5B2851E for ; Wed, 28 Feb 2024 17:23:03 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 611BE1586EF; Wed, 28 Feb 2024 17:22:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="pFP76c/2" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 81FB73FBB8; Wed, 28 Feb 2024 17:22:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709140977; cv=none; b=iV6U0bK2FocPXOtt35FChStlCLWyDHY8gqVp1fM2SZrz2AR1UDnN+w14EXW/U3uqlKjgMyko0FShkPP/TEtVKCJKXQl9M+8cb+CaPw/IGKChtgNRpZCYjG3bqXw6zSmEL9ifqkB94LkyJfCLiYTpyE0PqatK/0RCwNU1pnZuMIc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709140977; c=relaxed/simple; bh=nRStdjfCcY7LSJLuSnjP760bh7C+8aHgl8Sn6p9a54c=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Bt175Hxlf3/ue32JNCVpgsYTxKDZAdr6w7M+BKuskVzLZzhpCAjZyQP1K3/GWfOMHlgpVb9lOj1mVQh8Rw7pkyy2Jr6dZoCVPvrjWn9hC6BkvA9pBF1dnWLFjpk40pcJHMuqFBon0R3InqteLnZQdZkROWuT3gjqVipDMFPxEuc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=pFP76c/2; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id CB032C433C7; Wed, 28 Feb 2024 17:22:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1709140977; bh=nRStdjfCcY7LSJLuSnjP760bh7C+8aHgl8Sn6p9a54c=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=pFP76c/27QGJc+0KjT3gXE1b0bg/veuDKpkmd+8bBXr3xT/NuaN68Dc4uD+96knYe DjELLTJTAHI3e8Z3gTqXcZk+NSZG9+2tU/gzor6pqlzoUyscNZnzJd16m6OQYsVO8t DqSWBaQlWk+hxPP7aZOKTRLHas946LtCbxs+UFFJmvBeNjPRo0Qplu5v4YY+10GEM1 dhrwHTJHscRO3RO0JV9f1mY9y2CF7e2I14zW3Sfv39HrL0fsJ2fqPIcDgLx3ZOeIYH WmWTSzrT8GYhLZnEohrvXsM+RI6BAZmOTDTO9IiErZUmWqfz35sVmLvmahVjHh7HAa Zz7WuqiVCvL2A== Date: Thu, 29 Feb 2024 02:22:55 +0900 From: Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= To: Bjorn Helgaas Cc: Saurabh Singh Sengar , bhelgaas@google.com, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, alexander.stein@ew.tq-group.com, decui@microsoft.com Subject: Re: [PATCH] PCI/sysfs: Fix race in pci sysfs creation Message-ID: <20240228172255.GA3579062@rocinante> References: <20240227171458.GA16664@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net> <20240228152222.GA272403@bhelgaas> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240228152222.GA272403@bhelgaas> Hello, Sorry for late reply. [...] > > > > 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. I really thought you were asking me about your patch. So, I didn't reply since Bjorn added his review. > 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. Start with a review, if you have some time. Perhaps we can make it better before sending another revision. There are two areas which this series decided not to tackle initially: - Support for the Alpha platform - Support for legacy PCI platforms Feel free to have a look at the above. Perhaps you will have some ideas on how to best convert both of these to use static attributes, so that we could convert everything at the same time. > 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. That I can do, perhaps this coming weekend. Or even sooner when I find some time this week. Krzysztof