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 X-Spam-Level: X-Spam-Status: No, score=-0.9 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E5C83C3A59E for ; Wed, 4 Sep 2019 22:46:00 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B5DD320870 for ; Wed, 4 Sep 2019 22:46:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1567637160; bh=QXa9FOQlcR93VFXaVslVmY1z8aHwwfqAQ50pNLg6CsI=; h=References:In-Reply-To:From:Date:Subject:To:Cc:List-ID:From; b=N3mpRBZxARXpk8GeZ3h3qwKnWwsipE4HWqd0KBSyb6JLQT/A07DBkx15vvfbgZW18 Phtaq4R9KxoXmANSVTsD26t8mBaBXq6ToSpFdnT5iS3iRVfolMtbQW2qzvjQp3adcc v/zzyU/3Pd0+sGshLp65qSVNwFsiSvnkxBMiBgLM= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729093AbfIDWqA (ORCPT ); Wed, 4 Sep 2019 18:46:00 -0400 Received: from mail-lj1-f193.google.com ([209.85.208.193]:42588 "EHLO mail-lj1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727156AbfIDWqA (ORCPT ); Wed, 4 Sep 2019 18:46:00 -0400 Received: by mail-lj1-f193.google.com with SMTP id y23so330738lje.9 for ; Wed, 04 Sep 2019 15:45:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=KFDhCyHzhyiLnyceYcteUHqOXGgh38Kg6TIOg9RDlV8=; b=GnnwuO2FC8JvRpMBdQIyMOw63KWp0i8RWU7BAf9vhwmdfauk+kGPRrhGsnlnlPAmBt Cx6hzCIVK4L+kzxznEGXiVTPGueSaoLKTwELcbVCO2oVI6bZuWttjzsqT9tZPNkgY/TA 7QyH0CjS5KTQcx4hIjs9o8ztIuxjlBT486QSI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=KFDhCyHzhyiLnyceYcteUHqOXGgh38Kg6TIOg9RDlV8=; b=iCPDwrpImsE9Gs8FXho/0Moaja7V14HKTpq03vfGys7TUEIMnjaVfohACEX8CYwB7J v5N4XkjKvCJT4RTTGWG1LofhGUWCNCvFP2/HzpWa0kv+IRdakjj5jAxUX3ZoJaerxNqZ 5EsnaEEFfMpXINxbWFW+UhBpjEbViSImMF0j/nHxpiDglUaxnwgP1AobW/cLdPs6J1uW R+LNhuPz/xe6qRG5N5B2No3MUrRk6Ix3KjFLFeb9t3RhHVuUItUU/HTvatFTsGtdz8/O M7DMV59sb8DbOs5ipXdI/a6Xrd9ecZIQ6KTT5BpWBNPWqol9CVBUgm5EK5MrCm8KaJ+b 3QZA== X-Gm-Message-State: APjAAAV9LWjImYDsLQUb6JxvsSb2Kihyyffuh+84VRlAqTV6NmJRgTZV gkNkQkSWcEbgv17mX4MojxfUVn1lzkM= X-Google-Smtp-Source: APXvYqy7PIq18aDeccpqnM9+0i5T2fYFPsG2NlaLJZ98jhUnWEGUyeoZnngNGTjqDD70DjGf5D2zVQ== X-Received: by 2002:a2e:99cc:: with SMTP id l12mr24331ljj.5.1567637157762; Wed, 04 Sep 2019 15:45:57 -0700 (PDT) Received: from mail-lj1-f170.google.com (mail-lj1-f170.google.com. [209.85.208.170]) by smtp.gmail.com with ESMTPSA id j2sm45782lfb.50.2019.09.04.15.45.57 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 04 Sep 2019 15:45:57 -0700 (PDT) Received: by mail-lj1-f170.google.com with SMTP id l20so368258ljj.3 for ; Wed, 04 Sep 2019 15:45:57 -0700 (PDT) X-Received: by 2002:a2e:814d:: with SMTP id t13mr24885ljg.72.1567636715921; Wed, 04 Sep 2019 15:38:35 -0700 (PDT) MIME-Version: 1.0 References: <20190904201933.10736-1-cyphar@cyphar.com> <20190904201933.10736-11-cyphar@cyphar.com> <20190904214856.vnvom7h5xontvngq@yavin.dot.cyphar.com> <20592.1567636276@warthog.procyon.org.uk> In-Reply-To: <20592.1567636276@warthog.procyon.org.uk> From: Linus Torvalds Date: Wed, 4 Sep 2019 15:38:20 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v12 10/12] namei: aggressively check for nd->root escape on ".." resolution To: David Howells Cc: Aleksa Sarai , Al Viro , Jeff Layton , "J. Bruce Fields" , Arnd Bergmann , Shuah Khan , Shuah Khan , Ingo Molnar , Peter Zijlstra , Christian Brauner , Jann Horn , Kees Cook , Eric Biederman , Andy Lutomirski , Andrew Morton , Alexei Starovoitov , Tycho Andersen , David Drysdale , Chanho Min , Oleg Nesterov , Rasmus Villemoes , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Aleksa Sarai , Linux Containers , alpha , Linux API , linux-arch , Linux ARM , linux-fsdevel , linux-ia64@vger.kernel.org, Linux List Kernel Mailing , "open list:KERNEL SELFTEST FRAMEWORK" , linux-m68k , linux-mips@vger.kernel.org, linux-parisc@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-s390 , Linux-sh list , linux-xtensa@linux-xtensa.org, sparclinux@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org On Wed, Sep 4, 2019 at 3:31 PM David Howells wrote: > > It ought to be reasonably easy to make them per-sb at least, I think. We > don't allow cross-super rename, right? Right now the sequence count handling very much depends on it being a global entity on the reader side, at least. And while the rename sequence count could (and probably should) be per-sb, the same is very much not true of the mount one. So the rename seqcount is likely easier to fix than the mount one, but neither of them are entirely trivial, afaik. Linus