From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id AC669CCA479 for ; Mon, 4 Jul 2022 21:04:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231140AbiGDVEs (ORCPT ); Mon, 4 Jul 2022 17:04:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55898 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229921AbiGDVEr (ORCPT ); Mon, 4 Jul 2022 17:04:47 -0400 Received: from zeniv.linux.org.uk (zeniv.linux.org.uk [IPv6:2a03:a000:7:0:5054:ff:fe1c:15ff]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BC7ED55AB; Mon, 4 Jul 2022 14:04:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=linux.org.uk; s=zeniv-20220401; h=Sender:In-Reply-To:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=T4NEq+eMSGAkYEOA0B+r4pdVqAgo1X2D4OJSO7fEkNY=; b=AQZXT4X26RLQ+tZazISD4HjcHj uY43HvoKZBqSRJnUKTH2W+dL9c2FSeIpL0aPm++Jao5qMRkopG7Jw78ME/C9ubLOhmUX+Xe7dSXYQ Y4FAtgFK9dsEA66ZijK/hRjM+EGhXfzM0WZiFkcx1oNYvhS6AJBKQc5wmRfGCUBsBMX/1JsDNApIz YBywIfgH9bOTV56kOM/DAJAd+721Hutx1uqwOZ01LB6wtndOMYcaI3ulgDRCfq9YpymEaNwddqg+d rieM3tFld/azhG0yquNoj12g5gKcvOdTmSk3OfOJ8i9qf1cUd7Sz2LDQqiSnIeNKzaW0yUC3aW2YX O9uT8OhQ==; Received: from viro by zeniv.linux.org.uk with local (Exim 4.95 #2 (Red Hat Linux)) id 1o8TEm-0088kl-TL; Mon, 04 Jul 2022 21:04:09 +0000 Date: Mon, 4 Jul 2022 22:04:08 +0100 From: Al Viro To: Linus Torvalds Cc: Alexander Potapenko , Alexei Starovoitov , Andrew Morton , Andrey Konovalov , Andy Lutomirski , Arnd Bergmann , Borislav Petkov , Christoph Hellwig , Christoph Lameter , David Rientjes , Dmitry Vyukov , Eric Dumazet , Greg Kroah-Hartman , Herbert Xu , Ilya Leoshkevich , Ingo Molnar , Jens Axboe , Joonsoo Kim , Kees Cook , Marco Elver , Mark Rutland , Matthew Wilcox , "Michael S. Tsirkin" , Pekka Enberg , Peter Zijlstra , Petr Mladek , Steven Rostedt , Thomas Gleixner , Vasily Gorbik , Vegard Nossum , Vlastimil Babka , kasan-dev , Linux-MM , linux-arch , Linux Kernel Mailing List , Evgenii Stepanov , Nathan Chancellor , Nick Desaulniers , Segher Boessenkool , Vitaly Buka , linux-toolchains Subject: Re: [PATCH v4 43/45] namei: initialize parameters passed to step_into() Message-ID: References: <20220701142310.2188015-44-glider@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: Al Viro Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jul 04, 2022 at 01:51:16PM -0700, Linus Torvalds wrote: > On Mon, Jul 4, 2022 at 1:46 PM Al Viro wrote: > > > > Why is that a problem? It could have been moved to another parent, > > but so it could after we'd crossed to the mounted and we wouldn't have > > noticed (or cared). > > Yeah, see my other email. > > I agree that it might be a "we don't actually care" situation, where > all we care about that the name was valid at one point (when we picked > up that sequence point). So maybe we don't care about closing it. > > But even if so, I think it might warrant a comment, because I still > feel like we're basically "throwing away" our previous sequence point > information without ever checking it. > > Maybe all we ever care about is basically "this sequence point > protects the dentry inode pointer for the next lookup", and when it > comes to mount points that ends up being immaterial. There is a problem, actually, but it's in a different place... OK, let me try to write something resembling a formal proof and see what falls out.